Strange serial input format to code ... suggestions please
Chuck D.
Posts: 3
I've been working with the BS2 for a few months and am working up a prototype of a bridge between two common marine electronics communications protocols: SeaTalk and NMEA-0183.
Per a reference on SeaTalk at http://www.thomasknauf.de/rap/seatalk1.htm#Ser, SeaTalk transmits
11 bits for each character:
# 1 Start bit (high)
# 8 Data Bits (least significant bit transmitted first)
# 1 Command bit, set on the first character of each datagram. Reflected in the parity bit of most UARTs. Not compatible with NMEA0183 but well suited for the multiprocessor communications mode of 8051-family microcontrollers (bit SM2 in SCON set).
# 1 Stop bit (low)
I'm curious if anyone has attempted to recieve and/or transmit characters with such non-standard data transmission schemes, whether reading and writing such characters is possible with SERIN/SEROUT (or something else), and if so, HOW??
Per a reference on SeaTalk at http://www.thomasknauf.de/rap/seatalk1.htm#Ser, SeaTalk transmits
11 bits for each character:
# 1 Start bit (high)
# 8 Data Bits (least significant bit transmitted first)
# 1 Command bit, set on the first character of each datagram. Reflected in the parity bit of most UARTs. Not compatible with NMEA0183 but well suited for the multiprocessor communications mode of 8051-family microcontrollers (bit SM2 in SCON set).
# 1 Stop bit (low)
I'm curious if anyone has attempted to recieve and/or transmit characters with such non-standard data transmission schemes, whether reading and writing such characters is possible with SERIN/SEROUT (or something else), and if so, HOW??
Comments
But no, the BS2 is pretty limited in its RS-232 byte interpretation. 8N1, or 7E1 (8-data, no parity, 1 stop bit), (7-data, even parity, 1 stop bit). Okay, with inter-byte delays you can add 'stop' bits, but that's about it.
Typically one would use a co-processor programmed for the right protocol to recieve this.
My incoming signal was 8Odd1 and the stamp just seems to ignore the parity bit and correctly decode the data.
As long as that Command bit doesn't do anything, you should be able to get the data.
Cheers
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Don't visit my new website...