[font=arial,helvetica]In a message dated 6/1/01 8:04:25 PM Central Daylight Time, aconti@neo.rr.com
writes:
Can someone tell me what is the Scratch Pad RAM
The BS2e, BS2sx and BS2p have additional RAM (64 bytes in the BS2e and BS2sx,
127 bytes in the BS2p) that can be used by any program slot and is not
affected when switching from one program slot to another. ·This makes it
useful as a data exchange mechanism between programs.
You can stuff a byte into SP-RAM with PUT. ·You retrieve a byte with GET.
PUT and GET are analogous to WRITE and READ (that is, they are byte-oriented
and you must specify an address).
In the BS2p there is a new modifier, SPSTR, for serial input commands (SERIN,
I2CIN, OWIN, LCDIN). ·This modifier will let you "buffer" data from the input
device into the SP-RAM (starting at location 0). ·Many have found this useful
for reading long strings (i.e., from a GPS device). ·Once the data is in
SP-RAM, you can parse through it manually with GET. ·By buffering to SP-RAM,
you don't use any variable space for your raw input.
HTH.
-- Jon Williams
-- Applications Engineer, Parallax,
-- Dallas, TX
PS: All this good stuff can be found in the Parallax BASIC Stamp manual. ·It
is worth downloading from Parallax (Version 2.0c)[/font]
I've downloaded and read most of the 2.0c manual and cannot find any
reference to the SPSTR command. I've checked the index, all the pages
for the Scrath Pad RAM, the I2C commands, OW commands and
SERIN/SEROUT commands and can find no reference to this at all. The
section in SERIN that deals with strings gets close, referring to the
STR modifier, but there is no mention of SPSTR (that I can find).
This is a very powerful command and should have it's own section near
the STR modifier. Am I just missing it?!
Is there a limit to the number of times you can write/read to the SP-
RAM?
[font=arial,helvetica]In a message dated 6/2/01 10:43:52 AM Central Daylight Time, bs2web@yahoo.com
writes:
I've downloaded and read most of the 2.0c manual and cannot find any
reference to the SPSTR command. I've checked the index, all the pages
for the Scrath Pad RAM, the I2C commands, OW commands and
SERIN/SEROUT commands and can find no reference to this at all. The
section in SERIN that deals with strings gets close, referring to the
STR modifier, but there is no mention of SPSTR (that I can find).
This is a very powerful command and should have it's own section near
the STR modifier. Am I just missing it?!
No...you're right. ·It's not in the manual. ·I happen to know the guy who
created the SPSTR function though, so I have the good skinny. ;-)
Is there a limit to the number of times you can write/read to the SP-
RAM?
No practical limit that I'm aware of. ·The SP-RAM is RAM, no EEPROM.
-- Jon Williams
-- Applications Engineer, Parallax[/font]
> >This modifier will let you "buffer" data from the input
> >device into the SP-RAM (starting at location 0).
>
>Does the "SPSTR" modifier allow the BS2p SERIN operation to proceed
>"asynchronously", or does the processor wait for SERIN to complete?
>
>Jay
It waits for SERIN to complete. The SERIN has to be ready to receive
the characters before they start arriving, and the command does not
finish until the required number of charaters are received or the
time-out period elapses.
>===== Original Message From basicstamps@yahoogroups.com =====
>In a message dated 6/1/01 8:04:25 PM Central Daylight Time, aconti@n...
>writes:
>
>
>> Can someone tell me what is the Scratch Pad RAM
>>
>The BS2e, BS2sx and BS2p have additional RAM (64 bytes in the BS2e and BS2sx,
>127 bytes in the BS2p) that can be used by any program slot and is not
>affected when switching from one program slot to another. This makes it
>useful as a data exchange mechanism between programs.
>
>You can stuff a byte into SP-RAM with PUT. You retrieve a byte with GET.
This only seems to work if the files are part of the same project.
>PUT and GET are analogous to WRITE and READ (that is, they are byte-oriented
>and you must specify an address).
>
>In the BS2p there is a new modifier, SPSTR, for serial input commands (SERIN,
>I2CIN, OWIN, LCDIN). This modifier will let you "buffer" data from the input
>device into the SP-RAM (starting at location 0). Many have found this useful
>for reading long strings (i.e., from a GPS device). Once the data is in
>SP-RAM, you can parse through it manually with GET. By buffering to SP-RAM,
>you don't use any variable space for your raw input.
>
>HTH.
>
>-- Jon Williams
>-- Applications Engineer, Parallax,
>-- Dallas, TX
>
>PS: All this good stuff can be found in the Parallax BASIC Stamp manual. It
>is worth downloading from Parallax (Version 2.0c)
Comments
writes:
The BS2e, BS2sx and BS2p have additional RAM (64 bytes in the BS2e and BS2sx,
127 bytes in the BS2p) that can be used by any program slot and is not
affected when switching from one program slot to another. ·This makes it
useful as a data exchange mechanism between programs.
You can stuff a byte into SP-RAM with PUT. ·You retrieve a byte with GET.
PUT and GET are analogous to WRITE and READ (that is, they are byte-oriented
and you must specify an address).
In the BS2p there is a new modifier, SPSTR, for serial input commands (SERIN,
I2CIN, OWIN, LCDIN). ·This modifier will let you "buffer" data from the input
device into the SP-RAM (starting at location 0). ·Many have found this useful
for reading long strings (i.e., from a GPS device). ·Once the data is in
SP-RAM, you can parse through it manually with GET. ·By buffering to SP-RAM,
you don't use any variable space for your raw input.
HTH.
-- Jon Williams
-- Applications Engineer, Parallax,
-- Dallas, TX
PS: All this good stuff can be found in the Parallax BASIC Stamp manual. ·It
is worth downloading from Parallax (Version 2.0c)[/font]
I've downloaded and read most of the 2.0c manual and cannot find any
reference to the SPSTR command. I've checked the index, all the pages
for the Scrath Pad RAM, the I2C commands, OW commands and
SERIN/SEROUT commands and can find no reference to this at all. The
section in SERIN that deals with strings gets close, referring to the
STR modifier, but there is no mention of SPSTR (that I can find).
This is a very powerful command and should have it's own section near
the STR modifier. Am I just missing it?!
Is there a limit to the number of times you can write/read to the SP-
RAM?
Thanks in advance,
--Jeff Wallace
--http://www.high-techgarage.com
> PS: All this good stuff can be found in the Parallax BASIC Stamp
> manual. It is worth downloading from Parallax (Version 2.0c)
writes:
reference to the SPSTR command. I've checked the index, all the pages
for the Scrath Pad RAM, the I2C commands, OW commands and
SERIN/SEROUT commands and can find no reference to this at all. The
section in SERIN that deals with strings gets close, referring to the
STR modifier, but there is no mention of SPSTR (that I can find).
This is a very powerful command and should have it's own section near
the STR modifier. Am I just missing it?!
No...you're right. ·It's not in the manual. ·I happen to know the guy who
created the SPSTR function though, so I have the good skinny. ;-)
RAM?
No practical limit that I'm aware of. ·The SP-RAM is RAM, no EEPROM.
-- Jon Williams
-- Applications Engineer, Parallax[/font]
>device into the SP-RAM (starting at location 0).
Does the "SPSTR" modifier allow the BS2p SERIN operation to proceed
"asynchronously", or does the processor wait for SERIN to complete?
Jay
> >device into the SP-RAM (starting at location 0).
>
>Does the "SPSTR" modifier allow the BS2p SERIN operation to proceed
>"asynchronously", or does the processor wait for SERIN to complete?
>
>Jay
It waits for SERIN to complete. The SERIN has to be ready to receive
the characters before they start arriving, and the command does not
finish until the required number of charaters are received or the
time-out period elapses.
>In a message dated 6/1/01 8:04:25 PM Central Daylight Time, aconti@n...
>writes:
>
>
>> Can someone tell me what is the Scratch Pad RAM
>>
>The BS2e, BS2sx and BS2p have additional RAM (64 bytes in the BS2e and BS2sx,
>127 bytes in the BS2p) that can be used by any program slot and is not
>affected when switching from one program slot to another. This makes it
>useful as a data exchange mechanism between programs.
>
>You can stuff a byte into SP-RAM with PUT. You retrieve a byte with GET.
This only seems to work if the files are part of the same project.
>PUT and GET are analogous to WRITE and READ (that is, they are byte-oriented
>and you must specify an address).
>
>In the BS2p there is a new modifier, SPSTR, for serial input commands (SERIN,
>I2CIN, OWIN, LCDIN). This modifier will let you "buffer" data from the input
>device into the SP-RAM (starting at location 0). Many have found this useful
>for reading long strings (i.e., from a GPS device). Once the data is in
>SP-RAM, you can parse through it manually with GET. By buffering to SP-RAM,
>you don't use any variable space for your raw input.
>
>HTH.
>
>-- Jon Williams
>-- Applications Engineer, Parallax,
>-- Dallas, TX
>
>PS: All this good stuff can be found in the Parallax BASIC Stamp manual. It
>is worth downloading from Parallax (Version 2.0c)