vedendo il messaggio di errore ho spostato il comando che mi hai detto, nel secondo if, questo è il risultato
codice:Warning: Specified serial port is not valid in /var/www/php_serial.class.php on line 111 Warning: Unable to set the baud rate : the device is either not set or opened in /var/www/php_serial.class.php on line 204 Warning: Unable to set parity : the device is either not set or opened in /var/www/php_serial.class.php on line 254 Warning: Unable to set length of a character : the device is either not set or opened in /var/www/php_serial.class.php on line 298 Warning: Unable to set the length of a stop bit : the device is either not set or opened in /var/www/php_serial.class.php on line 335 Warning: Unable to set flow control mode : the device is either not set or opened in /var/www/php_serial.class.php on line 376 Warning: The device must be set before to be open in /var/www/php_serial.class.php on line 137 Warning: Device must be opened in /var/www/php_serial.class.php on line 541 object(phpSerial)#1 (7) { ["_device"]=> NULL ["_windevice"]=> NULL ["_dHandle"]=> NULL ["_dState"]=> int(0) ["_buffer"]=> string(1) "a" ["_os"]=> string(5) "linux" ["autoflush"]=> bool(true) } Warning: Device must be opened to read it in /var/www/php_serial.class.php on line 474

Rispondi quotando

