DAHUA IP getting PTZ coordinates

Jan 15, 2017
2
0
Hello , I'm a Newbie
icon_smile.gif


I just want to know how can I get PTZ coordinates like : P:230° , T: 45° , Z: x8 instantly with distant access from a PC.

I just figure out how to connect with the telnet protocol to the camera. But I don't know if it help.

just want using the information in an external program that i'm developping.
 
Code:
/cgi-bin/ptz.cgi?action=getStatus
status.Focus.FocusPosition=3510.000000
status.Focus.Status=Unknown
status.Iris.IrisValue=0.250000
status.Iris.Status=Idle
status.MoveStatus=Idle
status.PTS=0
status.Postion[0]=238.800000
status.Postion[1]=9.000000
status.Postion[2]=128.000000
status.PresetID=0
status.Sequence=0
status.UTC=0
status.ZoomStatus=Idle
status.ZoomValue=280

Code:
/cgi-bin/ptz.cgi?action=start&channel=0&code=PositionABS&arg1=[HPOS]&arg2=[VPOS]&arg3=[ZOOM]&arg4=[SPEED]

http://contenidosdigitales.net/plan...entas/api/DAHUA_HTTP_API_FOR_IPC&SD-V1.36.pdf
 
Code:
/cgi-bin/ptz.cgi?action=getStatus
status.Focus.FocusPosition=3510.000000
status.Focus.Status=Unknown
status.Iris.IrisValue=0.250000
status.Iris.Status=Idle
status.MoveStatus=Idle
status.PTS=0
status.Postion[0]=238.800000
status.Postion[1]=9.000000
status.Postion[2]=128.000000
status.PresetID=0
status.Sequence=0
status.UTC=0
status.ZoomStatus=Idle
status.ZoomValue=280

Code:
/cgi-bin/ptz.cgi?action=start&channel=0&code=PositionABS&arg1=[HPOS]&arg2=[VPOS]&arg3=[ZOOM]&arg4=[SPEED]

http://contenidosdigitales.net/plan...entas/api/DAHUA_HTTP_API_FOR_IPC&SD-V1.36.pdf

I bow to your nerdness.
 
Code:
/cgi-bin/ptz.cgi?action=getStatus
status.Focus.FocusPosition=3510.000000
status.Focus.Status=Unknown
status.Iris.IrisValue=0.250000
status.Iris.Status=Idle
status.MoveStatus=Idle
status.PTS=0
status.Postion[0]=238.800000
status.Postion[1]=9.000000
status.Postion[2]=128.000000
status.PresetID=0
status.Sequence=0
status.UTC=0
status.ZoomStatus=Idle
status.ZoomValue=280

Code:
/cgi-bin/ptz.cgi?action=start&channel=0&code=PositionABS&arg1=[HPOS]&arg2=[VPOS]&arg3=[ZOOM]&arg4=[SPEED]

http://contenidosdigitales.net/plan...entas/api/DAHUA_HTTP_API_FOR_IPC&SD-V1.36.pdf

I Love youuuu nayr ! :p
Is it possible to use this commands in the P2P connexion. And how ?
 
Last edited:
you had a space that got escaped ldasilva, remove that %20
 
  • Like
Reactions: hmjgriffon
take all those brackets out

Code:
http://admin:admin@192.168.200.41/cgi-bin/ptz.cgi?action=start&channel=0&code=GotoPreset&arg1=0&arg2=2&arg3=0

works for me
 
Oh, thanks Nayr! The getStatus command did not exist back when I was tinkering with a custom panorama ptz control interface -- it would have been very handy to be able to query the camera for its current position.
 
Nayr,

You gave the action getStatus in this post. It's not in the API doc. How did you find it? Is there a way to query the camera for a list of commands?