Guest_imported
New member
- Jan 1, 1970
- 0
Hi,
I am trying to use the "cu" command (UNIX command) in a script. With that, i want to send requests (AT, ATI, AT1...) to a modem, in a asynchron line, and I want to get the response back, in a file for example.
My pb is that it is impossible to get the response back.
And I don't know how to do...
For example, if, in shell, i use the command :
cu -l /dev/cua/b -s 9600 - b 8 > zzz
I can type the commands AT, ATI, AT1, and then ~. (to quit the connection by cu).
Then, if i look in the zzz file, i have
connected
AT
OK
ATI
...
...
Disconnected
I would like to integrate this in a perl script, and moreover i want to get the word "OK" for example...
Can anyone help me ?????
I am trying to use the "cu" command (UNIX command) in a script. With that, i want to send requests (AT, ATI, AT1...) to a modem, in a asynchron line, and I want to get the response back, in a file for example.
My pb is that it is impossible to get the response back.
And I don't know how to do...
For example, if, in shell, i use the command :
cu -l /dev/cua/b -s 9600 - b 8 > zzz
I can type the commands AT, ATI, AT1, and then ~. (to quit the connection by cu).
Then, if i look in the zzz file, i have
connected
AT
OK
ATI
...
...
Disconnected
I would like to integrate this in a perl script, and moreover i want to get the word "OK" for example...
Can anyone help me ?????