Hello. I have problem with delays on my maestro mini 12. Delays are 3 times slower then they should be.
I’m having delays in seconds. I did that like it is described in example script:
sub seconds begin dup while 1 minus 1000 milliseconds #another subroutine to include other subroutines repeat drop return sub milliseconds begin dup while 1 minus 1 delay button_check #subroutine to check if button is pressed battery_check #subroutine to check if battery is low led_blink #led-on 50 milliseconds every 3 seconds drop return
The problem appeared when I added led_blink subroutine:
sub led-blink get_ms 5 peek minus 4 peek less_than if 8000 8 servo else 4000 8 servo get_ms 5 peek minus 3 peek greater_than if get_ms 5 poke endif endif return
And here are variables to go first on stack when the script starts:
300 100 get_ms 3000 50 get_ms
I’m assuming that my script is to complex and demanding for maestro to process it in real time.
Is there some other way to control LEDs and Servos independently and to check button presses in between delays?
I can even post the whole script if someone is willing to take a look at it and maybe offer some solution to my problem.