Hi all , how can i put this into a device
lets say i want baby tv in an device (T1)
how can i do that ?
the url is this one
http://192.168.0.35/web/subservices
this is the response from above url
i found a script on another topic but it doesnt write to the device
i get an error
lets say i want baby tv in an device (T1)
how can i do that ?
the url is this one
http://192.168.0.35/web/subservices
this is the response from above url
Code:
<e2servicelist> <e2service> <e2servicereference>1:0:1:15BC:7ED:2:11A0000:0:0:0:</e2servicereference> <e2servicename>BabyTV</e2servicename> </e2service> </e2servicelist>
i found a script on another topic but it doesnt write to the device
i get an error
PHP Code:
Error 1 Running script C:\Program Files (x86)\HomeSeer HS3\scripts\skype_unknown.vb :Exception has been thrown by the target of an invocation.Conversion from string "t1" to type 'Integer' is not valid.
Code:
Sub Main(parms As Object) Dim Is_URL As String Dim Is_page As String Dim Is_start As String Dim Is_eind As String Dim Is_MyPos As Integer Dim Is_lengte As Integer Dim Is_script As String Dim debug As Integer Dim Is_DS As String debug = 0 Is_script = "dbtest" Is_URL = "192.168.0.35" Is_page = "/web/subservices" Is_start = "<e2servicename>" Is_eind = "</e2servicename>" Is_DS = "T1" Is_page = hs.GetURL(Is_URL, Is_page, False, 80) If debug = 1 Then hs.SaveINISetting(Is_script, "XXXXXXXXfull page", Is_page, "my_gets.ini") Is_lengte = len(Is_start) If debug = 1 Then hs.writelog("Is_lengte:", Is_lengte) Is_MyPos = Instr(Is_page, Is_start) Is_MyPos = Is_MyPos + Is_lengte If debug = 1 Then hs.writelog("Is_MyPos:", Is_MyPos) Is_page = mid(Is_page, Is_MyPos) If debug = 1 Then hs.SaveINISetting(Is_script, "XXXXXXXXright page length", Is_MyPos, "my_gets.ini") If debug = 1 Then hs.SaveINISetting(Is_script, "XXXXXXXXright page", Is_page, "my_gets.ini") Is_MyPos = Instr(Is_Page, Is_eind) 'Returns the position of the first occurrence of one string within another. If debug = 1 Then hs.writelog("Is_MyPos end:", Is_MyPos) Is_page = mid(Is_page, 1, Is_MyPos - 1) If debug = 1 Then hs.SaveINISetting(Is_script, "XXXXXXXXfinal page right", Is_MyPos, "my_gets.ini") If debug = 1 Then hs.SaveINISetting(Is_script, "XXXXXXXXfinal page", Is_page, "my_gets.ini") If Is_page <> hs.DeviceString(Is_DS) Then hs.SetDeviceString(Is_DS, Is_page, True) End If end sub
Comment