Example PTZ control script with start/stop type events

Forum for questions and support relating to the 1.27.x releases only.
Locked
TheKorn
Posts: 142
Joined: Fri Aug 02, 2013 12:39 pm

Example PTZ control script with start/stop type events

Post by TheKorn »

So I'm getting reasonable at hacking zm ptz control scripts to do what I want so far. But I'm working on a new type of camera (HooToo HT-IP006N) that doesn't send singular button events but rather start/stop events and don't have anything to model it off of.

What I mean is, let's say I hit the Pan Up button. The web interface then executes

Code: Select all

http://(blahblah)/decoder_control.cgi?command=0
and the camera pans up and continues going up until I release the button. At that point the web interface executes

Code: Select all

http://(blahblah)/decoder_control.cgi?command=1
at which point the camera stops panning up. Each direction has its own unique start/stop combo, along with zoom in and zoom out having their own unique start/stop combos.

Anyone have an example script they know of that works in a similar way that I can hack up and re-purpose? I suppose I could send a start immediately followed by a stop, but am wondering out loud if there's a better way or (even better!) if someone has already invented this wheel.

Thanks in advance!
TheKorn
Posts: 142
Joined: Fri Aug 02, 2013 12:39 pm

Re: Example PTZ control script with start/stop type events

Post by TheKorn »

Anybody?
jHeron
Posts: 73
Joined: Sun Jun 16, 2013 5:06 pm

Re: Example PTZ control script with start/stop type events

Post by jHeron »

I started looking into the same thing for my easyN cam but have not had time lately to follow up with it...
Have a look at the FI8608W_Y2k.pm script that's included with the 1.27RPM, I believe thats what your looking for. He uses an autoStop function that operates on a timer, the timer gets set based on how far up on the UI arrow you click.
At least thats how I remember it but its been a couple weeks :)
Let us know how you make out!
Cheers,
Jon
TheKorn
Posts: 142
Joined: Fri Aug 02, 2013 12:39 pm

Re: Example PTZ control script with start/stop type events

Post by TheKorn »

Ahhh, thanks for the point, I'll check it out!
Locked