DAHUA PTZ Camera control Presets with command line in terminal, and Node-Red

DAHUA PTZ Camera control Presets with command line in terminal window This command line work in terminal window:
Preset 2:
curl --digest -u "admin:password" -g "http://192.168.0.109:40003/cgi-bin/ptz.cgi?action=start&channel=0&code=GotoPreset&arg1=0&arg2=2&arg3=0"
Preset 3:
curl --digest -u "admin:password" -g "http://192.168.0.109:40003/cgi-bin/ptz.cgi?action=start&channel=0&code=GotoPreset&arg1=0&arg2=3&arg3=0"
Preset 4:
curl --digest -u "admin:password" -g "http://192.168.0.109:40003/cgi-bin/ptz.cgi?action=start&channel=0&code=GotoPreset&arg1=0&arg2=4&arg3=0"

For node-red use command HTTP REQUEST and modify:
URL:
http://192.168.0.108:40001/cgi-bin/ptz.cgi?action=start&channel=0&code=GotoPreset&arg1=0&arg2=2&arg3=0
Use authentication:
Type: Digest authentication
User: username
Password: password

1 Like

can you please provide more information, i have dahua ptz and reolink camera’s , im trying to use reolink camera’s as a spotter camera’s to tell the ptza camera where’s the action.

your help is really appreciated and thank you in advance.