Re: RS-232 Digital thermometer - interface and driver

From: Frank da Cruz (fdc_at_columbia.edu)
Date: 05/12/04


Date: 12 May 2004 17:54:11 GMT

On 2004-05-12, Floyd L. Davidson <floyd@barrow.com> wrote:
: keith_rhodes@yahoo.com (Keith) wrote:
:
:>Maybe this weekend, if I'm lucky, I'll try things like echo K >>
:>/dev/thermometer to see if I get back the model number.
:
: ...actually, rather than just echo, I'd suggest either using
: kermit, minicom, or seyon. Those are "modem" programs, and with
: each you will be able to see data coming back. If you put the
: modem program into a debug mode where it prints *all* received
: data as hex, you can then actually decipher what the response is
: too. But the big advantage of a modem program for initial
: testing is that you can change the serial port configuration
: easily.
:
: Once you get that working, all you need to do is write a simple
: C program to send commands and display results... ;-)
:
If you use C-Kermit:

  http://www.columbia.edu/kermit/ckermit.html

you won't have to write a C program, nor will you have to learn all
about the peculiarities of serial ports and drivers in this or that
version of Linux or Unix or any other OS. C-Kermit is not only a
modem program (and a Telnet client, FTP client, etc etc) but also a
programming language designed for communications applications just
like this one. Here, for example, is a Kermit program for executing
Telocator Alphanumeric Protocol for alphabenumeric paging:

  ftp://kermit.columbia.edu/kermit/scripts/ckermit/alphapage

This is a rather complex example, but it illustrates many of the
features of the language, and its abstraction of the underlying
i/o details. For a programming tutorial and a library of examples,
see:

  http://www.columbia.edu/kermit/ckscripts.html

- Frank