Synology Diskstation & Cameras

Ggggrrrr!

Just cannot get the app to connect and bring up the cameras, consistantly keep getting a ‘Connection Error - Network Tiem Out…’ Looking at the logs it apears not be finding any cameras which are all ONVIF and from reading above these issues were resolved. I have tried all the versions of the App and DH listed above including the latest by MATT (Thanks!) but just cannot get any further. All help appreciated! Thanks guys! :slight_smile:

10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:30: error java.lang.RuntimeException: bad character in base64 value @line 372 (locationHandler)
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=5GRONGsxhokeo14A0LWN131500&cameraId=9 HTTP/1.1
Accept: /
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=5GRONGsxhokeo14A0LWN131500&cameraId=9, options: [:]
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: debug getChildDevices(false), children=0
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace {“data”:{“audioOut”:false,“fisheyeParam”:{},“ptzContinuous”:true,“ptzHome”:true,“ptzPan”:true,“ptzPresetNumber”:255,“ptzTilt”:true,“ptzZoom”:true},“success”:true}
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset=“UTF-8”
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=5GRONGsxhokeo14A0LWN131500&cameraId=9 HTTP/1.1
Accept: /
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=5GRONGsxhokeo14A0LWN131500&cameraId=9, options: [:]
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: debug getChildDevices(false), children=0
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace {“error”:{“code”:400,“errors”:{“param1”:"",“param2”:""}},“success”:false}
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset=“UTF-8”
10bbbd25-0792-4985-8906-b90b7b0d2c71 18:27:29: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=5GRONGsxhokeo14A0LWN131500&cameraId=8 HTTP/1.1
Accept: /
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

I’m getting the same results as well.

Update: Decided to remove device handler and smartapp and start over. Still got errors trying to load two cameras, then read somewhere in this thread some cameras are problematic. So decide to use just one and everything works. Then setup the sms in synology and tested all ok. In my setup I can live with just the one camera sending alerts.

So which device handler you use now?
I have issues installing the snapshot server from @Matt_K1 locally on my NAS as described above.

Just cannot get mine to conect at all, returns zero children constantly. Disabled all cameras then enabed one at a time. Several have simple ONVIF configs yet they will just not pick up. To be honest I am a little confused as to why this should be an issue anyway after all the whole recording process happens on the DiskStation and we are simply just viewing via HTML. It would be great if someone looked at the App and DH but it is way beyond my capabilities.

Maybe I am missing something here!

I have not made any changes on the DS or SS. What is the Node JS and does anyone have detailed instructons as to exactly what I need to on the DS side PLEASE?

Thanks!

Hi @Matt_K1 I use your code published on Sep 8. It did solve the ‘time out’ problem. I still have issue with the motion detection setup. Following the in-app instructions and type 123-4567890 and click save on the page(just a ‘blank’ in first drop down). Then ‘send a text SMS message’, no success got back or screen updated in the app. I live in the US and will this be the case? Or do I need to put a +1 in the first drop down before phone number? But my SurveillanceStation client does not have that option, just ‘blank’ or a ‘+’. Thanks.

I really would be grateful for a little help here.

I simply cannot get it to complete a connection, it fails every time.
Is there anything I need to do/run on the DS itself please? Or is it all carried out on ST with the SmrtApp and DH?
The last few times it looks like it finds the details of one of the cameras but looks like it does not add it as a child and then soon after errors with a jave.RuntimeException.
Have attached the latest log below, sorry but as you know we cannot attach .txt files.

Appreciate you are all very busy but really would be grateful for some help here.
Thanks!

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: error java.lang.RuntimeException: bad character in base64 value @line 372 (locationHandler)
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=9 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=9, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace {"data":{"audioOut":false,"fisheyeParam":{},"ptzContinuous":true,"ptzHome":true,"ptzPan":true,"ptzPresetNumber":255,"ptzTilt":true,"ptzZoom":true},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=9 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=9, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace {"error":{"code":400,"errors":{"param1":"","param2":""}},"success":false}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:01 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:00 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=8 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:00 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=8, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:00 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:00 AM: trace {"error":{"code":400,"errors":{"param1":"","param2":""}},"success":false}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:52:00 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=8 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=8, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace {"data":{"audioOut":false,"fisheyeParam":{},"ptzContinuous":false,"ptzHome":false,"ptzPan":false,"ptzPresetNumber":0,"ptzTilt":false,"ptzZoom":true},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=8 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=8, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace {"error":{"code":400,"errors":{"param1":"","param2":""}},"success":false}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=7 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=7, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace {"error":{"code":400,"errors":{"param1":"","param2":""}},"success":false}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:57 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=7 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=7, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace {"data":{"audioOut":true,"fisheyeParam":{},"ptzContinuous":false,"ptzHome":false,"ptzPan":false,"ptzPresetNumber":0,"ptzTilt":false,"ptzZoom":false},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=7 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=7, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace {"data":{"offset":0,"total":0},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:56 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=4 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPatrol&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=4, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace {"data":{"offset":0,"presets":[{"id":1,"name":"home","type":1}],"total":1},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=4 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.PTZ&method=ListPreset&version=1&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=4, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace {"data":{"audioOut":false,"fisheyeParam":{},"ptzContinuous":true,"ptzHome":true,"ptzPan":true,"ptzPresetNumber":5,"ptzTilt":true,"ptzZoom":true},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=4 HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace {"data":{"cameras":[{"DINum":0,"DONum":0,"audioCodec":2,"channel":"1","dsId":0,"enableLowProfile":true,"enableRecordingKeepDays":true,"enableRecordingKeepSize":false,"fov":"","highProfileStreamNo":1,"id":4,"idOnRecServer":0,"ip":"192.168.0.118","lowProfileStreamNo":2,"mediumProfileStreamNo":1,"model":"Generic_ONVIF","newName":"PATIO5MPPTZ","port":80,"postRecordTime":5,"preRecordTime":5,"recordTime":30,"recordingKeepDays":30,"recordingKeepSize":"10","status":1,"stream1":{"bitrateCtrl":1,"constantBitrate":"0","fps":15,"quality":"5","resolution":"2592x1944"},"stream2":{"bitrateCtrl":1,"constantBitrate":"0","fps":15,"quality":"5","resolution":"704x576"},"tvStandard":0,"vendor":"ONVIF","videoCodec":3,"videoMode":""},{"DINum":0,"DONum":0,"audioCodec":2,"channel":"1","dsId":0,"enableLowProfile":true,"enableRecordingKeepDays":true,"enableRecordingKeepSize":false,"fov":"","highProfileStreamNo":1,"id":7,"idOnRecServer":0,"ip":"192.168.0.120","lowProfileStreamNo":2,"mediumProfileStreamNo":1,"model":"IPC-HDW4831EM-ASE","newName"...[TRUNCATED]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=GetCapabilityByCamId&version=4&_sid=CVlucQGxzUzho14A0LWN131500&cameraId=4, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:55 AM: trace DISKSTATION REPONSE TYPE: Content-Type: application/json; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Sending hub action: GET /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=List&version=9&_sid=CVlucQGxzUzho14A0LWN131500& HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Requesting URL /webapi/entry.cgi?api=SYNO.SurveillanceStation.Camera&method=List&version=9&_sid=CVlucQGxzUzho14A0LWN131500&, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace {"data":{"sid":"CVlucQGxzUzho14A0LWN131500"},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace DISKSTATION REPONSE TYPE: Content-Type: text/plain; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Sending hub action: GET /webapi/auth.cgi?api=SYNO.API.Auth&method=Login&version=2&account=maccam&passwd=Szkoda11&session=SurveillanceStation&format=sid HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Requesting URL /webapi/auth.cgi?api=SYNO.API.Auth&method=Login&version=2&account=maccam&passwd=Szkoda11&session=SurveillanceStation&format=sid, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace {"data":{"SYNO.SurveillanceStation.ExternalRecording":{"maxVersion":3,"minVersion":1,"path":"entry.cgi","requestFormat":"JSON"}},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace DISKSTATION REPONSE TYPE: Content-Type: text/plain; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Sending hub action: GET /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.SurveillanceStation.ExternalRecording HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Requesting URL /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.SurveillanceStation.ExternalRecording, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace {"data":{"SYNO.SurveillanceStation.PTZ":{"maxVersion":5,"minVersion":1,"path":"entry.cgi","requestFormat":"JSON"}},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace DISKSTATION REPONSE TYPE: Content-Type: text/plain; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Sending hub action: GET /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.SurveillanceStation.PTZ HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace Requesting URL /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.SurveillanceStation.PTZ, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace {"data":{"SYNO.SurveillanceStation.Camera":{"maxVersion":9,"minVersion":1,"path":"entry.cgi","requestFormat":"JSON"}},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:54 AM: trace DISKSTATION REPONSE TYPE: Content-Type: text/plain; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: trace Sending hub action: GET /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.SurveillanceStation.Camera HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: trace Requesting URL /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.SurveillanceStation.Camera, options: [:]
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: debug getChildDevices(false), children=0
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: trace {"data":{"SYNO.API.Auth":{"maxVersion":6,"minVersion":1,"path":"auth.cgi"}},"success":true}
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: trace DISKSTATION REPONSE TYPE: Content-Type: text/plain; charset="UTF-8"
a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: trace Sending hub action: GET /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.API.Auth HTTP/1.1
Accept: */*
User-Agent: Linux UPnP/1.0 SmartThings
HOST: 192.168.0.200:5000

a8f5f8f1-b105-4dce-8314-77e745eb484d 11:51:53 AM: trace Requesting URL /webapi/query.cgi?api=SYNO.API.Info&method=Query&version=1&query=SYNO.API.Auth, options: [:]

Hi @Biubiubiubiubu. 123-4567890 appears correct, that part of the application did not change. What is important though, is to make sure that the SMS notification text has the string “Motion in %CAMERA%” . When you follow the instructions to set up motion detection in the DiskStation Connect app, it prompts you to:


Now click on the Settings tab in the Nofications window
Go to the Camera section of this pane and then check SMS for Motion Detected"
With the Motion Detected row highlighted, choose Edit and then Edit Notification from the top left of this pane
Put the following text into the Subject line and choose Save
Motion in %CAMERA%

This is super-important because the app works by parsing the text in the SMS notification. If the SMS notification from Synology does not have this text, then the motion detection notification will not be processed by the DiskStation SmartApp on the Smartthings side. Hopefully this made sense :slight_smile:

I got this working myself. @chippie, it is important to follow the instructions for the SMS setup. The newer SS UI forces you to save changes first before you can send test message. Just because the test SMS message works doesn’t mean the motion SMS messages will work because they depend on the exact text as per instructions. Also make sure you do not enable any type of SMS rate limiting. I should report I am on the latest software version, and had to use port 5000, while I typically use 5001 that did not seem to work.

I plan to make updates and get the video working on this if others are interested? I had mostly Foscam devices and have a Foscam DH, however I decided to get Amcrest cam and found out after the fact that firmware no longer supports mjpeg streaming without a 2 step process, which makes it close to useless on it’s own. So I thought why not hook into SS API as standard interface and use whatever cams are supported thru SS, without custom apps/software for each kind.

I’ve already updated the DH to show motion as it’s primary status.

2 Likes

Thank you for taking the time to reply.

Unfortuantely, I cannot even get that far. Simply searching for cameras fails once I enter the details in Smartthings. It goes no further, it just comes back with a TimeOut error.

Is there anything I need to do/install on the Synology itself or anything I need to make sure is enabled/disbalbed there please?

EDIT: Also which app and DH are the best ones to use please?

Do you use https to login by any chance?
https doesn’t work, you need to use http.

Also double authentication doesn’t work

No and no… :frowning:

It just will not get past the login as per the logs attached above.

I am not a coder, but if you look in the code, you see the error appears when it reaches the camera preset.
Maybe the issue is with the PTZ presets/patrols in case you have them configured?
I do not have PTZ cameras at home so I can’t be sure.

I use the version of @Matt_K1 from September 8th that doesn’t use the local file server since I couldn’t install the local fire server on my NAS

I use the Classic SmartThings app, and am using the latest from @Matt_K1 repo. I have not setup the local file server, that doesn’t need to be done to detect/configure cameras and motion detection.

@chippie Looking at your logs, it looks to be failing on your camera with cameraId=9. What is the actual camera name? I wonder if you have bad chars in one or your camera names? The logs have it truncated. I think there were bugs that were fixed related to this that maybe only some run into. I would try using the latest code from the @Matt_K1 repo. I rather not have to setup a local server for taking snapshots, and I have another DH for Foscam that has the native stuff working, so I should be able to figure it out over time, just will take me a bit to get to it. I want to make the code work with both based on config.