15418Re: How can I test the current speed in a script?
- Apr 2, 2013--- In firstname.lastname@example.org, James Ewen <ve6srv@...> wrote:
> It all depends upon what you need this routine to do, and how much you
> are changing between the profiles.
> Let's pretend that you want to change the path used from WIDE2-2 while
> moving to WIDE2-1 when sitting still, but only after sitting still for
> 5 minutes....> Well, set up a script that tests against being in profile 2, and while
> in profile 2, start a timer. Increment the timer every second, and
> when the timer reaches 300 (5 minutes * 60 seconds), execute the
> command to change the path to WIDE2-1.
> You'll need to test if you switch back to profile 1, and if you do,
> clear the timer value to zero, and set the path in profile 2 back to
> WIDE2-2. You can set a variable to check to see if you've changed
> parameters while in profile 2 or not so you don't do unnecessary
> writes....> So, what do you want to do, and how often do you want to do it?
> VE6SRVThanks James, I updated my script based on your explanation.My initial script was not working, because I had assumed that the profiles defined in OTWINCFG were static, and just used to set the active parameters.Instead, as you described, the profiles are directly modified avery time a script modifies a parameter, therefore I needed to re-set the parameters to their original value.The parameters I want to change are POWER, INTERVAL, and COMMENT.The attached script has been working well for the last 2 weeksIf Profile 1Do OnceExec "POWER ON"Exec "INTERVAL 60"Exec "COMMENT S"Set Counter 1 = 0Exec "BEACON"End BlockOn SecondIncrement Counter 1If Counter 1 = 300Exec "COMMENT P"Exec "POWER 3"Exec "INTERVAL 900"End BlockEnd BlockEnd BlockIf Profile 2Do OnceExec "COMMENT M"Exec "BEACON"End BlockEnd Block
- << Previous post in topic Next post in topic >>