use Device::SerialPort; use Data::Dumper qw(Dumper); my $port = Device::SerialPort->new("/dev/ttyUSB3"); $port->baudrate(115200); # Configure this to match your device $port->databits(8); $port->parity("none"); $port->stopbits(1); $port->lookclear;