Can't get snapshot via URL

Stimpy68

n3wb
Joined
Jul 2, 2017
Messages
3
Reaction score
0
Location
The Netherlands
Hi there,

I just bought a DH-SD22204T-GN, and it works great, but I have one issue with it. I can't seem to get a snapshot via an URL : cgi-bin/snapshot.cgi?1. When I try this on a Linux cli I get:

Connecting to xxx.xxx.xxx.xxx:80... connected.
HTTP request sent, awaiting response... 500 Internal Server Error
2017-07-02 19:05:07 ERROR 500: Internal Server Error.

I'm runnig:

Software Version2.422.0000.3.R.4.484, Build Date: 2016-11-21
WEB Version3.2.1.396840
ONVIF Version2.42

Any ideas?
 
Joined
Aug 3, 2015
Messages
3,829
Reaction score
12,293
Location
Charlotte
I presume you're using the 'curl' command to send your request.
Please post the entire command you're using.

Here's what works with my Dahua turret cameras. That's a capital letter O before snapshot.jpg.
Code:
$ wget 'http://user:password@192.168.1.nnn:1234/cgi-bin/snapshot.cgi?1' -O snapshot.jpg
 
Last edited:
Joined
Aug 3, 2015
Messages
3,829
Reaction score
12,293
Location
Charlotte
I usually refer to this page for iSpy and they show the same URL you're using. It's possible the camera's firmware may require different syntax for the username and password. Try this instead:
Code:
$ wget 'http://192.168.1.nnn:1234/cgi-bin/snapshot.cgi?loginuse=username&loginpas=password' -O snapshot.jpg
 

Stimpy68

n3wb
Joined
Jul 2, 2017
Messages
3
Reaction score
0
Location
The Netherlands
Okay, I emailed the shop I bought it from and they gave me the URL. I checked it multiple times, but it seems to be I tried it serveral times without succes, but now it seems to work? Very strange....

The correct URL is: http://username:password@192.168.0.123/cgi-bin/snapshot.cgi?1

Also got it working in Domoticz, doorbell pressed = snapshot in the mail :-D Now find a way to make the cam go to a specific preset and then make the snapshot when the doorbell is pressed. I have the URL for the preset working, just have to make things come together domoticz ;-)
 
Joined
Aug 3, 2015
Messages
3,829
Reaction score
12,293
Location
Charlotte
Don't feel too bad about it. I've done the same thing, trying a URL with slightly varying syntax, and even after twenty or thirty failures, suddenly something just works, when it clearly did not, earlier. Who knows? Not me, that's for certain.
 
Top