The elephant project is done, but...
Del Ogren
Posts: 7
Friends.
Due to some minor technical problems, and human scheduling confusions,
I now have a bit of·time to add some bells and whistles to the elephant project.
Does anyone have a trick for detecting whether or not a serial cable
is connected?
I'd like to do that to make the user interface a bit more friendly.
Like:
If plugged in = yes
· goto menu
else
· goto just-run
Any ideas?
tnx,
--del
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Which end do end-users use?
·
Due to some minor technical problems, and human scheduling confusions,
I now have a bit of·time to add some bells and whistles to the elephant project.
Does anyone have a trick for detecting whether or not a serial cable
is connected?
I'd like to do that to make the user interface a bit more friendly.
Like:
If plugged in = yes
· goto menu
else
· goto just-run
Any ideas?
tnx,
--del
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Which end do end-users use?
·
Comments
If you have a terminal connected, when you see the prompt enter a 'return'. If the SERIN doesn't time-out, output the menu. If it DOES time out, you're running stand-alone, and should run your program.
I thought about doing it that way. But I didn't like the notion of the user having to wait
for a timeout in stand alone mode. That and adding another LED to to the box that
says, "OK I'm ready to work now." Though that's what I might end up having to do.
But then I started doing what we all dread, RTFM....
The schematic for the carrier board seems to indicate a loop-back on pins 6 and 7
(DSR and RTS ?) of the DB 9 connector. Has anyone tried looking at the voltage
on that loop-back to determine if a host computer is attached? I might study that
a bit later this evening.
And, I suppose I gotta ask the end users if they want it to be done at all...
--del
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Which end do end-users use?
·
The loopback on pins 6 and 7 is 'hard-wired' close to the connector, but I suppose you could add a jumper resistor (of 22 Kohms) to read that voltage. Clever.