#!perl use strict; use warnings; use Win32::SerialPort; my $port = Win32::SerialPort->new( "COM4" ); $port->user_msg(1); # misc. warnings $port->error_msg(1); # hardware and data errors $port->baudrate(19200); $port->databits(8); $port->stopbits(1); $port->parity("none"); $port->read_const_time(1000); #$port->stty_clear("0"); $port->pulse_dtr_on(300); $port->write_settings; my $baud = $port->baudrate; my $parity = $port->parity; my $data = $port->databits; my $stop = $port->stopbits; my $hshake = $port->handshake; print "B = $baud, D = $data, S = $stop, P = $parity, H = $hshake\n"; undef $port; __END__ liefert bei mir: B = 19200, D = 8, S = 1, P = none, H = rts