serout question
basicstampede
Posts: 214
How do I do this?
I need to ask user to enter a text character, then I need to send it out using serout.
For example, the user may type "I love basic stamps".· Then I have to send out
Say CON $00
EOM CON $AA
serout tx, baud, [noparse][[/noparse]Say, "I love basic stamps", EOM]
This is for a EMIC board.
I've read the example program.· It shows a constant string stored in EEPROM.
However, I wish to modify the program so that EMIC says what the user types.· The length of the message may vary.
Any insight would be appreciated.·
I need to ask user to enter a text character, then I need to send it out using serout.
For example, the user may type "I love basic stamps".· Then I have to send out
Say CON $00
EOM CON $AA
serout tx, baud, [noparse][[/noparse]Say, "I love basic stamps", EOM]
This is for a EMIC board.
I've read the example program.· It shows a constant string stored in EEPROM.
However, I wish to modify the program so that EMIC says what the user types.· The length of the message may vary.
Any insight would be appreciated.·
Comments
Serin character
If chracter is not equal to return then Serout Say
While character is not equal to return
Serout character
Serin character
end while
serout EOM
In essence, you would build your string on the fly on the EMIC. As I said, this would heavily depend on the timing requirements of the EMIC.
The same kind of concept could more easily be handled by one of the BS2s with "Scratchpad" RAM and the STR capabilities.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Truly Understand the Fundamentals and the Path will be so much easier...