PDA

View Full Version : Serin2 and Timeout to Label



f0ster52
- 9th April 2009, 19:02
Hello everybody,
my first post in this board is to question the experts:

The timeout to label function in Serin2 command, is to be considered like a GOTO or could be used like a GOSUB/RETURN?

Thanks in advance.

Luckyborg
- 9th April 2009, 20:16
I', pretty sure it is only used as a goto, so if you wanted to use it as a return you would have to do something like


get_data:
SerIn2 PORTC.7,813,2000,nodata,[x]
Serin2_return:
...
return

nodata:
...
...
goto serin2_return


David

f0ster52
- 10th April 2009, 03:29
I', pretty sure it is only used as a goto, so if you wanted to use it as a return you would have to do something like


get_data:
SerIn2 PORTC.7,813,2000,nodata,[x]
Serin2_return:
...
return

nodata:
...
...
goto serin2_return


David

I was already using structures like the one in your example, then i'll continue using'em

Thanks for the help David.