Sending a string using hyperterminal or Parallax serial terminal
dodger
Posts: 37
I believe the serial device i am using at the moment sends out 18 characters in a string, but the object says it can only recieve 15 characters.· I want to try to eliminate the cause of my problems and verify that the application i have is correct.·
Therefore i would like to use a terminal program to send out a string.
Is it possible to send a string using hyper term or the parallax serial term.· I can only send a byte at a time.· Since i am trying to figure out whats causing some problems i would like to send a string through a terminal program and have the microcontroller recieve it using the Extended FDSerial object.· Any suggestions?·
Thanks
Therefore i would like to use a terminal program to send out a string.
Is it possible to send a string using hyper term or the parallax serial term.· I can only send a byte at a time.· Since i am trying to figure out whats causing some problems i would like to send a string through a terminal program and have the microcontroller recieve it using the Extended FDSerial object.· Any suggestions?·
Thanks
Comments
Hyperterminal may be scriptable, but I normally use the MacOS and have no idea how to script Hyperterminal under Windows. I know this can be done under the MacOS, but that wouldn't help you.
RS232 Datastream Format
mmmbsdddddbuuuuucl, where:
m Memory Location
s Sign (space or -) c Carriage Return
d Data with Decimal Point l Line Feed
u Units b Blank
The 15 character receive buffer is used internally in FullDuplexSerial to hold characters that have appeared on the serial line, but have not been read by your program by using rxcheck or rxtime or rx. These remove one character from the input buffer (if they're "successful" ... rx hangs until "successful"). Similarly, the 15 character transmit buffer holds characters produced by your program until there's time to transmit them. A program can easily produce characters faster than they can be sent. All of the transmit routines (dec, str, tx) will hang until there's room in the transmit buffer for the characters to be transmitted.
I currently have my transmitt connected to my recieve on the propeller. So i would expect to see an Ic on my video display.
{{ Prop Serial}}
CON
· _clkmode = xtal1 + pll16x
· _xinfreq = 5_000_000
VAR
· long MyStr [noparse][[/noparse]16]
· long Torque
OBJ
· SER·· :······ "FullDuplexSerial"
· TV··· :······ "tv_text"
· Num·· :······ "Numbers"
· Ext·· :······ "Extended_FDSerial"
PUB Main
·
· Num.init
· TV. start(12)
· TV.str(string("Start",13))
· TV.out(13)
· Ext.start (17,16,0,9600)
· Ext.SetDelimiter (",")
· repeat 30
··· Ext.rxflush
··· Ext.str(string("Ic,"))
··· Torque := Ext.RxStrTime(200,@MyStr)
······· TV.out (Torque)
··· waitcnt (clkfreq/10 + cnt)
· TV.str(string("End",13))
· Ext.stop
This is a duplicate thread...the original thread is located at the following link. In the future please follow up in your original thread rather than starting a duplicate thread.
http://forums.parallax.com/showthread.php?p=793318
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering