I’m trying to use RS232 to read data from a GPS receiver using serial port C. The RS232 sentences happen in bursts with a space of 160mS between the bursts.
I’ve verified that I have gotten serial C setup correctly, and can transmit exactly what I think I’m transmitting. But when I read the serial interface I get completely random junk data. It appears as though its not starting to read at the start of the serial stream, and instead just starting in the middle. Then the hex codes I’m seeing are just flat out impossible for the ASCII string that I know should be there.
once I do serCread() then print out the first 16 bits, despite what I see on my oscilloscope screen is definitely the start of the NMEA code ‘$’ , I have never gotten a 24 code to show up, ever.
Can anyone tell me how I’m supposed to synchronize the start of an async RS232 communication? I mean I want it to be async, but I also want it to start at the right time! right?