Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

SSDP to my Roku

$
0
0

i am trying to ping my roku to see if its online so i can send some remote commands to it via telnet...

 

what i have so far is this BUT its not coming back anything:

Plain Text         
#include <AutoItConstants.au3> #include <Constants.au3> $getInfo = _GetDOSOutput("M-SEARCH * HTTP/1.1" & @CRLF & "HOST: 239.255.255.250:1900" & @CRLF & "ST:roku:ecp" & @CRLF & "MAN:""ssdp:discover""" & @CRLF & "MX:10" & @CRLF & @CRLF) ConsoleWrite($getInfo  & @CRLF) Func _GetDOSOutput($sCommand)     Local $iPID, $sOutput = ""     $iPID = Run('"' & @ComSpec & '" /c ' & $sCommand, "", @SW_SHOW, $STDERR_CHILD + $STDOUT_CHILD) ConsoleWrite($iPID  & @CRLF)     While 1         $sOutput &= StdoutRead($iPID, False, False) ConsoleWrite($sOutput  & @CRLF)         If @error Then    ConsoleWrite("you have a error"  & @CRLF)             ExitLoop         EndIf         Sleep(10)     WEnd     Return $sOutput  EndFunc   ;==>_GetDOSOutput

Also all the info i want is returned the IP address that should come something back like this:
 

Location: http://192.168.1.134:8060/

any idea(s) what i am doing wrong here? 

 


Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>