Trying to get control working on no-name camera

Post here to ask any questions about hardware suitability, configuration in ZoneMinder, or experiences. If you just want to know if something works with ZoneMinder or not, please check the Hardware Compatibility sections in the forum, and the Wiki first. Also search this topic as well.
Post Reply
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Trying to get control working on no-name camera

Post by Jethro_uk »

Purchased a no-name wireless IP camera via Amazon. Connecting to it directly, it works 100%, via IE with an ActiveX. It reports the following, and appears to be a "netwave"

Code: Select all

 Device Firmware Version   0.41.2.47 
 Device Embeded Web UI Version   0.2.10.12 

Trying to access it via .cgi files is OK. videostream.cgi&user=user&pwd=pwd&resolution=32 works perfectly in ZM

Trying to access any other .cgi, as listed in the ipcamcgisdk21.pdf will only work from IE. However, they all seem to work.

I got them to work in Chrome, when I spoof the user-agent to be IE8. So I know the camera is quite happy to listen to commands.

Having read the documentation, I finally decided to try and create a control module, based on the http://www.zoneminder.com/wiki/index.php/Foscam_Clones guide.

I created the .pm file, and followed the guide to setting up via ZM. All well so far. I decided to call the camera "IPCam" and made sure case is consistent throughout. I also know to "killall -9 zmcontrol.pl"

However, when I try to control the camera, I get this, in the logfile:

Code: Select all

Sep 18 16:16:53 LucidFileserver zmcontrol[32092]: INF [Starting control server 1/IPCam]
Sep 18 16:16:53 lll zmcontrol[32093]: INF [Control server 1/IPCam starting at 12/09/18 16:16:53]
Sep 18 16:17:03 lll zmcontrol[32092]: FAT [Can't connect: Connection refused]
Firing up Wireshark doesn't seem to show anything obvious between Server and camera - just a load of ACKs.

I have put user=xxx&pwd=xxx in the "Control Device" field on the Control tab.

So, 2 questions, although hopefully an answer to the first will negate the need for the second !

1) Can anyone suggest what the problem is, and a fix

OR

2) What more can I do to provide diagnostic information. I tried editing zmcontrol.pl to up the DEBUG level, but it didn't return any more than I have posted.

Apart from that, ZM is great - very smart.
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Re: Trying to get control working on no-name camera

Post by Jethro_uk »

Brief update.

I can control the camera from Chrome, if I sign in using the "manual settings" and choose either "server push" OR "server refresh" option.

Now to dig out Fiddler and see what's going on.
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Re: Trying to get control working on no-name camera

Post by Jethro_uk »

Another update ... it seems the IE8 user-agent is a red herring. For some reason I can get it to work from Chrome now, without fiddling with the user-agent ....
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Re: Trying to get control working on no-name camera

Post by Jethro_uk »

OK, final update.

I *think* the problem is simply that ZM isn't connecting to the camera to control it.

I get the same errors, irrespective of WHAT I put in "device address". Which seems to imply that either that field isn't being updated properly (although it seems to save OK). Or that there's something I need to do to force a change in parameters.

Anyone ?
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Re: Trying to get control working on no-name camera

Post by Jethro_uk »

UPDATE:

I turned debug up to 9, and looked in the logs. I was intrigued to discover the following line:

Code: Select all

09/18/12 19:02:23.118936 zmfix[22900].ERR-zmfix.cpp/40 [Can't stat 192.168.10.200: No such file or directory]
now 192.168.10.200 is the "control address" I set in the "Control" tab. And sure enough, when I changed it to "fubar" I got this error:

Code: Select all

09/18/12 19:08:03.313136 zmfix[22900].ERR-zmfix.cpp/40 [Can't stat fubar: No such file or directory]
So, before I go any further, can anyone suggest why zmfix.cpp is trying to open "control address" as a file ?
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Re: Trying to get control working on no-name camera

Post by Jethro_uk »

OK:

have looked into zmfix.cpp, and it's trying to do this:

Code: Select all

select distinct Device from Monitors where not isnull(Device) and Type = 'Local'
and then fixDevice() the results.

Clearly *something* is borked, as the record in the database has "http" for 'Device' and "Remote" for 'Type'.

Anyone ?
Jethro_uk
Posts: 14
Joined: Tue Sep 18, 2012 3:19 pm

Re: Trying to get control working on no-name camera

Post by Jethro_uk »

OMK, fixed the zmfix.cpp error.

Am now back to getting "file or directory" not found from zmcontrol.pl

Anyone ?
Post Reply