PDA

View Full Version : Creating txt file using Basic Stamp Editor



deckbuild
09-18-2008, 04:11 PM
Hi guys,


I am trying to use my bs2px chip to create a txt file, and then send it to my bluetooth chip using uart interface. Is it actually possible to create a text file using Basic stamp editor in the first place http://forums.parallax.com/images/smilies/confused.gif ? If it is not, I am planning to create a text file separately, and then use bs2px to send it to my bt chip using uart interface. Could someone please enlighten me?



Cheers http://forums.parallax.com/images/smilies/cool.gif ,



Mave

Post Edited (deckbuild) : 9/21/2008 9:41:07 AM GMT

Mike Green
09-18-2008, 10:20 PM
The closest thing to a "text file" would be to store the text as DATA statements in the EEPROM of the BS2px and use the READ and STORE statements to fetch the characters one at a time to send with a SEROUT statement.

Read the chapters in the Stamp Basic Manual on the DATA, READ, STORE, and SEROUT statements. That will explain how this sort of thing works and give some simple examples. The Stamp Editor's help will give you some information, but you need to read the Manual.

Please edit your original message (using the pencil icon in the upper right corner) to add an appropriate subject.

deckbuild
09-21-2008, 05:39 PM
Anymore help on this

Unsoundcode
09-21-2008, 11:34 PM
Hi deckbuild, just to re-enforce what Mike has said you should take a look at the DATA instruction of the PBasic IDE help files. If you open the help file and do a search for DATA Example there is an example of storing and displaying text phrases. The display is·achieved using the DEBUG instruction, if on the other hand you wanted to transmit your text phrases to another device the DEBUG instruction would be replaced with the SEROUT instruction.

If this example is not what you had in mind then if you can expand on your explanation we can look at alternatives.

Jeff T.