Re: COPILOT Glucose Meter COM problem

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

 



On Fri, 2011-11-11 at 12:42 -0600, williambuell wrote:
> I am a 62 year old beginner in Ubuntu. Thanks for any help, guidance, suggestions on this problem!
> 
> I have used commands like the following to be certain that I have an active com port: 
> dmesg | grep ttyS
>
This won't necessarily tell you anything useful for several reasons. The
prime one is that the default kernel parameters always
create /dev/ttyS[0-3] regardless of whether your computer has any serial
ports or not. The secondary reason is that, some time back you were
right and reading through /var/log/messages showed serial ports
(referred to as UARTS and normally with a hardware type of 16550) but
more recent kernels don't do this - probably since UDEV device
management became the norm. Neither of my systems (a laptop with serial
ports, the other with 6 serial ports installed) give any grep hits for
ttyS, UART or 16550  regardless of whether I use dmesg to feed grep or
simply run 

	grep ttyS /var/log/messages*

The best way I know to find real serial ports is to use setserial with
the -a option, which tells it to report on the state of the port without
doing anything else. Here are a couple of examples:

The first is on the machine with serial ports installed:
# setserial -a /dev/ttyS0
/dev/ttyS0, Line 0, UART: 16550A, Port: 0x03f8, IRQ: 4
	Baud_base: 115200, close_delay: 50, divisor: 0
	closing_wait: 3000
	Flags: spd_normal skip_test

The second is on the laptop, which has no serial ports:
# setserial -a /dev/ttyS0
/dev/ttyS0, Line 0, UART: unknown, Port: 0x03f8, IRQ: 4
	Baud_base: 115200, close_delay: 50, divisor: 0
	closing_wait: 3000
	Flags: spd_normal skip_test

The clue is the on the first line of setserial output: if it says "UART:
unknown" then you're looking at one of the kernel's imaginary serial
ports while if it says "UART: 16550A" or similar, you've found one which
is mapped onto actual physical hardware and which, hopefully, has an
accessible D-9 connector attached to it.

I'm able to use any of my serial ports (/dev/ttyS[0-5]) from a Wine
application without needing any symlinks: the application can find them
directly, but the same application has never been able to find a known
good USB serial adapter (supplied by pfranc some time back and used
successfully with the Linux programs kermit and minicom) but, of course, 
ymmv.


Martin






[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux