Troubleshooting PBASIC Step at a time?
Archiver
Posts: 46,084
In a message dated 5/6/2004 7:34:04 PM Eastern Daylight Time,
troybakken@y... writes:
> Is there a way to step through Pbasic code a line at a time? Is
> there a way to do this such that you can look at the status of the
> pins on the stamp while you step? Alternately is there a debug
> that will allow you to halt the program to wait for a keyboard
> entry? I am looked in the book and haven't found it.
>
You can accomplish this by writing at any point in the program:
serout 16, baud, [noparse][[/noparse]"Press any key to continue", cr]
serin 16, baud , [noparse][[/noparse]com]
Once the program receives any byte it will continue on its way.
Sid Weaver
256K of plugin EEPROM................
http://www.visualmuses.com/chipcircuit/index.html
[noparse][[/noparse]Non-text portions of this message have been removed]
troybakken@y... writes:
> Is there a way to step through Pbasic code a line at a time? Is
> there a way to do this such that you can look at the status of the
> pins on the stamp while you step? Alternately is there a debug
> that will allow you to halt the program to wait for a keyboard
> entry? I am looked in the book and haven't found it.
>
You can accomplish this by writing at any point in the program:
serout 16, baud, [noparse][[/noparse]"Press any key to continue", cr]
serin 16, baud , [noparse][[/noparse]com]
Once the program receives any byte it will continue on its way.
Sid Weaver
256K of plugin EEPROM................
http://www.visualmuses.com/chipcircuit/index.html
[noparse][[/noparse]Non-text portions of this message have been removed]
Comments
there a way to do this such that you can look at the status of the
pins on the stamp while you step? Alternately is there a debug
that will allow you to halt the program to wait for a keyboard
entry? I am looked in the book and haven't found it.
Thanks,
Troy
MyVal VAR BYTE
SERIN 16, 16384, [noparse][[/noparse]DEC MyVal]
The BS2 will wait until you type a number
into the 'terminal' window with this line.
--- In basicstamps@yahoogroups.com, "Troy Bakken" <troybakken@y...>
wrote:
> Is there a way to step through Pbasic code a line at a time? Is
> there a way to do this such that you can look at the status of the
> pins on the stamp while you step? Alternately is there a debug
> that will allow you to halt the program to wait for a keyboard
> entry? I am looked in the book and haven't found it.
>
> Thanks,
>
> Troy