[ILUG] Reverse engineering serial protocol
daledunlea at commergy.com
Fri Oct 1 10:28:48 IST 2004
> > The first thing I need to do is verify the baud rate. I
> suspect that
> > it is 9600 8N1, but have no way of being sure. Does anyone
> know of a
> > way to verify the baud-rate/data/parity/stop-bits for an RS232
> > interface that doesn't require an oscilloscope?
> > I've tried listening with minicom, and wrote a program to
> read bytes
> > from /dev/ttyS0 and print them to the screen in the hope of
> > readily apparent, but no joy so far. My next step is to connect an
> > RS232 cable from my linux box to my windows laptop that has the
> > drivers installed, sned it some characters, and see what the mouse
> > pointer does.
> I know you say you've tried minicom, but have you tried all
> the baud rate/stop-start-bit combinations? By varying these
> you should be able to find out the serial parameters that the
> screen is using.
I have tried a whole range of these, but minicom outputs data regardless
of which baud rate I use, so it's hard to know what the "right" setting
is seeing as how they all produce data.
> The screen won't necessarily be outputting
> regular ol' ASCII though. I don't know if minicom is cable
> of displaying output in hex, but according to google GTKTerm
> (a hyperterm clone) is. Cian
The program I wrote that reads from /dev/ttyS0 outputs as binary, hex,
and decimal. Binary seems to be offering me something approaching a clue
in that the last byte read is always equal to the second-last byte read,
but with bit 6 negated. This consistency is leading me to believe that I
may be on the right track, but so far, it is all guess-work.
More information about the ILUG