FullDuplexSerial Stop Bits
I'm using the Parallax Full Duplex Serial object and have noticed that when transmitting, it uses two stop bits. I would like to modify the code to send only one stop bit but of course I don't know assembly programming. Anybody have an answer for me (other than learning assembly)?
All help appreciated
Tom
All help appreciated
Tom

Comments
Usually it's not a problem if 2 stop bits are transmitted as most applications are not trying to push the limits of a already limited communications medium. The FullDuplex object does not actually send 2 stop bits but it effectively does so because it transmits an idle bit before the start bit. The code snippet around line 252 (comments added) shows that a stop bit is appended with #$100 and then room is made for a start bit and a padding bit by shifting left 2 bits. The data is transmitted lsb first so the first bit is actually an idle bit.
or txdata,#$100 'Add a stop bit after the 8 data bits shl txdata,#2 'make room for a start bit plus a padding bit or txdata,#1 'force the padding bit to an idle/stop bit mov txbits,#11 'count 8 data + 1 stop + 1 start + 1 idle/stop mov txcnt,cntI haven't tried it but you could try this.
or txdata,#$100 'Add a stop bit after the 8 data bits shl txdata,#1 'make room for a start bit plus a padding bit mov txbits,#10 'count 8 data + 1 stop + 1 start mov txcnt,cnt*Peter*
I'll give it a try.
Tom
Thanks Again Peter. I'm not making the change for speed but for compatability.
Tom
Tom