Amcrest PTZ functionality

If you've made a patch to quick fix a bug or to add a new feature not yet in the main tree then post it here so others can try it out.
alabamatoy
Posts: 170
Joined: Sun Jun 05, 2016 2:53 pm

Re: Amcrest PTZ functionality

Post by alabamatoy » Fri Feb 23, 2018 1:32 pm

All of this discussion of the type of authentication is interesting, but I am inclined to think its a Zoneminder version or operating system issue, not an issue with the Amcrest cameras themselves....despite the evidence to the contrary. Why would all this work so nicely on mine and fail on others? I have a brand new Amcrest POE PTZ camera that I added to my setup just a few weeks ago, and it works fine with my original script.

I dont object to someone finding flaws in my ugly, probably-poorly designed script. But I am fearful that people are chasing the wrong root cause of the problem because it works fine on my setup, and has been for months. Is there a flaw in this thinking?

simonlok
Posts: 3
Joined: Fri Feb 23, 2018 1:05 pm

Re: Amcrest PTZ functionality

Post by simonlok » Fri Feb 23, 2018 8:25 pm

Which model of camera and which firmware version are you running?

This is what I have:

Software Version2.520.AC00.18.R, Build Date: 2017-06-29
WEB Version3.2.1.453504
ONVIF Version2.42 (V2.2.2.428697)

On the version of software stated above the CGI PTZ API reports 401 Unauthorized to all HTTP Basic authentication requests.

Based on my reading of the Amcrest support forum they removed support for HTTP Basic and require HTTP Digest authentication in their recent firmware.

alabamatoy
Posts: 170
Joined: Sun Jun 05, 2016 2:53 pm

Re: Amcrest PTZ functionality

Post by alabamatoy » Fri Feb 23, 2018 9:18 pm

Isnt this controlled by CURL? Is not CURL what the script is using to commo with the camera?

I cannot tell you the details of the camera unless there is some way to get that remotely - I am about 120 miles from my cameras!

alabamatoy
Posts: 170
Joined: Sun Jun 05, 2016 2:53 pm

Re: Amcrest PTZ functionality

Post by alabamatoy » Wed Mar 28, 2018 5:26 pm

Cross-posting, another user seems to have figured out a fix: viewtopic.php?f=36&t=27093#p105188

alabamatoy
Posts: 170
Joined: Sun Jun 05, 2016 2:53 pm

Re: Amcrest PTZ functionality

Post by alabamatoy » Sat Nov 30, 2019 2:53 pm

iconnor wrote:
Tue Jan 10, 2017 2:14 pm
Hey alabamatoy, can I assist you in getting this into ZoneMinder?

Do you have plans to do so, or can I just grab the script and make a PR in your name?
This code apparently never made it into the repo. My new 1.32.3 install has no amcrest control scripts. Oh well, I know yall got a lot going on.

bhearsum
Posts: 3
Joined: Thu Jan 02, 2020 6:43 pm

Re: Amcrest PTZ functionality

Post by bhearsum » Thu Jan 02, 2020 6:52 pm

Cross posting from viewtopic.php?f=36&t=27093&p=112998#p112998:

Thanks to everyone who's been working on this so far. I've been able to get this working with 1.32.3 + the latest firmware on my IP2M-841. However, it appears that Zoneminder 1.32.3's frontend is not sending the right query parameters when making PTZ requests. For example, it posts to /zm/index.php with paramaters such as:
view=request
request=control
id=6
control=Up
yge=32
Which results in errors like "Invalid control parameter: Up" and "Can't access Up member of object of class ZoneMinder::Control::Amcrest_HTTP".

Changing those requests to send "moveUp" (which matches the method name in Amcrest_HTTP.pm) fixes the problem.

I also tried adjusting the perl module to use "Up", but that failed because the PHP backend doesn't like "Up" as a control parameter (see https://github.com/ZoneMinder/zoneminde ... ns.php#L11)

User avatar
iconnor
Posts: 924
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: Amcrest PTZ functionality

Post by iconnor » Thu Jan 02, 2020 9:34 pm

You need to check Can Move Continuous.

NoNaym
Posts: 1
Joined: Sun Jan 26, 2020 5:37 am

Re: Amcrest PTZ functionality

Post by NoNaym » Sun Jan 26, 2020 5:52 am

Just picked up an Amcrest IP3M-941 and am seeing the same "Invalid control parameter: Up" and "Can't access Up member of object of class ZoneMinder::Control::Amcrest_HTTP" errors. Punching the URLs from the amcrest781.pm/Amcrest_HTTP.pm files with my camera's IP makes the camera move correctly, so it definitely seems like it should work. I have tried checking "Can Move Continuous," but I get a "No printMsg method defined for protocol ZoneMinder::Control" error instead. Not sure if anybody is using this specific Amcrest camera with ZM PTZ control yet, but would definitely appreciate any thoughts. Seemed like the right place to post this, but definitely let me know if I'm wrong there.

I have made sure that my serial number is in the Device Control section and all credentials and ip addresses are correct.

Camera firmware version is latest: V2.620.00AC00.3.R

Thanks in advance!!

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests