This is a pretty common thing to do. You should be able to detect RTS/CTS or DCD assuming as martell said the handshaking signals are supported by Device::SerialPort.
Update1: Looks like both modem control(DCD) and handshaking(RTS/CTS) are both supported.
if ($PortObj->can_wait_modemlines) { $rc = $PortObj->wait_modemlines( MS_RLSD_ON ); if (!$rc) { print "carrier detect changed\n"; } } if ($PortObj->can_modemlines) { $ModemStatus = $PortObj->modemlines; if ($ModemStatus & $PortObj->MS_RLSD_ON) { print "carrier detecte +d\n"; } }
# controlling outputs from the port $PortObj->dtr_active(T); # sends outputs direct to hard +ware $PortObj->rts_active(Yes); # return status of ioctl call # return undef on failure
James
There's never enough time to do it right, but always enough time to do it over...
In reply to Re: Need to detect continuity between 2 terminals
by jmlynesjr
in thread Need to detect continuity between 2 terminals
by redss
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |