Hi Guys,
According to the manual, the "BUTTON" function acts as a "GOTO" to a defined label (the last argument) with the added bonus of disabling auto-repeat and or debounce... does anybody know if the same can be used to GOSUB?
or know of a solution to do the same?
Since I have loops within loops the button presses keep being registered, but I cannot use the BUTTON function to GOTO since it will reset the count on the main loop
Code:
MAIN:
FOR CNT2 = 1 TO CNT
IF PORTA.3 = 1 THEN GOSUB SHIP
IF PORTA.0 = 1 THEN GOSUB FIRE
IF CNT2 == CNT THEN GOSUB ADD
GOSUB LCDUPDATE
PAUSE 5
NEXT
GOTO MAIN
As you can see I am using GOSUB as to not interrupt the "for..next" loop doing the count, but I need a way of stopping auto repeat on the button checks... (without pausing since this messes up the count timing) unless there is another way to have a definitive count?
(watchdog timer perhaps? never used it)
Basically so that when the user presses the button it will only increment by 1 and not auto repeat (due to the instructions per second) and increment by about 70 per press 
Any help will be greatly appreciated!
Bookmarks