I have tried to use the serial port ttyS0 to connect to an UPS. To test the port, I checked it with minicom and the latter returned the message “serial port locked”.
I run the following commands:
dmesg | grep tty
console [tty0] enabled
serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
00:09: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
0000:00:03.3: ttyS1 at I/O 0x3440 (irq = 17) is a 16550A
cat /proc/tty/driver/serial
serinfo:1.0 driver revision:
0: uart:16550A port:000003F8 irq:4 tx:266548 rx:3 brk:3
1: uart:16550A port:00003440 irq:17 tx:0 rx:0 CTS|DSR|CD
2: uart:unknown port:000003E8 irq:4
3: uart:unknown port:000002E8 irq:3
setserial /dev/ttyS0 -G
/dev/ttyS0 uart 16550A port 0x03f8 irq 4 baud_base 115200 spd_normal skip_test
The results seem to indicate that all is correct. But the port is locked! What is wrong?
Any help would be greatly appreciated by a new Linux user.