From: Sayre S. <sa...@qu...> - 2003-08-04 21:19:37
|
I am new to Expect. I am using it to control some serial devices that our company manufactures. They are connected on /dev/tty ports directly as RS232 devices. I open the port using IO::File and then connect that handle to Expect. I have a problem where Expect.pm occasionally closes the filehandle on the port giving the following message from the debug output: Waiting for new data (6 seconds)... handle id(3): new data. handle id(3): EOF handle id(3): closing... Returning from expect with TIMEOUT or EOF I have patched my problem by commenting out the $exp->hard_close(); on line 853 of Expect.pm - which I realize is a drastic step. What am I doing wrong? Why would expect decide to close my filehandle? What can I do about it so that I do not have to modify the Expect.pm program. Any help would be greatly appreciated. Thank you very much, Sayre Swarztrauber |