Hi
I´m having trouble reading from COM1, writing works like a charm but I´d
like to be able to read the output from a switch or a router in order to
determine that the command was succesful and the configuration actually
went fine :-)
doin´:
$fp = fopen("COM1", "rwb");
fwrite($fp, $username . "\r\n");
if($response == 'password')
works, using hyperterminal shows that I´m logged in and i can actually
config the device as I want, but if I try to do something like :
$fp = fopen("COM1", "rwb");
fwrite($fp, $username . "\r\n");
$response = fread($fp, 4096);
if($response == 'password')
fwrite($fp, $password . "\r\n");
else {
print "no response?";
exit;
}
this is where it ends. Anyone got an idea?
Sincerly
Kim Madsen