LF: TI protocol -- it's not what [some of] you think it is!


[Prev][Next][Index][Thread]

LF: TI protocol -- it's not what [some of] you think it is!



Just so all of you know, the TI link protocol is *nothing* like RS-232. In
a few words, this is because TI calculators do not have precise timing
circuits; instead, they use resistor / capacitor loops for timing. Now let
me explain.


RS-232 has one line for transmission, and one line for reception. Data can
flow through both simultaneously (full duplex); the two lines are
independent of one another. Data is sent as a continuous stream of bits,
punctuated by stop bits (and parity bits in some cases). Whether a bit is 0
or 1 is determined by whether the voltage is HI or LO. The data *must* be
sent at a precise speed; the stop bit allows for at most a 5% error in the
baud rate.


The TI protocol is totally different from RS-232. Both of the data lines
are for transmission and reception. When the link is idle, both output
lines send out LO voltage. To send a bit, the sender sets either the red or
the white line to HI, depending on whether the bit is 0 or 1. The receiver
then echoes the bit back the same way it was sent; once the sender receives
the echo, it then sets both output lines to LO. Read TI-PROT.TXT (available
from ticalc.org) for the exact details of the protocol.


Notice that the TI protocol is speed independent; it has no preset baud
rate. This is absolutely necessary. Otherwise, if a calculator with fresh
batteries tried to send data to a calculator with low batteries, the
difference in speed would be likely be far beyond any reasonable tolerance
level. Of course, I'm only guessing that this was TI's rationale for not
using RS-232. Personally, I think they should have put quartz crystals in
their calculators.


I'll close by adding one other note. While the TI-85 had to handle every
low-level detail of the TI protocol in software, the TI-92 does it all in
hardware. You can actually send or read a byte just by writing or reading a
whole byte to or from a specific I/O port. This is why sound may be
impossible on the TI-92, unless there are other ports for directly
manipulating the link output lines.




<pre>
---
David Ellsworth
the ticalc.org project
davidell@ticalc.org
<pre>
---
</pre>