FullDuplexSerial & Inverting data via "TX"
JMLStamp2p
Posts: 259
Hello,
Is there a simple command that would invert the data sent via FullDuplexSerial
Excluding the Mode command?
My situation is that I have "2" Trancievers attached to two seperate Prop boards. I have to give the transmitting end a Mode "1" to Transmit correctly and
the recieving end a mode "2" to recieve correctly. The reason for this is that I have a pair of N-Channel MOSFETS on each board to accomplish the RS232 level conversions interfacing to the Prop. I can transmit to the recieving end and the recieving end will ack. and transmit a code back but when I recieve it back the data is inverted. I have looked through the manual and did not see a command to invert the byte before it is used in FullDuplexSerials TX method but may be overlooking it.
Thanks for any help,
JMLStamp2p
Is there a simple command that would invert the data sent via FullDuplexSerial
Excluding the Mode command?
My situation is that I have "2" Trancievers attached to two seperate Prop boards. I have to give the transmitting end a Mode "1" to Transmit correctly and
the recieving end a mode "2" to recieve correctly. The reason for this is that I have a pair of N-Channel MOSFETS on each board to accomplish the RS232 level conversions interfacing to the Prop. I can transmit to the recieving end and the recieving end will ack. and transmit a code back but when I recieve it back the data is inverted. I have looked through the manual and did not see a command to invert the byte before it is used in FullDuplexSerials TX method but may be overlooking it.
Thanks for any help,
JMLStamp2p
Comments
................................................
My Recieve code fragment below:
................................................
PUB Recieve | rxbyte
repeat
rxbyte := data.rx
if rxbyte == 2
Data_Recieved_1
if rxbyte == 5
Data_Recieved_4
..................................
theByte := theByte ^ $FF
or shorter: theByte ^= $FF
Andy
I got it working by bypassing the MOSFET on the Transmit out line. Andy, I will experiment with your code statement and appreciate your help as always !
Mike, I was having to use different Modes in the Transmitter and Reciever Props until I changed the configuration of my hardware. Now I am using Mode-2 on both ends and everything is working fine, thanks for your help as it is always appreciated as well.
JMLStamp2p
JMLStamp2p