Hi guys, okay, so this isn't telephony related but judging from the search I just did, there are more people in the VoIP groups with tcl scripting experience than in the wan/lan group where this probably belongs.
So what I'm trying to do is have my router use Tcl to pull down a webpage from a cable modem.
Here's my code so far.
set sock [socket 192.168.100.1 80]
puts $sock "GET /signaldata.htm HTTP/1.0\n\n"
flush $sock
set result [ gets $sock ]
puts stdout "OUTPUT:\n$result"
set exit_msg "closing socket"
close $sock
It doesn't work. All I get is:
OUTPUT:
I know the URL works because I can pull it up fine from my browser and a telnet to port 80 from the router itself also opens the socket for a brief moment.
Can anyone tell me what I'm doing wrong?
Thanks