| [reply] |
kfiryaar:
Well, which is it CommPort or SerialPort? ;^)
Seriously, though, show a bit of code so we can get a clue. Even if I had the package installed on my machine, I wouldn't have a way to reproduce the problem without some code to do so.
Generally when using a well-used module, you can assume that any errors are on your side of the fence, which is another reason it would be good to show some code.
...roboticus | [reply] |
| [reply] |
| [reply] |
Comments in RED:
$PortName = "COM24";
$PortObj = new Win32API::CommPort ($PortName)
|| die "Can't open $PortName: $^E\n";
# die if the modem is mapped to port that is higher then 9 ("COM24" here).
# "query modem" using device manager is successful.
# When I re-assign the modem port to "COM4", the new works just fine.
$ob->baudrate(38400);
$ob->parity("none");
$ob->parity_enable(1); # for any parity except "none"
$ob->databits(8);
$ob->stopbits(1);
$ob->handshake('rts');
my $baud = $ob->baudrate;
print "baud from configuration: $baud\n";
$ob->write("ATE0X4\r");
sleep 1;
my $result = $ob->input;
print "result = $result\n";
undef $ob;
Thanks,
Kfir
| [reply] |