Open hamsterrrr opened 4 years ago
Hi
Try to use the Download option. For me it does not work, the script does not want to enter if (defined ($ decoded -> {'OPFileQuery'})) {
Regards
decode_json exception - its a key for solution. if use in sub PrepareGenericCommand after line
print " err $@\n"; we can see a errror - Undefined subroutine &IPcam::decode_json called at ./sofiactl.pl
there is wrong usage decode_json in subroutine.
Hi,
I can find the record video by command OPFileQuery now, it returns json data like :
{ "BeginTime":"2021-08-17 00:00:00", "DiskNo":0, "EndTime":"2021-08-17 01:00:00", "FileLength":"0x000B656D", "FileName":"/idea0/2021-08-17/001/00.00.00-01.00.00[H][@2905d][3].h264", "SerialNo":0 }
Now i want to view this record via VLC, so my question is : +) follow this FileName, how can i get stream url without downloading the video. +) if not anyway else ?
Thanks,
I get this
./sofiactl.pl --user admin --pass 'password' --host 192.168.100.9 --port 34567 --command OPFileQuery --bt '2020-10-21T00:00:00Z' --et '2020-10-21T00:30:00Z' -ch 0 --dl
decode_json exception. data:{ "AliveInterval" : 21, "ChannelNum" : 8, "DeviceType " : "HVR", "ExtraChannel" : 0, "Ret" : 100, "SessionID" : "0x00000041" }
decode_json exception. data:{ "Name" : "OPFileQuery", "OPFileQuery" : [ { "BeginTime" : "2020-10-21 00:10:20", "DiskNo" : 0, "EndTime" : "2020-10-21 00:10:29", "FileLength" : "0x000006E3", "FileName" : "/idea0/2020-10-21/001/00.10.20-00.10.29[M][@71a][0].h264", "SerialNo" : 0 } ], "Ret" : 100, "SessionID" : "0x41" }