LinuxMCE Forums

General => Installation issues => Topic started by: brononius on July 25, 2012, 09:34:30 am

Title: [SOLVED] IP Camera in 1004
Post by: brononius on July 25, 2012, 09:34:30 am
Hey,

I've got some IPCAM02 running, and i want them to add in LinuxMCE.
But don't succeed to it. :$

I've tried adding them 'surveillance camera' as a 'generic motion ip camera - 1916' and as an 'advanced IP camera'. But couldn't get a image running.
Does anybody has an example what i need to add?
Fe i'm adding the IP, the MAC, the username (admin) and password.

Next to it, i found in http://wiki.linuxmce.org/index.php/Monitor_surveillance_cameras that you also could motion wrapper.
But couldn't find this in 1004.
Is it still in there, another location...?


ps a manual for the IPCAM is located here: http://download.chinavasion.com/download/CVLM-I122.pdf

Thanks!!!
Title: Re: IP Camera in 1004
Post by: mardibloke on July 25, 2012, 12:12:01 pm
Add as Motion Wrapper,  the wiki covers it very well:

http://wiki.linuxmce.org/index.php/Monitor_surveillance_cameras#Adding_IP_Cameras_under_Motion_Wrapper

What I do not see in the manual for you IPCAM, is a link for a static image from your camera.

For example, my Axis cameras the link is : /axis-cgi/jpg/image.cgi   or my other cameras : /mjpg/video.mjpg

You need to figure that out for your camera.

Title: Re: IP Camera in 1004
Post by: Armor Gnome on July 25, 2012, 12:47:39 pm
For finding an IP camera's image location I used firefox, much in the way you can use it to DL images from sites that go out of their way to block the "right-click and save" methods.

Example from external network would be: 192.168.1.7/image.jpg

From your browser on the camera's browser page, right click on the static image picture.  For D-Link interfaces this is the image itself when using images as the live view method.  Select view image source or view source.  This gives you a url for each of the elements that it is displaying graffically including the logos, etc.  You will find a string normally that looks like <IP address>/images.jpg/image.cgi=436478326234.  Open another tab in your browser and retype the address of your camera's browser plus the first part of the red text above.  The image in the new browser tab will be a frameless image of your camera's feed if you got it correct.

The additional (/instruction) is what the device data is looking for since you allready provided the first part of the full url when you gave it the IP address.

Things to avoid that would "not" be still images would be /image.cgi (this is useful as it constantly refreshes however)  /anything.mpg, /anything.mpeg etc.
Title: Re: IP Camera in 1004
Post by: brononius on July 25, 2012, 01:01:23 pm
OK, i've got the motion wrapper in it (thought it was by default there)...

Following link gives me directly the video output.
   192.168.0.100/videostream.cgi
   192.168.0.100/video.cgi

And this link a image
   192.168.0.100/snapshot.cgi

What i've done:


ps maybe one strange thing? When i click in the orbiter on the cameraname, he opens a new window. And i see here (where the videostream should be) very flue the name of a room on top of it. This in white font...
Title: Re: IP Camera in 1004
Post by: brononius on July 25, 2012, 01:04:50 pm
I've also tried with: /videostream.cgi?user=admin&pwd=admin in the panasonic template. But no luck...  :-[
Title: Re: IP Camera in 1004
Post by: brononius on July 25, 2012, 01:25:07 pm
OK, i've got the motion wrapper in it (thought it was by default there)...

ps maybe one strange thing? When i click in the orbiter on the cameraname, he opens a new window. And i see here (where the videostream should be) very flue the name of a room on top of it. This in white font...

I think i found something...
I've tried to restart the service motion, and received a message that the daemon was disabled.
After setting the no in /etc/default/motion to yes, it started.
And now i've got a more nicer grey picture with the message that it couldn't connect... Also time, name...

so sudo /etc/init.d/motion start is a first step in the right direction?
Title: Re: IP Camera in 1004
Post by: DragonK on July 25, 2012, 01:33:39 pm
OK, i've got the motion wrapper in it (thought it was by default there)...

Following link gives me directly the video output.
   192.168.0.100/videostream.cgi
   192.168.0.100/video.cgi

And this link a image
   192.168.0.100/snapshot.cgi

What i've done:
  • Template 1916 (controlled by 'motion wrapper'
  • Data:   /videostream.cgi
  • user:   admin
  • password:   admin
  • TCP port:   80
  • protocol: http
  • IP:      192.168.0.100
  • MAC:  00:0d:c5:d0:47:e1


ps maybe one strange thing? When i click in the orbiter on the cameraname, he opens a new window. And i see here (where the videostream should be) very flue the name of a room on top of it. This in white font...

You have 2nics in your server? 192.168.0.# is your external network?
That might be your problem......
Title: Re: IP Camera in 1004
Post by: brononius on July 25, 2012, 01:58:41 pm
192.168.0.x is my internal side...

In the meantime, i managed to have a view! Yiepie.
I can't move the (motion)camera with an orbiter. But babysteps...

After starting the 'motion' service, it starts to give me output. And in the folder /home/cameras/, it's creating images...

I've noticed also that i need to restart motion each time i reload the server.

I'm guessing 'motion' is a kind of service that pulls down images from the camera's? And this is generating the images under security?
When i don't use motion, is there another process that must be running?

Title: Re: IP Camera in 1004
Post by: brononius on July 27, 2012, 12:47:30 pm
3 days later, a lot of stress, a lot of recreating/regen/reloading the devcies, one camera already died because a bad firmware upgrade...

But i think that if i could manage to insert a Foscam camera, it should work.
I found the wiki on http://wiki.linuxmce.org/index.php/Foscam_FI8908W
And i believe that the IPCAM works 99% the same as this Foscam model.
But i can't figure out how i can create/duplicate and change the commands for a template.

Is there somewhere an easy way to just download the template for the camera?  :(
wget the file, move it to the proper place and done? ;)
Title: Re: IP Camera in 1004
Post by: brononius on August 02, 2012, 02:31:34 pm
I figured out that following options allowed me to control/view the camera. This all works when i'm using a normal webbrowser.

View video:

View image:

Control the camera:



I've now tried to put this in the template (motion camera template 1916). But i could only get the view to work.
I can't seem to be able to control the camera by an orbiter. What i've added in the template:

When i enter path, will he not put this in front of my movement comment? Or is path only for getting the image?

I'm not sure what the difference is between a 'normal IP camera (core)' and a 'motion ip camera (motion)'.
Can this be the problem for the movemen?
I've try to get a core ip camera to work, but here i'm even not getting the image.




ps i'm trying to contact the person who works on the template of 'Advanced IP Camera' on the wiki page. But can't figure out how i can reach him. Any idea?
Title: Re: IP Camera in 1004
Post by: bri_jac on August 02, 2012, 02:55:51 pm
To my understanding the difference between 'normal IP camera (core)' and a 'motion ip camera (motion)' is that:

Normal ip camera: You can control the movements of the IP cam via your orbiter, but the images are not being actively monitored, unless this is done by your ip cam.

Motion: Motion is monitoring your images from your ip cam and LinuxMCE can then catch an action/event and do something about it. BUT it's NOT possible via Motion to get acces to adjust position/rotate the camera viewing angle. Then instead you must login to the IP cam's own webserver and via this interface adjust the movement.


Motion wrapper:
http://wiki.linuxmce.org/index.php/Motion (http://wiki.linuxmce.org/index.php/Motion)
Title: Re: IP Camera in 1004
Post by: brononius on August 02, 2012, 02:59:55 pm
Thanks,

Then i'll need to leave the motion path, and trying to get the Advanced_IP_Camera to work?
If i could only figure out how to start the capturing of the images...

The folder lmce-admin/security_images isn't filled by images... :$
Title: Re: IP Camera in 1004
Post by: mardibloke on August 02, 2012, 06:18:31 pm
I figured out that following options allowed me to control/view the camera. This all works when i'm using a normal webbrowser.

Try :

http://10.10.10.10/kmotion

I add my cameras in there and use it as the interface for monitoring, and setting it to record when there is motion. Then reviewing archive footage.  It supports my Axis PTZ cameras and moving.
Title: Re: IP Camera in 1004
Post by: brononius on August 02, 2012, 06:28:25 pm
http://10.10.10.10/kmotion

I suppose this is something 'camera/brand' based?
I don't have this on 'linuxmce', nor on the camera itself...
Title: Re: IP Camera in 1004
Post by: sambuca on August 02, 2012, 08:15:28 pm
I am the developer of the Advanced IP Camera.

From the URLs you posted you should be able to create a template using the Advanced IP Camera in 5-10 minutes. The wiki article describes this process (well, I hope). The Pan and Zoom function was created just a few days ago, so I'm not sure if the update has been built yet.

The Motion Camera template #1916 does not use the same parameters as the Advanced IP Camera, so that is why you cannot control the camera from any orbiter.

Just ask if you have any questions.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 02, 2012, 09:08:04 pm
I am the developer of the Advanced IP Camera.

From the URLs you posted you should be able to create a template using the Advanced IP Camera in 5-10 minutes. The wiki article describes this process (well, I hope).

It still doesn't work, but i'm already relieved that you came in the picture. ;)


I've tried your wiki several times now. But i can't seem to figure out how i can make (a copy of) the template.
So i'm using the original 'Advanced IP Camera (#2208)'.

At first sight (for me at least), everything is filled in like it should be.
But i've got the impression that it simply isn't 'touched'. Like i need to restart/start a service or so?
In your manual, you write that the new template is started with the core. Can this be the issue?  ???

You can see in my attachment below that i can't get a picture (view) from it.
So for the moment no need to control something... ;)
Title: Re: IP Camera in 1004
Post by: sambuca on August 02, 2012, 09:28:29 pm
There is no way to copy a template at the moment.. so you have to create a new one from scratch.

It is possible to use the Advanced IP Camera template for testing, and later create a template using that data.

If the device is started properly, you should see a log file with the device id in /var/pluto/log on the core. This could also give more information about what is wrong..

Another strange thing is the use of user and password in the URL itself. Is this all that is required to authenticate with the camera? If so, you can probably clear the AuthPass and AuthUser fields. If those fields are filled in, it will try to use basic http authentication for all requests. Maybe that messes up the communication with the camera?

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 02, 2012, 09:51:43 pm
I have tried to remove the user/password. In both the fields and links. No luck...

When i check the log folder, nothing is being created with the camera id. So somewhere there is a `start` issue for that device?
Title: Re: IP Camera in 1004
Post by: sambuca on August 02, 2012, 10:02:18 pm
Do you have the /usr/pluto/bin/Advanced_IP_Camera binary on the core?

Once the device is created with the template, and the router has been reloaded, it should start. The correct package should be installed automatically. If the binary is not present, there must be something wrong with the install or that the system hasn't triggered the install yet. A reboot should always trigger a install of missing packages.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 02, 2012, 10:17:15 pm
Yes, binary is present.
When i run it, i`m getting follow output:

Code: [Select]
brononius@dcerouter:/usr/pluto/bin$ ./Advanced_IP_Camera
Advanced_IP_Camera, v.2.0.0.45.12022425524
Visit www.plutohome.com for source code and license information
 
01      08/02/12 22:06:19.850           Connection for client socket reported BAD DEVICE IP=::ffff:192.168.111.1, device 0 last error
 3 <0xb77276f0>
05      08/02/12 22:06:20.350           void ClientSocket::Disconnect() on this socket: 0x923a450 (m_Socket: 3) <0xb77276f0>
Device ID is invalid.  Exiting...

A reboot didn`t changed anything...
Title: Re: IP Camera in 1004
Post by: sambuca on August 02, 2012, 10:28:48 pm
You need to specify the device ID on the command line to start it like that, use -d <dev.id>

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 03, 2012, 07:25:04 am
I think i've looked from the wrong ID.  Probably because it was pass my bedtime... :-[

When i run the command now:

Code: [Select]
sudo /usr/pluto/bin/Advanced_IP_Camera -d 191
Advanced_IP_Camera, v.2.0.0.45.12022425524
Visit www.plutohome.com for source code and license information

05 08/03/12 7:16:14.640 m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77d06f0>
05 08/03/12 7:16:14.640 m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77d06f0>
Segmentation fault
I'm guessing that 'segmentation fault' isn't good?

And the log:
Code: [Select]
Return code: 139
3       08/03/12 07:16:14       191 (spawning-device)   ^[[1;31mDevice died... count=2/50 dev=191^[[1;00m
Fri Aug  3 07:16:14 CEST 2012 died
========== NEW LOG SECTION ==========
1       08/03/12 07:16:24       191 (spawning-device)   ^[[1;00mStarting... 3^[[1;00m
1       08/03/12 07:16:24       191 (spawning-device)   ^[[1;00mFound /usr/pluto/bin/Advanced_IP_Camera^[[1;00m
05      08/03/12 7:16:24.728            ^[[33;1mm_vectEventMethod.size() = 5. Configured EventMethods:^[[0m <0xb77dd6f0>
05      08/03/12 7:16:24.728            ^[[33;1mm_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices:^[[0m <0xb77dd6f0>

Title: Re: IP Camera in 1004
Post by: sambuca on August 03, 2012, 08:29:43 am
No, the segmentation fault does not look good..

First, please make sure you have the newest version of the lmce-advanced-ip-camera package. If there is a newer one, install that and do a quick reload and try starting the Advanced IP Camera again.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 03, 2012, 09:45:44 am
Any tip how i should update/check the package?  :-[
Title: Re: IP Camera in 1004
Post by: sambuca on August 03, 2012, 10:01:05 am
Do this:
Code: [Select]
apt-get install lmce-advanced-ip-camerawill install any newer version if available.

br,sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 03, 2012, 10:11:03 am
Was already on the latest version:
Code: [Select]
lmce-advanced-ip-camera is already the newest version.
And to be sure, i've removed it, and reinstalled it.
But the result stays the same: 'segmentation fault'
Title: Re: IP Camera in 1004
Post by: sambuca on August 03, 2012, 10:40:12 am
Ok, then you need to help me debug it. Look in /home/coredump/1 for the last file with Advanced_IP_Camera in its name, this is the dump file.

Code: [Select]
cd /usr/pluto/bin
sudo gdb Advanced_IP_Camera <path and filename to dump file>

Once gdb has started, type bt and press enter
This will give you the stack trace and will help pinpoint the error. Please copy this and post it here.

Type quit to exit gdb.

br,
sambuca

Title: Re: IP Camera in 1004
Post by: brononius on August 03, 2012, 12:56:50 pm
Hey,

Rather short response? Maybe i'm doing something wrong?

sudo gdb /usr/pluto/bin/Advanced_IP_Camera
Code: [Select]
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying" and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>...

Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...(no debugging symbols found)...done.
(gdb)
(gdb)
(gdb) bt
No stack.
(gdb) quit
Title: Re: IP Camera in 1004
Post by: sambuca on August 03, 2012, 03:49:29 pm
Yes, you forgot to add the dump file parameter to the command line. It should be something like this
sudo gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Camera_123412341234

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 03, 2012, 05:17:51 pm
I'm getting another error...  ???

sudo gdb /usr/pluto/bin/Advanced_IP_Camera /tmp/core_Advanced_IP_Camera_123412341234
Code: [Select]
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying" and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...(no debugging symbols found)...done.
"/tmp/core_Advanced_IP_Camera_123412341234" is not a core dump: File format not recognized
(gdb) bt
No stack.
(gdb)
Title: Re: IP Camera in 1004
Post by: Marie.O on August 03, 2012, 06:43:37 pm
replace the core_Advanced_IP_Camera_123412341234 with the name and location of your coredump in /home/...
Title: Re: IP Camera in 1004
Post by: brononius on August 03, 2012, 07:32:11 pm
Ahhh, i thought it simply put the output in a file.  :-\
Why do we think we always know it better? ;)

It went better with follow command (thanks!):

sudo gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1344009871_11
Code: [Select]
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...(no debugging symbols found)...done.

warning: core file may not match specified executable file.
[New Thread 18662]

warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/lib/libcurl.so.4...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libcurl.so.4
Reading symbols from /usr/lib/libmysqlclient_r.so.16...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libmysqlclient_r.so.16
Reading symbols from /usr/pluto/lib/libSerializeClass.so...(no debugging symbols found)...done.
Loaded symbols for /usr/pluto/lib/libSerializeClass.so
Reading symbols from /usr/pluto/lib/libDCECommon.so...(no debugging symbols found)...done.
Loaded symbols for /usr/pluto/lib/libDCECommon.so
Reading symbols from /usr/pluto/lib/libPlutoUtils.so...(no debugging symbols found)...done.
Loaded symbols for /usr/pluto/lib/libPlutoUtils.so
Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0
Reading symbols from /usr/lib/libstdc++.so.6...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/tls/i686/cmov/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libm.so.6
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/i686/cmov/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libc.so.6
Reading symbols from /usr/lib/libidn.so.11...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libidn.so.11
Reading symbols from /usr/lib/liblber-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/liblber-2.4.so.2
Reading symbols from /usr/lib/libldap_r-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libldap_r-2.4.so.2
Reading symbols from /lib/tls/i686/cmov/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/librt.so.1
Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /lib/i686/cmov/libssl.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libssl.so.0.9.8
Reading symbols from /lib/i686/cmov/libcrypto.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libcrypto.so.0.9.8
Reading symbols from /lib/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1
Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2
Reading symbols from /usr/lib/libsasl2.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libsasl2.so.2
Reading symbols from /usr/lib/libgnutls.so.26...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgnutls.so.26
Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /lib/tls/i686/cmov/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libdl.so.2
Reading symbols from /lib/libkeyutils.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libkeyutils.so.1
Reading symbols from /usr/lib/libtasn1.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libtasn1.so.3
Reading symbols from /lib/libgcrypt.so.11...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcrypt.so.11
Reading symbols from /lib/libgpg-error.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/libgpg-error.so.0
Reading symbols from /lib/tls/i686/cmov/libnss_files.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnss_files.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 191 -r localhost -l /var/log/pluto/191_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  0x0806db4c in ?? ()
(gdb) bt
#0  0x0806db4c in ?? ()
#1  0x0805a984 in ?? ()
#2  0x08059320 in ?? ()
#3  0x0078bbd6 in __libc_start_main () from /lib/tls/i686/cmov/libc.so.6
#4  0x08058501 in ?? ()
(gdb)

Does this say anything?
Title: Re: IP Camera in 1004
Post by: hari on August 03, 2012, 10:24:27 pm
no beacuse it is stripped:

Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...(no debugging symbols found)...done.

It needs to be compiled with "-g".
Title: Re: IP Camera in 1004
Post by: brononius on August 04, 2012, 06:53:52 am
It needs to be compiled with "-g".

You lost me there...  :-[
Title: Re: IP Camera in 1004
Post by: hari on August 05, 2012, 12:36:07 am
gdb needs "debug symbols" to print out useful backtraces. Either these are stripped off in your case or the binary was not compiled with the proper compiler switch at all. Somebody needs to compile the camera device with the "-g" switch and pass you that binary or provide the debug symbols as a separate file.
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 05:57:04 am
Oh, ok. Will somebody be so kind to... ;)

ps, must i mention this to somebody somewhere?
Since it's a default DVD/image installation, i can image that others will have the same issue...
Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 08:29:00 am
I will provide a binary with symbols later today (if no one else beats me to it...)

I don't know what the consensus about debug symbols in the default packages is? I know I haven't changed the build of the Advanced IP Camera in any way related to that.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 10:24:58 am
Download this binary http://hob.dyndns.org/lmce/Advanced_IP_Camera (http://hob.dyndns.org/lmce/Advanced_IP_Camera) and run it on the command line (no need to replace the one in /usr/pluto/bin), and try again.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 10:52:07 am
hmmm, seems to give me the same result/error...


sudo ./Advanced_IP_Camera -d 191
Code: [Select]
Advanced_IP_Camera, v.<=version=>
Visit www.plutohome.com for source code and license information

05 08/06/12 10:50:51.731 m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77676f0>
05 08/06/12 10:50:51.731 m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77676f0>
Segmentation fault
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 10:54:22 am
And the gdb:


sudo gdb /tmp/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1344243051_11
Code: [Select]
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /tmp/Advanced_IP_Camera...done.

warning: core file may not match specified executable file.
[New Thread 15911]
[New Thread 15914]
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 191 -r localhost -l /var/log/pluto/191_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  0x0806db4c in __gnu_cxx::new_allocator<std::_Rb_tree_node<std::pair<int const, std::string> > >::allocate (this=0x0, __n=3218971160)
    at /usr/include/c++/4.4/ext/new_allocator.h:86
86 if (__builtin_expect(__n > this->max_size(), false))
(gdb) bt
#0  0x0806db4c in __gnu_cxx::new_allocator<std::_Rb_tree_node<std::pair<int const, std::string> > >::allocate (this=0x0, __n=3218971160)
    at /usr/include/c++/4.4/ext/new_allocator.h:86
#1  0x0805a984 in ~Advanced_IP_Camera (this=0x891e478, __in_chrg=<value optimized out>) at Advanced_IP_Camera.cpp:60
#2  0x08059320 in main (argc=7, argv=0xbfdd9ba4) at Main.cpp:203
(gdb)
Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 02:04:16 pm
Not sure if I have fixed it, but can you download the binary again - I've created a new version, and try again. See if it still segfaults.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 02:19:58 pm
Seems to be a lot better. Thanks !!!
At least i don't have the 'segfault' anymore...
Now back to the camera setup. Or must there be done something else before?


sudo ./Advanced_IP_Camera -d 191
Code: [Select]
Advanced_IP_Camera, v.<=version=>
Visit www.plutohome.com for source code and license information

05 08/06/12 14:18:01.422 m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77da6f0>
05 08/06/12 14:18:01.422 m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77da6f0>



sudo gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1344243051_11
Code: [Select]
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...done.

warning: core file may not match specified executable file.
[New Thread 15911]
[New Thread 15914]
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 191 -r localhost -l /var/log/pluto/191_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  0x0806db4c in std::copy<ItemToSerialize**, ItemToSerialize**> (__first=0x0, __last=0xbfdd9a18, __result=0x0)
    at /usr/include/c++/4.4/bits/stl_algobase.h:458
458    copy(_II __first, _II __last, _OI __result)
(gdb) bt
#0  0x0806db4c in std::copy<ItemToSerialize**, ItemToSerialize**> (__first=0x0, __last=0xbfdd9a18, __result=0x0)
    at /usr/include/c++/4.4/bits/stl_algobase.h:458
#1  0xbfdd9a38 in ?? ()
#2  0x0805a984 in ~Advanced_IP_Camera (this=0x891e478, __in_chrg=<value optimized out>) at Advanced_IP_Camera.cpp:66
#3  0x08059320 in main (argc=7, argv=0xbfdd9ba4) at Main.cpp:203

Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 02:32:11 pm
You should be able to set up the camera now.

What you can do is to edit the /etc/pluto.conf file and find the LogLevels line. Add ,10 to the end of it to get more logging:
Code: [Select]
LogLevels = 1,5,7,8,10And do a quick reload - or if you like, for testing purposes, you can start the device on the command line (no reload required).

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 03:32:59 pm
I've recreated the camera (id 192) and rebooted the server completly.
Afterwards, no luck with the camera.  :-[


tail -f /var/log/pluto/192_Advanced_IP_Camera.log
Code: [Select]
== ATTEMPT FRESH START ==
1 08/06/12 15:15:03 /usr/pluto/bin/Spawn_Device.sh 192 (spawning-device) 15920 Dev: 192; Already Running list: 15,16,18,19,29,30,123,180,
== FRESH START ==
1 08/06/12 15:15:03 /usr/pluto/bin/Spawn_Device.sh 192 (spawning-device) device: 192 ip: localhost cmd_line: Advanced_IP_Camera
0 08/06/12 15:15:03 192 (spawning-device) Entering 192
========== NEW LOG SECTION ==========
1 08/06/12 15:15:03 192 (spawning-device) Starting... 1
1 08/06/12 15:15:03 192 (spawning-device) Found /usr/pluto/bin/Advanced_IP_Camera
05 08/06/12 15:15:03.792 m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77796f0>
05 08/06/12 15:15:03.792 m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77796f0>




A manual start, sudo /usr/pluto/bin/Advanced_IP_Camera -d 192
Code: [Select]
Advanced_IP_Camera, v.<=version=>
Visit www.plutohome.com for source code and license information

05 08/06/12 15:26:40.225 m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77c46f0>
05 08/06/12 15:26:40.225 m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77c46f0>
No error afterwards, just keeps running?





And a debug, sudo gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1344257657_11
Code: [Select]
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...done.

warning: core file may not match specified executable file.
[New Thread 3512]
[New Thread 3515]

warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/lib/libcurl.so.4...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libcurl.so.4
Reading symbols from /usr/lib/libmysqlclient_r.so.16...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libmysqlclient_r.so.16
Reading symbols from /usr/pluto/lib/libSerializeClass.so...(no debugging symbols found)...done.
Loaded symbols for /usr/pluto/lib/libSerializeClass.so
Reading symbols from /usr/pluto/lib/libDCECommon.so...(no debugging symbols found)...done.
Loaded symbols for /usr/pluto/lib/libDCECommon.so
Reading symbols from /usr/pluto/lib/libPlutoUtils.so...(no debugging symbols found)...done.
Loaded symbols for /usr/pluto/lib/libPlutoUtils.so
Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0
Reading symbols from /usr/lib/libstdc++.so.6...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/tls/i686/cmov/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libm.so.6
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/i686/cmov/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libc.so.6
Reading symbols from /usr/lib/libidn.so.11...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libidn.so.11
Reading symbols from /usr/lib/liblber-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/liblber-2.4.so.2
Reading symbols from /usr/lib/libldap_r-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libldap_r-2.4.so.2
Reading symbols from /lib/tls/i686/cmov/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/librt.so.1
Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /lib/i686/cmov/libssl.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libssl.so.0.9.8
Reading symbols from /lib/i686/cmov/libcrypto.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libcrypto.so.0.9.8
Reading symbols from /lib/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1
Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2
Reading symbols from /usr/lib/libsasl2.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libsasl2.so.2
Reading symbols from /usr/lib/libgnutls.so.26...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgnutls.so.26
Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /lib/tls/i686/cmov/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libdl.so.2
Reading symbols from /lib/libkeyutils.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libkeyutils.so.1
Reading symbols from /usr/lib/libtasn1.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libtasn1.so.3
Reading symbols from /lib/libgcrypt.so.11...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcrypt.so.11
Reading symbols from /lib/libgpg-error.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/libgpg-error.so.0
Reading symbols from /lib/tls/i686/cmov/libnss_files.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnss_files.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 192 -r localhost -l /var/log/pluto/192_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  DCE::EventMethod::Start (this=0x805b164) at EventMethod.cpp:51
51 EventMethod.cpp: No such file or directory.
in EventMethod.cpp
(gdb) bt
#0  DCE::EventMethod::Start (this=0x805b164) at EventMethod.cpp:51
#1  0xbf86c7a8 in ?? ()
#2  0x0805b164 in ~Advanced_IP_Camera (this=0x96d0478, __in_chrg=<value optimized out>) at Advanced_IP_Camera.cpp:54
#3  0x08059500 in main (argc=7, argv=0xbf86c914) at Main.cpp:236
(gdb) quit
Now a 'segmentation fault' more at the end? ps i don't now what i'm looking at  :-X


Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 03:56:58 pm
The log wont show much more than now before something starts happening..

But you should enable more logging like I described, it will help troubleshoot.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 06:03:13 pm
A bit more log, a bit more details... ;)

I see that in the link, he puts 3x ///
Normal behavior? Or something wrong?
In the GUI i've put /snapshot.cgi (with only 1 /). I've tried also with and without user/password directly in the link.


sudo tail -f /var/log/pluto/192_Advanced_IP_Camera.log
Code: [Select]
2       08/06/12 18:01:00       192 (spawning-device)   Device requests restart... count=1/50 dev=192
1       08/06/12 18:01:08       192 (spawning-device)   Starting... 1
1       08/06/12 18:01:08       192 (spawning-device)   Found /usr/pluto/bin/Advanced_IP_Camera
10      08/06/12 18:01:08.860           Device: 192 starting.  Connecting to: localhost <0xb77126f0>
10      08/06/12 18:01:08.865           Setting timeout for socket 4 to 20 <0xb77126f0>
10      08/06/12 18:01:08.866           DCE Router asked us to wait--it's busy at the moment <0xb77126f0>
10      08/06/12 18:01:09.871           getConfig() Configuration = panUpCmd=/decoder_control.cgi?command=0&onestep=1&user=USER&pwd=PASSWORD
panDownCmd=/decoder_control.cgi?command=2&onestep=1&user=USER&pwd=PASSWORD
panRightCmd=/decoder_control.cgi?command=4&onestep=1&user=USER&pwd=PASSWORD
panLeftCmd=/decoder_control.cgi?command=6&onestep=1&user=USER&pwd=PASSWORD <0xb77126f0>
10      08/06/12 18:01:09.871           getConfig() key = panUpCmd, value = /decoder_control.cgi?command=0&onestep=1&user=USER&pwd=PASSWORD <0xb77126f0>
10      08/06/12 18:01:09.871           getConfig() key = panDownCmd, value = /decoder_control.cgi?command=2&onestep=1&user=USER&pwd=PASSWORD <0xb77126f0>
10      08/06/12 18:01:09.871           getConfig() key = panRightCmd, value = /decoder_control.cgi?command=4&onestep=1&user=USER&pwd=PASSWORD <0xb77126f0>
10      08/06/12 18:01:09.871           getConfig() key = panLeftCmd, value = /decoder_control.cgi?command=6&onestep=1&user=USER&pwd=PASSWORD <0xb77126f0>
10      08/06/12 18:01:09.872           getConfig() Children: <0xb77126f0>
05      08/06/12 18:01:09.872           m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77126f0>
05      08/06/12 18:01:09.872           m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77126f0>
10      08/06/12 18:01:09.873           Connect OK <0xb77126f0>
10      08/06/12 18:01:09.873           Requesthandler 0xa0448d0 (device: 192) runThread now running <0xb6d10b70>
10      08/06/12 18:01:14.148           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:14.148           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:15.200           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:15.200           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:16.244           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:16.244           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:17.288           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:17.288           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:18.332           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:18.332           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:19.380           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:19.380           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:20.423           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:20.423           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:21.468           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:21.468           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:22.514           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:22.514           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:23.558           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:23.558           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:23.941           Receive string: MESSAGE 109            <0xb6d10b70>
10      08/06/12 18:01:23.941           Received MESSAGE 109            0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:23.942           Received Message type 1 ID 84 from 0 to 192 (device: 192) resp 1 <0xb6d10b70>
10      08/06/12 18:01:23.942           CMD_Get_Video_Frame: sUrl: http://192.168.111.93:80///snapshot.cgi?user=USER&pwd=PASSWORD&rate=1 <0xb6d10b70>
10      08/06/12 18:01:23.951           CMD_Get_Video_Frame: http code: 404, response: <0xb6d10b70>
10      08/06/12 18:01:23.951           Socket::SendMessage type 4 id 0 from 192 to 0 <0xb6d10b70>
10      08/06/12 18:01:24.602           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:24.602           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:25.647           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:25.647           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:26.692           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:26.692           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:27.738           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:27.738           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:28.782           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:28.782           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:29.199           Receive string: MESSAGE 109            <0xb6d10b70>
10      08/06/12 18:01:29.199           Received MESSAGE 109            0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:29.199           Received Message type 1 ID 84 from 0 to 192 (device: 192) resp 1 <0xb6d10b70>
10      08/06/12 18:01:29.199           CMD_Get_Video_Frame: sUrl: http://192.168.111.93:80///snapshot.cgi?user=USER&pwd=PASSWORD&rate=1 <0xb6d10b70>
10      08/06/12 18:01:29.207           CMD_Get_Video_Frame: http code: 404, response: <0xb6d10b70>
10      08/06/12 18:01:29.207           Socket::SendMessage type 4 id 0 from 192 to 0 <0xb6d10b70>
10      08/06/12 18:01:29.826           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:29.826           Received  0xa0448d0 device: 192 <0xb6d10b70>
10      08/06/12 18:01:30.870           Receive string:  <0xb6d10b70>
10      08/06/12 18:01:30.870           Received  0xa0448d0 device: 192 <0xb6d10b70>
Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 07:07:15 pm
I've seen the triple /// too, but it has not been a problem before.

I see that the URL request gets a 404 error, which means that the requested resource does not exist.  Are you sure that the url is correct?

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 06, 2012, 07:35:17 pm
When i enter follow link in my browser, it works: http://192.168.111.93/snapshot.cgi?user=USER&pwd=PASSWORD&rate=1
or simply http://192.168.111.93/snapshot.cgi followed by 'USER' & 'PASSWORD'.
The same for /videostream.cgi

But when i insert  http://192.168.111.93:80///videostream.cgi, i'm recieving almost the same error coming from the IP camera:

Code: [Select]
404 Not Found

File not found.

Seems he doens't like the triple slash...
Title: Re: IP Camera in 1004
Post by: sambuca on August 06, 2012, 08:18:54 pm
Ok, I've made a new version that does not add extra slashes. You can download it from the same URL.

br,
sambuca
Title: Re: IP Camera in 1004
Post by: brononius on August 07, 2012, 08:22:39 am
Ok, I've made a new version

In one word:   NICE

Works perfectly. Everything works:

My settings asis:

beside: for the controls, i had to switch UP and DOWN since my camera is upside down... ;)





Next is to change the orbiter layout (buttons assigment) a bit. I don't have zoom, and i would like to replace this with preselections views (fe 10ups, 15 rights) But i think this another topic/template/..., no?
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 07, 2012, 08:54:17 am
Glad you finally got it working  :)

It would be great if you create a new template for your camera so that it is plug and play.

Changing the Orbiter layout is definitely another topic yes..

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 07, 2012, 09:18:06 am

Glad to.
Is there somewhere a procedure how to create templates?


ps not sure why, but when i reboot the server, i've got the 'segmentation fault' again. Just a download of your file, chmod... solved it again?


Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 07, 2012, 09:36:03 am
There should be some procedures in the wiki. Basically it goes like this:
Go to Advanced -> Configuration -> Device Templates, click Add device template. You need to specify your cameras manufacturer and device category first (category should be "IP Cameras < Surveillance cameras < Peripherals"). If you don't know the manufacturer, there is also a "Generic" manufacturer.

From there, you can follow the instructions on http://wiki.linuxmce.org/index.php/Advanced_IP_Camera (http://wiki.linuxmce.org/index.php/Advanced_IP_Camera) to fill in the required information.

I will look at the segmentation fault, but I think it is happening when the program stops and shouldn't prevent the camera from working.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 07, 2012, 01:08:26 pm
I think I've figured it out.
I've created a new template (id 2211 - Generic - IPCAM02), and it works at my end.

Are their extra steps i must do? Fe upload it somewhere in order to make it public?
Or isn't that the idea?


Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 07, 2012, 02:06:55 pm
Yes, you need to upload it to sqlCVS. You can do this anonymously, and I will approve it after checking that it looks ok.

Everything you need related to sqlCVS is found in the web-admin, under Advanced -> sqlCVS.
First you should do a sqlCVS update, check all under DCE, and click next. This will pop up a new window (watch out for popup blockers...) and will take a while to complete.
When this completes, open your IPCAM02 template and make sure everything is ok (no device data is missing or added by mistake by the update). I don't think it should, but better safe than sorry. Also note that your template might have gotten a new template number, you need this later.

Next, do a sqlCVS diff. Check all under DCE and click next.
This is where it gets interesting...  ;) This will, after a short while, display all changes in your installation compared to the standard one.

You will probably have several changes that are unrelated to the device template, and selecting those will in the worst case break existing templates (like the changes you did to the original Advanced IP Camera template).
What you see is a list of items, with NEW/MOD/DEL in front of them. In your case you created a new template, so only NEW items should be selected, deselect all others.

Now, look more closely at the selected items... You should see a column with PK_ or FK_DeviceTemplate for each item. In this column there should be the same number as your device template. If you have any other numbers, it may be other device templates you created but did not upload. So deselect everything not containing the IPCAM02 device template ID.

Create a new ticket in trac, and use the ticket ID as a reference in the text input at the bottom of the web-admin screen, along with perhaps a short description. Click "Commit". This will also take a short while. When that is done, let me know and I will take it from there.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 07, 2012, 02:42:59 pm
I'm getting an error on the DIFF...

Code: [Select]
01 08/07/12 14:39:44.791 gethostbyname2 for 'schema.linuxmce.org', failed, Last Error Code 3, Device: 1 <0xb779b6d0>

I'm seeing another topic (http://forum.linuxmce.org/index.php?topic=12695.0) with this kind of error. Will first try that...  :-[
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 07, 2012, 05:44:50 pm
Hmmm, my first template, i'm a bit curious... ;)

Ticketnr 1534, device template is uploaded...



ps this template should work also for the FOSCAM IPCAM generation. In my eyes, this is almost 99,99% the same device. Except the name and maybe firmware...
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 07, 2012, 08:18:09 pm
Your template has been approved, thanks for your work.

Please update sqlCVS and check that the template still is OK. There was some inconsistency after approving it, but I took care of it. It was not anything you did wrong ;)

You could also add a DHCP range for the cameras to make them plug-and-play.

It seems the camera is also capable of motion detection, and I think it is possible to add that to the template if your interested in helping a bit.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 08, 2012, 07:37:33 am
You could also add a DHCP range for the cameras to make them plug-and-play.
I'm not sure where i can find the MAC-range for these devices. Since it are 'nameless brands'.
These are the 4 MAC's i'm having:

It seems the camera is also capable of motion detection....... if your interested in helping
I'm very intrested in this. I was thinking to add motion wrapper for this.
But if there's another method, i'm open to that.
I'm pro centralizing everything. I test the camera motion detection already as stand-alone. But hated it a bit that the mails/files were treated as something seperated. So if it could be integrated in LinuxMCE, great...


I'm also looking for a kind of 'fixed movement'. I've got 2 camera's that should cover 2 angles. So i'm thinking to create a small script that 'center' the camera, and then move the 10x up, 6x left (or something like that). I don't know if there's a part in linuxmce that i could/should use?


ps your help on 'creating and uploading templates' was easy to follow! Short and direct...
Maybe a dedicated wiki for this? Could help everybody who wants to create/share templates?
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 08, 2012, 08:40:42 am
There is no 100% sure method of finding mac ranges, but the consensus seem to be that the first 3 or 4 bytes is used as a range. So in you case it would be from 00:0d:c5:d0:00:00 to 00:0d:c5:d0:FF:FF. This can always be changed later on if needed.

To do a quick test, can you open your browser to this address on your camera. You probably need the same user/password format on the url as other commands:
Code: [Select]
http://x.x.x.x/get_status.cgi?user=USER&pwd=PASSWORDand post the output from that.

I suppose it should be possible to do that with some timed event and such, if not too advanced. There is not built-in support for such a thing iirc.
And I don't know how well this will work with built-in motion detection. Ideally cameras should compensate for camera movement, but ymmv. That would be true when using a motion wrapper too, it does not know that the camera moves rather than there is motion in the frame.

Glad you liked my short guide :) I think there should already be wiki articles on this, but maybe they can be improved on.

br,
sambuca



Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 08, 2012, 08:45:51 am
The result of /get_status.cgi?user=USER&pwd=PASSWORD

Code: [Select]
var id='000DC5D047FF';
var sys_ver='11.14.1.46';
var app_ver='2.4.8.12';
var alias='videre';
var now=1344408264;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 08, 2012, 09:28:18 am
The result of /get_status.cgi?user=USER&pwd=PASSWORD

Code: [Select]
var id='000DC5D047FF';
var sys_ver='11.14.1.46';
var app_ver='2.4.8.12';
var alias='videre';
var now=1344408264;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;


ps For the moment i'm looking at zoneminder that looks very good...
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 08, 2012, 11:42:23 am
Ok, that is the result I was expecting. Now I wonder if the camera shuts down the connection immediately, or if it sends more data along as things change (D-Link camera does this). Don't know if this is easy to test with a browser, but you could use wget on the command line: wget <url> and see if it finishes, or just keeps going (stop with CTRL+C in that case).

It's quite easy to a motion detection to this template, but depending on how the camera uses the connection, I might have to make a small code change first.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 08, 2012, 12:40:58 pm
A bit strange, it seems to disconnect, but after an enter, it really stops...

Code: [Select]
DCEROUTER$ sudo wget http://192.168.111.93/get_status.cgi?user=USER&pwd=PASSWORD
[2] 1543
brononius@dcerouter:/var/www/intern$
[2]+  Stopped                 sudo wget http://192.168.111.93/get_status.cgi?user=USER


ps, if you want, i can give you console access to my server...
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 08, 2012, 12:54:09 pm
Right, because of the & on the URL, it doesn't work. Try this:
Code: [Select]
wget "http://192.168.111.93/get_status.cgi?user=USER&pwd=PASSWORD"
It shouldn't be much more questions now, but thanks for the offer.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 08, 2012, 02:13:38 pm
No prob for me. What works easiest for you... ;)

sudo wget "http://192.168.111.93/get_status.cgi?user=USER&pwd=PASSWORD"  -O test.txt
Code: [Select]
--2012-08-08 14:11:13--  http://192.168.111.93/get_status.cgi?user=USER&pwd=PASSWORD
Connecting to 192.168.111.93:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 220 [text/plain]
Saving to: `test.txt'

100%[===================================================================================================================>] 220         --.-K/s   in 0.001s 

2012-08-08 14:11:13 (405 KB/s) - `test.txt' saved [220/220]

more test.txt
Code: [Select]
var id='000DC5D047FF';
var sys_ver='11.14.1.46';
var app_ver='2.4.8.12';
var alias='videre';
var now=1344427874;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 08, 2012, 02:36:55 pm
Ok, I got what I need. I will do some tests for myself and post here when ready :)

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 08, 2012, 09:55:47 pm
I have updated the template a bit, and added motion detection capabilities. The necessary code hasn't been released yet, but you can download the recent binary from the same url as before. You would have to update sqlCVS too, and only new devices will be set up with the new template data.

So: update sqlCVS, download new binary - place it in /usr/pluto/bin, create a new device with the template, reload. (and cross fingers ;) )

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 09, 2012, 09:59:00 am
So i've did:

Not sure what happened, but all my camera's were gone under 'surveillance cameras'.
So i've recreated a camera with template id 2211 (IPCAM02), but couldn't get an image.

sudo /usr/pluto/bin/Advanced_IP_Camera -d 209
Code: [Select]
Advanced_IP_Camera, v.<=version=>
Visit www.plutohome.com for source code and license information

05 08/09/12 9:51:33.512 Connect() failed, Error Code 111 (Connection refused)) <0xb77d96f0>
05 08/09/12 9:51:34.513 Connect() failed, Error Code 111 (Connection refused)) <0xb77d96f0>
05 08/09/12 9:51:35.519 Socket::ReceiveData 0x8814498 failed, bytes left 0 start: 10000 1: 0 1b: 0 2: 0 2b: 0 m_Socket: 3 Event Dev #209 <0xb77d96f0>
05 08/09/12 9:51:35.519 Socket::ReceiveString2 ReceiveData failed m_Socket: -1 Event Dev #209 <0xb77d96f0>
01 08/09/12 9:51:35.519 DCE Router cannot give us config: ReceiveData failed <0xb77d96f0>
01 08/09/12 9:51:35.519 Connect() Failed <0xb77d96f0>
Segmentation fault

A complete reboot of the machine gives me the same result.

ps how can i test the motion detection function? Where can i see that?
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 09, 2012, 10:08:58 am
Are you using device template #2211? that is wrong on my install. The IPCAM02 template should now have ID 2213. If you used 2211 previously, that is probably why your devices disappeared, the template ID was probably changed when you did an sqlCVS update.

The error in the log suggests that there is something wrong with the device, and that it cannot load its device data. Make sure you are using the correct template, and you should check that the template look correct too.

The motion detection can be see in the DCERouter.log as an event sent from the cameras motion detector. The new template should automatically create a motion detector child under the camera device.

The current template will poll the camera every 10 seconds for any changes in motion detection status, so event might not be instant.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 09, 2012, 12:28:46 pm
huh, slik... ?

It was the correct template (2213). Just a typo from me.

I've just removed the device, restarted the computer and wanted to add the camera.
But apparantly linuxMCE isn't running anymore?!

In my logs:
/var/log/pluto/DCERouter.log
Code: [Select]
Thu Aug  9 12:27:21 CEST 2012 Starting
01 08/09/12 12:27:21.492 Got a device 205 with wrong device template 2356 <0xb77b08e0>
01 08/09/12 12:27:21.492 Got a device 206 with wrong device template 2356 <0xb77b08e0>
01 08/09/12 12:27:21.492 Got a device 207 with wrong device template 2356 <0xb77b08e0>
01 08/09/12 12:27:21.492 Got a device 208 with wrong device template 2356 <0xb77b08e0>
05 08/09/12 12:27:22.120 Loaded plug-in device: 3 master device: 10 -- ./File_Grids_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.120 Loaded plug-in device: 4 master device: 27 -- ./General_Info_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.121 Loaded plug-in device: 5 master device: 31 -- ./Climate_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.121 Loaded plug-in device: 6 master device: 9 -- ./Datagrid_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.121 Loaded plug-in device: 7 master device: 39 -- ./Infrared_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.121 Loaded plug-in device: 8 master device: 32 -- ./Lighting_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.122 Loaded plug-in device: 9 master device: 12 -- ./Orbiter_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.123 Loaded plug-in device: 10 master device: 2 -- ./Media_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.123 Loaded plug-in device: 11 master device: 34 -- ./Telecom_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.123 Loaded plug-in device: 12 master device: 52 -- ./Event_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.124 Loaded plug-in device: 13 master device: 33 -- ./Security_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.124 Loaded plug-in device: 14 master device: 1809 -- ./Plug_And_Play_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.126 Loaded plug-in device: 24 master device: 6 -- ./Xine_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.127 Loaded plug-in device: 28 master device: 2123 -- ./Picture_Plugin.so <0xb77b08e0>
05 08/09/12 12:27:22.127 Loaded plug-in device: 31 master device: 36 -- ./MythTV_PlugIn.so <0xb77b08e0>
05 08/09/12 12:27:22.173 Plugin 3 activated <0xb77b08e0>
05 08/09/12 12:27:22.217 Plugin 4 activated <0xb77b08e0>
05 08/09/12 12:27:22.262 Plugin 5 activated <0xb77b08e0>
05 08/09/12 12:27:22.309 Plugin 6 activated <0xb77b08e0>
05 08/09/12 12:27:22.353 Plugin 7 activated <0xb77b08e0>
05 08/09/12 12:27:22.398 Plugin 8 activated <0xb77b08e0>
05 08/09/12 12:27:22.489 Plugin 9 activated <0xb77b08e0>
Return code: 139
3 08/09/12 12:27:22 DCERouter (server) Device died... count=169/200 dev=DCERouter

Not sure if it's caused by the template, or by the 'apt-get upgrade'. But it's a fact that the old camera's are still configured somewhere.
Can/may I simply remove them from my database?


Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 09, 2012, 01:03:55 pm
Something seems to crash the DCERouter.. Don't think it is the template. Did you upgrade everything or just some packages? If you got conflicting versions of LinuxMCE libraries and binaries, this can happen.

You can delete the old camera devices from your database using the mysql tool.
sudo mysql pluto_main
delete from DeviceData where FK_Device=xx;
delete from Device where PK_Device=xx;


br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: Marie.O on August 09, 2012, 02:26:30 pm
There is no FK_Device in DeviceData

Deleting a device is not straightforward. You have leftovers in Device_DeviceData, Device_Command, Device_CommandGroup and maybe something else.
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 09, 2012, 02:37:26 pm
posde, you're right, that should have read Device_DeviceData.

brononius, check first that you don't find the devices under Advanced -> Configuration -> Devices. If you find them there, delete them there.

But for the reasons posde mention, if you need to change it in the database, a better solution could be to update the FK_DeviceTemplate of the Devices:
sudo mysql pluto_main
update Device set FK_DeviceTemplate = 2213 where PK_Device = xx;

and do the last one for each of you old device IDs.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 09, 2012, 03:05:18 pm
brononius, check first that you don't find the devices under Advanced -> Configuration -> Devices. If you find them there, delete them there.
They are there, but i can't click them. :$

update the FK_DeviceTemplate of the Devices:
sudo mysql pluto_main
update Device set FK_DeviceTemplate = 2213 where PK_Device = xx;
I've done this. And alle devices are back in, and clickable.
Can/should i simply remove them from here? or....
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 09, 2012, 03:18:48 pm
After a reboot, all seems fine.
Except 4 camera's i'm not sure they should be in there.


I've added a new one, and a child 'motion detector - 210' is created under the 'IPCAM02 camera - 209'.
But can't find anything back in the logs regarding 'motion' or '210'. :$


tail -f /var/log/pluto/DCERouter.log | grep mot
Code: [Select]
^Cbrononius@dcerouter:~$ tail -f /var/log/pluto/DCERouter.log | grep 210
Code: [Select]
^Cbrononius@dcerouter:~$ tail -f /var/log/pluto/DCERouter.log | grep 209
Code: [Select]
05 08/09/12 15:19:46.209 Socket::ReceiveData 0xa1ad900 failed, bytes left 0 start: 910000 1: 0 1b: 0 2: 0 2b: 0 m_Socket: 189 Incoming_Conn Socket 189 ::ffff:127.0.0.1 <0x4cda0b70>
05 08/09/12 15:19:46.209 Socket::ReceiveString2 ReceiveData failed m_Socket: -1 Incoming_Conn Socket 189 ::ffff:127.0.0.1 <0x4cda0b70>
05 08/09/12 15:19:46.209 TCPIP: Closing connection to -1003 (Router Dev #0) 0xa1ad900 m_Socket: -1 <0x4cda0b70>
05 08/09/12 15:19:46.209 Router::RemoveAndDeleteSocket 0xa1ad900 -1003 <0x4cda0b70>
^C
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 09, 2012, 03:20:40 pm
After a reboot, all seems fine.
Except 4 camera's i'm not sure they should be in there.


I've added a new one, and a child 'motion detector - 210' is created under the 'IPCAM02 camera - 209'.
But can't find anything back in the logs regarding 'motion' or '210'. I've let them run for about 3 minutes... :$


tail -f /var/log/pluto/DCERouter.log | grep mot
Code: [Select]
^Cbrononius@dcerouter:~$ tail -f /var/log/pluto/DCERouter.log | grep 210
Code: [Select]
^Cbrononius@dcerouter:~$ tail -f /var/log/pluto/DCERouter.log | grep 209
Code: [Select]
05 08/09/12 15:19:46.209 Socket::ReceiveData 0xa1ad900 failed, bytes left 0 start: 910000 1: 0 1b: 0 2: 0 2b: 0 m_Socket: 189 Incoming_Conn Socket 189 ::ffff:127.0.0.1 <0x4cda0b70>
05 08/09/12 15:19:46.209 Socket::ReceiveString2 ReceiveData failed m_Socket: -1 Incoming_Conn Socket 189 ::ffff:127.0.0.1 <0x4cda0b70>
05 08/09/12 15:19:46.209 TCPIP: Closing connection to -1003 (Router Dev #0) 0xa1ad900 m_Socket: -1 <0x4cda0b70>
05 08/09/12 15:19:46.209 Router::RemoveAndDeleteSocket 0xa1ad900 -1003 <0x4cda0b70>
^C
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 09, 2012, 05:38:59 pm
Sorry to ask, but you are sure that the camera has motion detection enabled (if there is such a setting)?

Is grep case-sensitive? If so, I think the event is Motion Detected or something like that.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 09, 2012, 07:26:28 pm
No prob for asking, glad to help...

Motion is activated (i'm recieving mails over that way).
See attached picture for settings...

When I do a grep on Motion, i'm getting not much more...
Shouldn't I see it each x seconds in the log?
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 09, 2012, 08:33:48 pm
Pardon me, it is the Sensor Tripped event you will see in the log...

You can also manually open /get_status.cgi on your camera and see if the alarm_status line changes when motion is detected.

The Advanced_IP_Camera devices will only send sensor tripped event when a sensor changes state, so only when motion is first detected, and then when the camera resets that status. And how long that is depends on the camera I guess.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 10, 2012, 06:32:06 am
Hey,

A get_status.cgi gives me:
Code: [Select]
...200;
var alarm_status=1;
var...

So he sees something.
but in the log, i can't find anything.

sudo grep ensor /var/log/pluto/DCERouter.log

sudo grep ripped /var/log/pluto/DCERouter.log

sudo grep 210 /var/log/pluto/DCERouter.log

sudo grep 209 /var/log/pluto/DCERouter.log

sudo grep Motion /var/log/pluto/DCERouter.log
Code: [Select]
05      08/09/12 15:09:34.128            UpdateEntArea::AddDevicesToEntArea adding device 211 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.131            UpdateEntArea::AddDevicesToEntArea adding device 212 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.132            UpdateEntArea::AddDevicesToEntArea adding device 213 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.134            UpdateEntArea::AddDevicesToEntArea adding device 214 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.146            UpdateEntArea::AddDevicesToEntArea adding device 210 Motion Detector to ent area 1 Rack <0xb09fab70>
(adding the stuff yesterday)

sudo grep Detector /var/log/pluto/DCERouter.log
Code: [Select]
05      08/09/12 15:09:34.128            UpdateEntArea::AddDevicesToEntArea adding device 211 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.131            UpdateEntArea::AddDevicesToEntArea adding device 212 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.132            UpdateEntArea::AddDevicesToEntArea adding device 213 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.134            UpdateEntArea::AddDevicesToEntArea adding device 214 Motion Detector to ent area 1 Rack <0xb09fab70>
05      08/09/12 15:09:34.146            UpdateEntArea::AddDevicesToEntArea adding device 210 Motion Detector to ent area 1 Rack <0xb09fab70>
(adding the stuff yesterday)


Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 10, 2012, 06:56:19 am
Ok, just put the logs of pluto on 10 (/etc/pluto.conf).

And now i can see in correct values in the cameras log. But nothing in the global logs.
So apparantly he's reading it correctly. But there's a missing link in linuxMCE?
I don't need to add something extra in linuxMCE? Like for example a 'motion detector' tool? I'm thinking of the 'Motion wrapper'...  ::)

sudo grep alarm_status /var/log/pluto/215_Advanced_IP_Camera.log
Code: [Select]
10      08/10/12 6:47:01.462            EventWriteCallback: s = var alarm_status=0;
var alarm_status=0;
var alarm_status=0;
var alarm_status=0;
10      08/10/12 6:47:11.482            EventWriteCallback: s = var alarm_status=0;
var alarm_status=0;
var alarm_status=0;
var alarm_status=0;
10      08/10/12 6:47:21.497            EventWriteCallback: s = var alarm_status=0;
var alarm_status=1;
var alarm_status=1;
var alarm_status=1;
10      08/10/12 6:47:31.526            EventWriteCallback: s = var alarm_status=1;
var alarm_status=1;
var alarm_status=1;
var alarm_status=1;
10      08/10/12 6:47:41.568            EventWriteCallback: s = var alarm_status=1;


I've created a new camera, and this was all I could found in the DCErouter.log:
Code: [Select]
10      08/10/12 6:44:24.665            Created device 216 Motion Detector (mdl: 54) routed to: 215 (1 CORE) disabled 0 <0xb775e8e0>
10      08/10/12 6:44:25.741            adding device 123 Motion Wrapper to map ent area 1 Rack <0xb775e8e0>
10      08/10/12 6:44:25.745            adding device 216 Motion Detector to map ent area 1 Rack <0xb775e8e0>
10      08/10/12 6:44:24.665            Created DCE device 215 Videre (mdl: 2213) routed to: 215 (1 CORE) disabled 0 <0xb775e8e0>
10      08/10/12 6:44:24.665            Created device 216 Motion Detector (mdl: 54) routed to: 215 (1 CORE) disabled 0 <0xb775e8e0>
10      08/10/12 6:44:25.744            adding device 215 Videre to map ent area 1 Rack <0xb775e8e0>
10      08/10/12 6:44:26.221            Requesthandler 0xac215b98 (device: 8) runThread now running <0x8abe7b70>
10      08/10/12 6:44:31.064            Device 215 connected as foreign template 2208 <0x5b1f1b70>
10      08/10/12 6:44:31.131            Device 215 connected as foreign template 2208 <0x593eeb70>
10      08/10/12 6:44:31.185            Executed query UPDATE Device SET Registered=1,psc_mod=psc_mod WHERE PK_Device=215 (1 rows) <0x589edb70>
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 10, 2012, 07:25:15 am
Can you post more of the Advanced_IP_Camera log, around the place where it says "alarm_status" ?

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 12, 2012, 09:54:10 am
Sorry for the late answer.

Some extra logging (first event: no alarm, later on: alarms...)

Code: [Select]
10 08/12/12 9:50:59.832 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var id='000DC5D047FF'; <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344757859;
var tz=- <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var alias='videre';
var now=1344757859;
var tz=-7200;
var alarm_status=0;
var ddns_status=0; <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var now=1344757859;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: s = var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:50:59.839 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb77dab70>
10 08/12/12 9:50:59.839 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb77dab70>
10 08/12/12 9:50:59.839 EventMethod::MethodURL(): http OK <0xb77dab70>
10 08/12/12 9:51:09.839 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var id='000DC5D047FF'; <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344757869;
var tz=- <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var alias='videre';
var now=1344757869;
var tz=-7200;
var alarm_status=1;
var ddns_status=0; <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var now=1344757869;
var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: s = var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:09.871 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb77dab70>
10 08/12/12 9:51:09.871 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb77dab70>
10 08/12/12 9:51:09.871 EventMethod::MethodURL(): http OK <0xb77dab70>
10 08/12/12 9:51:19.871 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var id='000DC5D047FF'; <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344757879;
var tz=- <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var alias='videre';
var now=1344757879;
var tz=-7200;
var alarm_status=1;
var ddns_status=0; <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var now=1344757879;
var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: s = var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:19.887 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb77dab70>
10 08/12/12 9:51:19.887 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb77dab70>
10 08/12/12 9:51:19.887 EventMethod::MethodURL(): http OK <0xb77dab70>
10 08/12/12 9:51:29.887 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb77dab70>
10 08/12/12 9:51:29.894 EventWriteCallback: s = var id='000DC5D047FF'; <0xb77dab70>
10 08/12/12 9:51:29.894 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb77dab70>
10 08/12/12 9:51:29.894 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344757889;
var tz=- <0xb77dab70>
10 08/12/12 9:51:29.894 EventWriteCallback: s = var alias='videre';
var now=1344757889;
var tz=-7200;
var alarm_status=1;
var ddns_status=0; <0xb77dab70>
10 08/12/12 9:51:29.894 EventWriteCallback: s = var now=1344757889;
var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb77dab70>
10 08/12/12 9:51:29.894 EventWriteCallback: s = var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:29.895 EventWriteCallback: s = var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:29.895 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:29.895 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:29.895 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:29.895 EventWriteCallback: s = var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:29.895 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb77dab70>
10 08/12/12 9:51:29.895 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb77dab70>
10 08/12/12 9:51:29.895 EventMethod::MethodURL(): http OK <0xb77dab70>
10 08/12/12 9:51:39.895 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var id='000DC5D047FF'; <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344757899;
var tz=- <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var alias='videre';
var now=1344757899;
var tz=-7200;
var alarm_status=1;
var ddns_status=0; <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var now=1344757899;
var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: s = var upnp_status=1;
 <0xb77dab70>
10 08/12/12 9:51:39.902 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb77dab70>
10 08/12/12 9:51:39.902 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb77dab70>
10 08/12/12 9:51:39.902 EventMethod::MethodURL(): http OK <0xb77dab70>
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 12, 2012, 01:43:45 pm
Can you please post the log right after the device has started, it prints its configuration then, so I'm sure it's got it right?

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 12, 2012, 01:59:30 pm
This is the part you need?

Code: [Select]
Return code: 2
2 08/12/12 13:51:51 215 (spawning-device) Device requests restart... count=1/50 dev=215
Sun Aug 12 13:51:51 CEST 2012 Restart
========== NEW LOG SECTION ==========
1 08/12/12 13:51:59 215 (spawning-device) Starting... 1
1 08/12/12 13:52:00 215 (spawning-device) Found /usr/pluto/bin/Advanced_IP_Camera
10 08/12/12 13:52:00.198 Device: 215 starting.  Connecting to: localhost <0xb77646f0>
10 08/12/12 13:52:00.256 Setting timeout for socket 4 to 20 <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() Configuration = panUpCmd=/decoder_control.cgi?command=0&onestep=1
panDownCmd=/decoder_control.cgi?command=2&onestep=1
panRightCmd=/decoder_control.cgi?command=6&onestep=1
panLeftCmd=/decoder_control.cgi?command=4&onestep=1
eventMethod1=urlPoll
eventURL1=/get_status.cgi <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() key = panUpCmd, value = /decoder_control.cgi?command=0&onestep=1 <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() key = panDownCmd, value = /decoder_control.cgi?command=2&onestep=1 <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() key = panRightCmd, value = /decoder_control.cgi?command=6&onestep=1 <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() key = panLeftCmd, value = /decoder_control.cgi?command=4&onestep=1 <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() key = eventMethod1, value = urlPoll <0xb77646f0>
10 08/12/12 13:52:00.316 GetEventMethod() requested EventMethod num = 1 <0xb77646f0>
10 08/12/12 13:52:00.316 GetEventMethod() new EventMethod num = 1 <0xb77646f0>
10 08/12/12 13:52:00.316 getConfig() key = eventURL1, value = /get_status.cgi <0xb77646f0>
10 08/12/12 13:52:00.316 GetEventMethod() requested EventMethod num = 1 <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() Children: <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() PK_Device= 216 <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() Motion detector, capabilities = method=1:triggerMethod=pattern:patternOn=var alarm_status=1;:patternOff=var alarm_status=0; <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() key = method, value = 1 <0xb77646f0>
10 08/12/12 13:52:00.317 GetEventMethod() requested EventMethod num = 1 <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() key = triggerMethod, value = pattern <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() key = patternOn, value = var alarm_status=1; <0xb77646f0>
10 08/12/12 13:52:00.317 getConfig() key = patternOff, value = var alarm_status=0; <0xb77646f0>
05 08/12/12 13:52:00.317 m_vectEventMethod.size() = 5. Configured EventMethods: <0xb77646f0>
05 08/12/12 13:52:00.317 GetConfig(): EventMethod 0, m_bRunning = 26, m_sMethod = urlPoll, m_sURL = /get_status.cgi, m_iInterval = 10, m_vectInputDevices = [ m_dwPK_Device = 216, m_dwFK_DeviceTemplate = 54, status = (null), m_sTriggerMethod = pattern, m_sPatternOn = var alarm_status=1;, m_sPatternOff = var alarm_status=0;,  ] <0xb77646f0>
05 08/12/12 13:52:00.317 m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb77646f0>
10 08/12/12 13:52:00.341 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var id='000DC5D047FF'; <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344772320;
var tz=- <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var alias='videre';
var now=1344772320;
var tz=-7200;
var alarm_status=0;
var ddns_status=0; <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var now=1344772320;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: s = var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:00.355 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb7763b70>
10 08/12/12 13:52:00.355 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb7763b70>
10 08/12/12 13:52:00.355 EventMethod::MethodURL(): http OK <0xb7763b70>
10 08/12/12 13:52:00.359 Connect OK <0xb77646f0>
05 08/12/12 13:52:00.359 Creating child 216 <0xb77646f0>
10 08/12/12 13:52:00.359 Got CreateEvent for unknown type 54. <0xb77646f0>
05 08/12/12 13:52:00.359 Note: Device manager has attached a device of type 54 that this has no custom event handler for.  It will not fire events. <0xb77646f0>
10 08/12/12 13:52:00.359 Got CreateCommand for unknown type 54. <0xb77646f0>
05 08/12/12 13:52:00.359 Note: Device manager has attached a device of type 54 that this has no custom handler for.  This is normal for IR. <0xb77646f0>
10 08/12/12 13:52:00.379 Requesthandler 0x9f3c8d0 (device: 215) runThread now running <0xb6361b70>
10 08/12/12 13:52:07.169 Receive string:  <0xb6361b70>
10 08/12/12 13:52:07.169 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:08.474 Receive string:  <0xb6361b70>
10 08/12/12 13:52:08.474 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:09.848 Receive string:  <0xb6361b70>
10 08/12/12 13:52:09.848 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:10.355 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var id='000DC5D047FF'; <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344772330;
var tz=- <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var alias='videre';
var now=1344772330;
var tz=-7200;
var alarm_status=0;
var ddns_status=0; <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var now=1344772330;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: s = var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:10.362 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb7763b70>
10 08/12/12 13:52:10.363 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb7763b70>
10 08/12/12 13:52:10.363 EventMethod::MethodURL(): http OK <0xb7763b70>
10 08/12/12 13:52:11.089 Receive string:  <0xb6361b70>
10 08/12/12 13:52:11.089 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:12.308 Receive string:  <0xb6361b70>
10 08/12/12 13:52:12.309 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:13.436 Receive string:  <0xb6361b70>
10 08/12/12 13:52:13.437 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:14.619 Receive string:  <0xb6361b70>
10 08/12/12 13:52:14.619 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:15.768 Receive string:  <0xb6361b70>
10 08/12/12 13:52:15.768 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:16.898 Receive string:  <0xb6361b70>
10 08/12/12 13:52:16.898 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:17.981 Receive string:  <0xb6361b70>
10 08/12/12 13:52:17.981 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:19.111 Receive string:  <0xb6361b70>
10 08/12/12 13:52:19.111 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:20.299 Receive string:  <0xb6361b70>
10 08/12/12 13:52:20.299 Received  0x9f3c8d0 device: 215 <0xb6361b70>
10 08/12/12 13:52:20.363 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var id='000DC5D047FF'; <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='videre';
var now=1344772340;
var tz=- <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var alias='videre';
var now=1344772340;
var tz=-7200;
var alarm_status=0;
var ddns_status=0; <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var now=1344772340;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var oray_type=0;
var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: s = var upnp_status=1;
 <0xb7763b70>
10 08/12/12 13:52:20.375 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb7763b70>
10 08/12/12 13:52:20.375 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb7763b70>
10 08/12/12 13:52:20.375 EventMethod::MethodURL(): http OK <0xb7763b70>
10 08/12/12 13:52:21.423 Receive string:  <0xb6361b70>
10 08/12/12 13:52:21.423 Received  0x9f3c8d0 device: 215 <0xb6361b70>
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 12, 2012, 05:26:50 pm
Yes, thanks.

There is an improvement in the latest version(in the last 2-3 days) that might help and let it detect the camera status properly. Feel free to try it out when you get a chance.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 13, 2012, 11:26:56 am
Hey,

I've done:

And in the log  "229_Advanced_IP_Camera.log", i see the motion alarm:
Code: [Select]
10 08/13/12 11:19:43.152 EventWriteCallback: s = var alarm_status=1;
But can't find anything in the DCErouter.log. I've searched with:

Not sure what else i can searh for in DCErouter.log.
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 13, 2012, 01:44:51 pm
For the record, this is how it looks in the DCERouter log:

Code: [Select]
07      08/13/12 13:36:52.482           Received Message from 139 (Motion Detector / ) to 0 (unknown / ), type 2 id 9 Event:Sensor Tripped, retry none, parameters: <0x587a4b70>
07      08/13/12 13:36:52.482             Parameter 25(Tripped): 1 <0x587a4b70>

And in the Advanced IP Camera log, there should be something like this:
Code: [Select]
05      08/13/12 13:39:32.565           InputStatusChanged: old status = 0, new status = 1 <0xb779fb70>
05      08/13/12 13:39:32.565           InputStatusChanged: trigger = var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=1;

I simulate the camera by editing a file on a server, but I don't think that should matter.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 13, 2012, 02:36:44 pm
I've got the 'var alarm_status' line in my camera log, but nothing of the 'InputStatusChanged'.
I don't know where the 'motion' looks at?

Code: [Select]
10 08/13/12 14:27:59.874 EventWriteCallback: s = var oray_type=0;
var upnp_status=4;
 <0xb7797b70>
10 08/13/12 14:27:59.874 EventWriteCallback: s = var upnp_status=4;
 <0xb7797b70>
10 08/13/12 14:27:59.874 EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb7797b70>
10 08/13/12 14:27:59.874 EventMethod::MethodURL(): curl_Easy_perform has returned <0xb7797b70>
10 08/13/12 14:27:59.874 EventMethod::MethodURL(): http OK <0xb7797b70>
10 08/13/12 14:28:09.874 EventMethod::MethodURL(): sUrl: http://192.168.111.93:80/get_status.cgi <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var id='000DC5D047FF'; <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var sys_ver='11.14.1.46';
var app_ver='2.4.8.12' <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var app_ver='2.4.8.12';
var alias='Videre';
var now=1344860889;
var tz=- <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var alias='Videre';
var now=1344860889;
var tz=-7200;
var alarm_status=1;
var ddns_status=0; <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var now=1344860889;
var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var tz=-7200;
var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=4;
 <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var alarm_status=1;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=4;
 <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=4;
 <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var ddns_host='';
var oray_type=0;
var upnp_status=4;
 <0xb7797b70>
10 08/13/12 14:28:09.907 EventWriteCallback: s = var oray_type=0;


Must I activate somewhere the motion detection module? Or is this by default running?





When i look at wizard > security > ID230 / template 54 (child of the camera), i see in Capabilities following:

Code: [Select]
method=1:triggerMethod=pattern:patternOn=var alarm_status=1;:patternOff=var alarm_status=0;
Is the ;: correct?
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 13, 2012, 09:13:10 pm
It simply looks for the text "var alarm_status=1;" in the text it receives from the camera. So I can't see why it does not work.

The configuration sets up the Advanced IP Camera to check for this text, and there is nothing more to it. The device needs a child device of the type Motion Detector with the correct data(like what text to look for).
So the ;: is correct. When defining child devices in the template, you cannot use line breaks, so we need to separate the data with : instead.

You could always try to change the Capabilities device data of the motion detector child and see if that helps... Perhaps try to substitute "patternOn=var alarm_status=1;" with "patternOn=alarm_status=1" to keep it simple.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 20, 2012, 11:27:40 am
You could always try to change the Capabilities device data of the motion detector child and see if that helps... Perhaps try to substitute "patternOn=var alarm_status=1;" with "patternOn=alarm_status=1" to keep it simple.

Forget to answer you...  ::)

I've tried to change patternOn=alarm_status=1 (without spaces and so), but give me the same result (or better said, no result).
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 20, 2012, 05:44:54 pm
Not sure what was wrong before. But when i check again, i think it works.

Device 236 is the motion detector for the camera.  
And in the log, you can see that i've got an "Event:Sensor Tripped" for that.


/var/log/pluto/DCErouter.log
Code: [Select]
05      08/20/12 17:39:51.060           XXX: Device: 236, State: ,, <0x645abb70>
05      08/20/12 17:39:51.060           XXX: PK_AlertType: 0, PK_HouseMode: 1 <0x645abb70>
05      08/20/12 17:39:51.062           void ClientSocket::Disconnect() on this socket: 0x98e3d088 (m_Socket: 168) <0x645abb70>
05      08/20/12 17:39:51.062           Socket::ReceiveData 0xa2dba88 failed, bytes left 0 start: 5150000 1: 0 1b: 0 2: 0 2b: 0 m_Socket: 169 Incoming_Conn Socket 169 ::ffff:127.0.0.1 <0x5a59bb70>
05      08/20/12 17:39:51.062           Socket::ReceiveString2 ReceiveData failed m_Socket: -1 Incoming_Conn Socket 169 ::ffff:127.0.0.1 <0x5a59bb70>
05      08/20/12 17:39:51.062           TCPIP: Closing connection to -1003 (Router Dev #0) 0xa2dba88 m_Socket: -1 <0x5a59bb70>
05      08/20/12 17:39:51.062           Router::RemoveAndDeleteSocket 0xa2dba88 -1003 <0x5a59bb70>
07      08/20/12 17:39:51.062           Received Message from 236 (Videre / Voortuin) to 0 (unknown / ), type 2 id 9 Event:Sensor Tripped, retry none, parameters: <0x645abb70>
07      08/20/12 17:39:51.062             Parameter 25(Tripped): 1 <0x645abb70>


With this sensor, i was able to switch on a light once the camera detects motion. So it works great...

Anything else you want me to check/validate/test?
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 20, 2012, 09:45:08 pm
That is great  :)

I was a bit puzzled about what to check next, so I'm glad it works.

I don't have anything else for you to test now. Thank you very much for you help.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on August 21, 2012, 07:32:13 am
I need to thank you.
For the support, and the extra lessons...

I learned:

Title: Re: [SOLVED] IP Camera in 1004
Post by: mkbrown69 on August 21, 2012, 07:28:43 pm
I need to thank you.
For the support, and the extra lessons...

I learned:
  • How to raise the loglevel (/etc/pluto.conf > 4,6,8,10)
  • Each device has his own log file (/var/log/pluto), based on the id
  • With the id. you can find a lot more in the global logfile (/var/log/pluto/DCErouter.log).
  • And that it isn't so difficult to create a template as it seems. ;)

I'd like to echo brononius, and say thanks as well.  I've been following this thread as I'm about to get my cameras configured (playing with the 2121 template, but will look at doing a DCS-930L soon - unless Armor Gnome beats me to it) after I finish something else I've been working on.  I'm guessing it's probably a bad thing to try to do a sql-cvs diff when working on multiple un-finished templates.

It's been very informative watching this thread progress.  Thanks for educating a few of us in the process.

Cheers!

/Mike
Title: Re: [SOLVED] IP Camera in 1004
Post by: Marie.O on August 21, 2012, 08:11:59 pm
multiple unfinished DTs is ALWAYS a recipe for disaster.
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on August 22, 2012, 08:04:10 am
I know some people have bad experiences with creating device templates and sqlCVS.

I'm here to present the opposite view. ;) I have no problem with sqlCVS. But the key is to work with one device template at a time. If you have done several changes in your system at once, failure is much more likely.

The easiest option in that case is to revert all changes (also done on the sqlCVS diff page), and re-do your changes.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: hari on August 25, 2012, 09:08:58 pm
it is possible to work on multiple DTs but you really need to understand the database schema to judge which entries should go in for the checkin of a specific DT
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on November 20, 2012, 12:13:45 pm
Sambuca

i  tryed this  and work,   but always when a hit  a button  orbiter  to pan the camera ,

the advanced_ip_camera dies .

but the camera move  correctly .

do you have any clue ?

thanks
Title: Re: [SOLVED] IP Camera in 1004
Post by: Marie.O on November 20, 2012, 02:26:08 pm
Try to do a backtrace of the coredump using gdb.
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on November 20, 2012, 02:54:18 pm
the  coredump

GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...done.
/home/coredump/1/core_Advanced_IP_Cam_1353411334_1: No such file or directory.
(gdb) qui
dcerouter_1027379:/home/coredump/1# gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1353411
core_Advanced_IP_Cam_1353411246_11  core_Advanced_IP_Cam_1353411286_11
core_Advanced_IP_Cam_1353411269_11  core_Advanced_IP_Cam_1353411334_11
dcerouter_1027379:/home/coredump/1# gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1353411
core_Advanced_IP_Cam_1353411246_11  core_Advanced_IP_Cam_1353411286_11
core_Advanced_IP_Cam_1353411269_11  core_Advanced_IP_Cam_1353411334_11
dcerouter_1027379:/home/coredump/1# gdb /usr/pluto/bin/Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Cam_1353411334_11
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...done.

warning: core file may not match specified executable file.
[New Thread 30681]
[New Thread 30676]
[New Thread 30679]

warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/lib/libcurl.so.4...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libcurl.so.4
Reading symbols from /usr/lib/libmysqlclient_r.so.16...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libmysqlclient_r.so.16
Reading symbols from /usr/pluto/lib/libSerializeClass.so...done.
Loaded symbols for /usr/pluto/lib/libSerializeClass.so
Reading symbols from /usr/pluto/lib/libDCECommon.so...done.
Loaded symbols for /usr/pluto/lib/libDCECommon.so
Reading symbols from /usr/pluto/lib/libPlutoUtils.so...done.
Loaded symbols for /usr/pluto/lib/libPlutoUtils.so
Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0
Reading symbols from /usr/lib/libstdc++.so.6...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/tls/i686/cmov/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libm.so.6
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/i686/cmov/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libc.so.6
Reading symbols from /usr/lib/libidn.so.11...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libidn.so.11
Reading symbols from /usr/lib/liblber-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/liblber-2.4.so.2
Reading symbols from /usr/lib/libldap_r-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libldap_r-2.4.so.2
Reading symbols from /lib/tls/i686/cmov/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/librt.so.1
Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /lib/i686/cmov/libssl.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libssl.so.0.9.8
Reading symbols from /lib/i686/cmov/libcrypto.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libcrypto.so.0.9.8
Reading symbols from /lib/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1
Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2
Reading symbols from /usr/lib/libsasl2.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libsasl2.so.2
Reading symbols from /usr/lib/libgnutls.so.26...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgnutls.so.26
Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /lib/tls/i686/cmov/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libdl.so.2
Reading symbols from /lib/libkeyutils.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libkeyutils.so.1
Reading symbols from /usr/lib/libtasn1.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libtasn1.so.3
Reading symbols from /lib/libgcrypt.so.11...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcrypt.so.11
Reading symbols from /lib/libgpg-error.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/libgpg-error.so.0
Reading symbols from /lib/tls/i686/cmov/libnss_files.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnss_files.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 194 -r localhost -l /var/log/pluto/194_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  0x0056eb43 in realloc () from /lib/tls/i686/cmov/libc.so.
Title: Re: [SOLVED] IP Camera in 1004
Post by: Marie.O on November 20, 2012, 04:50:24 pm
I run gdb in the directory of the binary. Also, after starting gdb execute a bt for backtrace.
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on November 20, 2012, 04:55:12 pm
now the correct BT

This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...done.

warning: core file may not match specified executable file.
[New Thread 28326]
[New Thread 28321]
[New Thread 28324]

warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/lib/libcurl.so.4...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libcurl.so.4
Reading symbols from /usr/lib/libmysqlclient_r.so.16...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libmysqlclient_r.so.16
Reading symbols from /usr/pluto/lib/libSerializeClass.so...done.
Loaded symbols for /usr/pluto/lib/libSerializeClass.so
Reading symbols from /usr/pluto/lib/libDCECommon.so...done.
Loaded symbols for /usr/pluto/lib/libDCECommon.so
Reading symbols from /usr/pluto/lib/libPlutoUtils.so...done.
Loaded symbols for /usr/pluto/lib/libPlutoUtils.so
Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0
Reading symbols from /usr/lib/libstdc++.so.6...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/tls/i686/cmov/libm.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libm.so.6
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/i686/cmov/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libc.so.6
Reading symbols from /usr/lib/libidn.so.11...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libidn.so.11
Reading symbols from /usr/lib/liblber-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/liblber-2.4.so.2
Reading symbols from /usr/lib/libldap_r-2.4.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libldap_r-2.4.so.2
Reading symbols from /lib/tls/i686/cmov/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/librt.so.1
Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /lib/i686/cmov/libssl.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libssl.so.0.9.8
Reading symbols from /lib/i686/cmov/libcrypto.so.0.9.8...(no debugging symbols found)...done.
Loaded symbols for /lib/i686/cmov/libcrypto.so.0.9.8
Reading symbols from /lib/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1
Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2
Reading symbols from /usr/lib/libsasl2.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libsasl2.so.2
Reading symbols from /usr/lib/libgnutls.so.26...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgnutls.so.26
Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /lib/tls/i686/cmov/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libdl.so.2
Reading symbols from /lib/libkeyutils.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libkeyutils.so.1
Reading symbols from /usr/lib/libtasn1.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libtasn1.so.3
Reading symbols from /lib/libgcrypt.so.11...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcrypt.so.11
Reading symbols from /lib/libgpg-error.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/libgpg-error.so.0
Reading symbols from /lib/tls/i686/cmov/libnss_files.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnss_files.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 194 -r localhost -l /var/log/pluto/194_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  0x0028eb43 in realloc () from /lib/tls/i686/cmov/libc.so.6
(gdb) bt
#0  0x0028eb43 in realloc () from /lib/tls/i686/cmov/libc.so.6
#1  0x0805e4bf in DCE::Advanced_IP_Camera::WriteCallback (ptr=0x8978839, size=1, nmemb=2, ourpointer=0xb6dd8044)
    at Advanced_IP_Camera.cpp:419
#2  0x00bb6a28 in ?? () from /usr/lib/libcurl.so.4
#3  0x00bce837 in ?? () from /usr/lib/libcurl.so.4
#4  0x00bd0595 in ?? () from /usr/lib/libcurl.so.4
#5  0x00bd1123 in curl_easy_perform () from /usr/lib/libcurl.so.4
#6  0x0805e3af in DCE::Advanced_IP_Camera::DoURLAccess (this=0x89357b8, sUrl=...) at Advanced_IP_Camera.cpp:396
#7  0x0805ea48 in DCE::Advanced_IP_Camera::CMD_Move_Up (this=0x89357b8, iStreamID=0, sCMD_Result=..., pMessage=0x8981630)
    at Advanced_IP_Camera.cpp:531
#8  0x0806241b in DCE::Advanced_IP_Camera_Command::ReceivedMessage (this=0x89357b8, pMessageOriginal=0x8981630)
    at ../Gen_Devices/Advanced_IP_CameraBase.h:365
#9  0x001b414c in DCE::HandleRequestSocket::RunThread (this=0x89357b8) at HandleRequestSocket.cpp:191
#10 0x001b33f6 in BeginHandleRequestThread (HRqSock=0x89357b8) at HandleRequestSocket.cpp:31
#11 0x009eb96e in start_thread () from /lib/tls/i686/cmov/libpthread.so.0
#12 0x002eb98e in clone () from /lib/tls/i686/cmov/libc.so.6
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 07, 2012, 05:42:04 pm
After  a Update , now   i can see  camera  image   but

every time  that  hit  a button to move camera    the device died

0      12/07/12 14:38:56.384           CMD_Get_Video_Frame: sUrl: http://10.1.1.116:80/snapshot.cgi <0xb61feb70>
10      12/07/12 14:38:56.580           CMD_Get_Video_Frame: data size: 9850 <0xb61feb70>
10      12/07/12 14:38:56.580           Socket::SendMessage type 4 id 0 from 196 to 57 <0xb61feb70>
10      12/07/12 14:38:56.613           Receive string: MESSAGE 67             <0xb61feb70>
10      12/07/12 14:38:56.613           Received MESSAGE 67             0x92347b8 device: 196 <0xb61feb70>
10      12/07/12 14:38:56.613           Received Message type 1 ID 201 from 57 to 196 (device: 196) resp 0 <0xb61feb70>
10      12/07/12 14:38:56.613           SetupCurl() start: sUrl: http://10.1.1.116:80/decoder_control.cgi?command=2&onestep=1; <0xb61feb70>
Return code: 139
3       12/07/12 14:38:56       196 (spawning-device)   Device died... count=19/50 dev=196
Fri Dec  7 14:38:56 BRST 2012 died
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on December 10, 2012, 09:39:11 am
I think i'm having a simular issue.
After a complete reinstallation of my machine, my camera snapshots (admin>security>view camera's) sometimes show by refresh, sometimes not.

When i open a log of an IP-camera, i've got:

Quote from: sudo tail -50 340_Advanced_IP_Camera.log
var oray_type=0;
var upnp_status=0;
 <0xb7769b70>
05   12/10/12 9:33:21.978      InputStatusChanged: old status = 0, new status = 0 <0xb7769b70>
Return code: 134
3   12/10/12 09:33:22   340 (spawning-device)   Device died... count=49/50 dev=340
Mon Dec 10 09:33:22 CET 2012 died
========== NEW LOG SECTION ==========
1   12/10/12 09:33:32   340 (spawning-device)   Starting... 50
1   12/10/12 09:33:32   340 (spawning-device)   Found /usr/pluto/bin/Advanced_IP_Camera
05   12/10/12 9:33:32.757      m_vectEventMethod.size() = 5. Configured EventMethods: <0xb76f66f0>
05   12/10/12 9:33:32.757      GetConfig(): EventMethod 1, m_bRunning = 26, m_sMethod = urlPoll, m_sURL = /get_status.cgi, m_iInterval = 10, m_vectInputDevices = [ m_dwPK_Device = 341, m_dwFK_DeviceTemplate = 54, status = (null), m_sTriggerMethod = pattern, m_sPatternOn = var alarm_status=1;, m_sPatternOff = var alarm_status=0;,  ] <0xb76f66f0>
05   12/10/12 9:33:32.757      m_mapPK_Device_OutputDevice.size() = 0. Configured OutputDevices: <0xb76f66f0>
05   12/10/12 9:33:32.758      Creating child 341 <0xb76f66f0>
05   12/10/12 9:33:32.758      Note: Device manager has attached a device of type 54 that this has no custom event handler for.  It will not fire events. <0xb76f66f0>
05   12/10/12 9:33:32.758      Note: Device manager has attached a device of type 54 that this has no custom handler for.  This is normal for IR. <0xb76f66f0>
05   12/10/12 9:33:32.765      InputStatusChanged: trigger = var alias='Sentio';
var now=236957;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: old status = 0, new status = 0 <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: trigger = var now=236957;
var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var  <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: old status = 0, new status = 0 <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: trigger = var tz=-7200;
var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=0;
 <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: old status = 0, new status = 0 <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: trigger = var alarm_status=0;
var ddns_status=0;
var ddns_host='';
var oray_type=0;
var upnp_status=0;
 <0xb76f5b70>
05   12/10/12 9:33:32.765      InputStatusChanged: old status = 0, new status = 0 <0xb76f5b70>
Return code: 134
3   12/10/12 09:33:33   340 (spawning-device)   Device died... count=50/50 dev=340
Mon Dec 10 09:33:33 CET 2012 died
3   12/10/12 09:33:43   340 (spawning-device)   Aborting restart of device 340...
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on December 10, 2012, 10:14:42 am
Can someone provide a stack trace for this problem?

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 10, 2012, 11:06:37 am
Sambuca   

this is the log that you want?


var p2p_local_port=23199;
 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventWriteCallback: s = var ddns_host='/vipddns/upgengxin.asp';
var oray_type=0;
var upnp_status=0;
var p2p_status=0;
var p2p_local_port=23199;
 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventWriteCallback: s = var oray_type=0;
var upnp_status=0;
var p2p_status=0;
var p2p_local_port=23199;
 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventWriteCallback: s = var upnp_status=0;
var p2p_status=0;
var p2p_local_port=23199;
 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventWriteCallback: s = var p2p_status=0;
var p2p_local_port=23199;
 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventWriteCallback: s = var p2p_local_port=23199;
 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventWriteCallback: compacting m_sEventBuffer, new length = 0 <0xb76f5b70>
10      12/10/12 8:04:28.959            EventMethod::MethodURL(): curl_Easy_perform has returned <0xb76f5b70>
10      12/10/12 8:04:28.959            EventMethod::MethodURL(): http OK <0xb76f5b70>
10      12/10/12 8:04:29.335            Receive string: MESSAGE 103            <0xb64feb70>
10      12/10/12 8:04:29.335            Received MESSAGE 103            0x9920428 device: 196 <0xb64feb70>
10      12/10/12 8:04:29.335            Received Message type 1 ID 84 from 57 to 196 (device: 196) resp 1 <0xb64feb70>
10      12/10/12 8:04:29.335            CMD_Get_Video_Frame: sUrl: http://10.1.1.116:80/snapshot.cgi <0xb64feb70>
10      12/10/12 8:04:29.737            CMD_Get_Video_Frame: data size: 10326 <0xb64feb70>
10      12/10/12 8:04:29.737            Socket::SendMessage type 4 id 0 from 196 to 57 <0xb64feb70>
10      12/10/12 8:04:30.147            Receive string: MESSAGE 103            <0xb64feb70>
10      12/10/12 8:04:30.147            Received MESSAGE 103            0x9920428 device: 196 <0xb64feb70>
10      12/10/12 8:04:30.147            Received Message type 1 ID 84 from 57 to 196 (device: 196) resp 1 <0xb64feb70>
10      12/10/12 8:04:30.147            CMD_Get_Video_Frame: sUrl: http://10.1.1.116:80/snapshot.cgi <0xb64feb70>
10      12/10/12 8:04:30.672            CMD_Get_Video_Frame: data size: 10292 <0xb64feb70>
10      12/10/12 8:04:30.672            Socket::SendMessage type 4 id 0 from 196 to 57 <0xb64feb70>
10      12/10/12 8:04:30.925            Receive string: MESSAGE 67             <0xb64feb70>
10      12/10/12 8:04:30.925            Received MESSAGE 67             0x9920428 device: 196 <0xb64feb70>
10      12/10/12 8:04:30.925            Received Message type 1 ID 203 from 57 to 196 (device: 196) resp 0 <0xb64feb70>
10      12/10/12 8:04:30.925            SetupCurl() start: sUrl: http://10.1.1.116:80/decoder_control.cgi?command=6&onestep=1; <0xb64feb70>
 <unfinished ...>
+++ killed by SIGSEGV (core dumped) +++
Segmentation fault (core dumped)
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on December 13, 2012, 09:04:40 am
No, I was looking for a gdb stack trace.
First, look in /home/coredump/1/ for files named core_Advanced_IP_Camera*
Then:
Code: [Select]
cd /usr/pluto/bin
gdb Advanced_IP_Camera /home/coredump/1/core_Advanced_IP_Camera_xxxxx
Where you replace xxxxx with the newest file.

This should load the debugged (gdb) and the dump file. Then type "bt" (withouth the quotes) and press enter.

This should give you a stack trace.

Thanks.
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 13, 2012, 10:49:14 am
Sambuca 

the correct log .

dcerouter_1027379:/usr/pluto/bin# gdb Advanced_IP_Camera /home/coredump/1/core_A                                                                             dvanced_IP_Cam_1355391997_11
GNU gdb (GDB) 7.1-ubuntu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/pluto/bin/Advanced_IP_Camera...done.

warning: core file may not match specified executable file.
[New Thread 23236]
[New Thread 23230]
[New Thread 23233]
[New Thread 23234]

warning: Can't read pathname for load map: Input/output error.
Reading symbols from /usr/lib/libcurl.so.4...(no debugging symbols found)...done                                                                             .
Loaded symbols for /usr/lib/libcurl.so.4
Reading symbols from /usr/lib/libmysqlclient_r.so.16...(no debugging symbols fou                                                                             nd)...done.
Loaded symbols for /usr/lib/libmysqlclient_r.so.16
Reading symbols from /usr/pluto/lib/libSerializeClass.so...done.
Loaded symbols for /usr/pluto/lib/libSerializeClass.so
Reading symbols from /usr/pluto/lib/libDCECommon.so...done.
Loaded symbols for /usr/pluto/lib/libDCECommon.so
Reading symbols from /usr/pluto/lib/libPlutoUtils.so...done.
Loaded symbols for /usr/pluto/lib/libPlutoUtils.so
Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...(no debugging symbols                                                                              found)...done.
Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0
Reading symbols from /usr/lib/libstdc++.so.6...(no debugging symbols found)...do                                                                             ne.
Loaded symbols for /usr/lib/libstdc++.so.6
Reading symbols from /lib/tls/i686/cmov/libm.so.6...(no debugging symbols found)                                                                             ...done.
Loaded symbols for /lib/tls/i686/cmov/libm.so.6
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
Reading symbols from /lib/tls/i686/cmov/libc.so.6...(no debugging symbols found)                                                                             ...done.
Loaded symbols for /lib/tls/i686/cmov/libc.so.6
Reading symbols from /usr/lib/libidn.so.11...(no debugging symbols found)...done                                                                             .
Loaded symbols for /usr/lib/libidn.so.11
Reading symbols from /usr/lib/liblber-2.4.so.2...(no debugging symbols found)...                                                                             done.
Loaded symbols for /usr/lib/liblber-2.4.so.2
Reading symbols from /usr/lib/libldap_r-2.4.so.2...(no debugging symbols found).                                                                             ..done.
Loaded symbols for /usr/lib/libldap_r-2.4.so.2
Reading symbols from /lib/tls/i686/cmov/librt.so.1...(no debugging symbols found                                                                             )...done.
Loaded symbols for /lib/tls/i686/cmov/librt.so.1
Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)                                                                             ...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /lib/i686/cmov/libssl.so.0.9.8...(no debugging symbols foun                                                                             d)...done.
Loaded symbols for /lib/i686/cmov/libssl.so.0.9.8
Reading symbols from /lib/i686/cmov/libcrypto.so.0.9.8...(no debugging symbols f                                                                             ound)...done.
Loaded symbols for /lib/i686/cmov/libcrypto.so.0.9.8
Reading symbols from /lib/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...(no debugging symbols fo                                                                             und)...done.
Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1
Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...(no debugging symbols foun                                                                             d)...done.
Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...(no debugging symbols f                                                                             ound)...done.
Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2
Reading symbols from /usr/lib/libsasl2.so.2...(no debugging symbols found)...don                                                                             e.
Loaded symbols for /usr/lib/libsasl2.so.2
Reading symbols from /usr/lib/libgnutls.so.26...(no debugging symbols found)...d                                                                             one.
Loaded symbols for /usr/lib/libgnutls.so.26
Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done                                                                             .
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /usr/lib/libk5crypto.so.3...(no debugging symbols found)...                                                                             done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)                                                                             ...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /lib/tls/i686/cmov/libdl.so.2...(no debugging symbols found                                                                             )...done.
Loaded symbols for /lib/tls/i686/cmov/libdl.so.2
Reading symbols from /lib/libkeyutils.so.1...(no debugging symbols found)...done                                                                             .
Loaded symbols for /lib/libkeyutils.so.1
Reading symbols from /usr/lib/libtasn1.so.3...(no debugging symbols found)...don                                                                             e.
Loaded symbols for /usr/lib/libtasn1.so.3
Reading symbols from /lib/libgcrypt.so.11...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcrypt.so.11
Reading symbols from /lib/libgpg-error.so.0...(no debugging symbols found)...don                                                                             e.
Loaded symbols for /lib/libgpg-error.so.0
Reading symbols from /lib/tls/i686/cmov/libnss_files.so.2...(no debugging symbol                                                                             s found)...done.
Loaded symbols for /lib/tls/i686/cmov/libnss_files.so.2
Core was generated by `/usr/pluto/bin/Advanced_IP_Camera -d 196 -r localhost -l                                                                              /var/log/pluto/196_Adv'.
Program terminated with signal 11, Segmentation fault.
#0  0x007e6b43 in realloc () from /lib/tls/i686/cmov/libc.so.6
(gdb) bt
#0  0x007e6b43 in realloc () from /lib/tls/i686/cmov/libc.so.6
#1  0x0805e4bf in DCE::Advanced_IP_Camera::WriteCallback (ptr=0x9f6247c,
    size=1, nmemb=4, ourpointer=0xb63bf044) at Advanced_IP_Camera.cpp:419
#2  0x0069ba28 in ?? () from /usr/lib/libcurl.so.4
#3  0x006b3837 in ?? () from /usr/lib/libcurl.so.4
#4  0x006b5595 in ?? () from /usr/lib/libcurl.so.4
#5  0x006b6123 in curl_easy_perform () from /usr/lib/libcurl.so.4
#6  0x0805e3af in DCE::Advanced_IP_Camera::DoURLAccess (this=0x9f1e7b8,
    sUrl=...) at Advanced_IP_Camera.cpp:396
#7  0x0805eefe in DCE::Advanced_IP_Camera::CMD_Move_Right (this=0x9f1e7b8,
    iStreamID=0, sCMD_Result=..., pMessage=0x9f6a790)
    at Advanced_IP_Camera.cpp:585
#8  0x08062e11 in DCE::Advanced_IP_Camera_Command::ReceivedMessage (
    this=0x9f1e7b8, pMessageOriginal=0x9f6a790)
    at ../Gen_Devices/Advanced_IP_CameraBase.h:443
#9  0x0033b14c in DCE::HandleRequestSocket::RunThread (this=0x9f1e7b8)
    at HandleRequestSocket.cpp:191
#10 0x0033a3f6 in BeginHandleRequestThread (HRqSock=0x9f1e7b8)
    at HandleRequestSocket.cpp:31
#11 0x0019396e in start_thread () from /lib/tls/i686/cmov/libpthread.so.0
#12 0x0084398e in clone () from /lib/tls/i686/cmov/libc.so.6
Title: Re: [SOLVED] IP Camera in 1004
Post by: brononius on December 13, 2012, 03:52:23 pm

I removed all IP-camera's (4 pieces) since the core keeps dying.
And for more then 24 hours, no problems.

When i added the motion wrapper and IP-camera's again, the core immediate starts dying each +/- 2 minutes...

Let me know if can help in any way!

Title: Re: [SOLVED] IP Camera in 1004
Post by: Marie.O on December 13, 2012, 04:16:08 pm
/me did not know that one still needs the motion wrapper with advanced ip cam.
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 13, 2012, 04:27:23 pm
as I understand motion is not necessary   for Advanced ip camera work

Carlos
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on December 13, 2012, 09:38:52 pm
The motion wrapper shouldn't be needed for the advanced camera, no, but it depends on whether the camera itself supports motion detection. I haven't tried the two together though, so no guarantees :)

I wasn't able to reproduce the bug in my setup, so I'm guessing a bit here. I committed a possible fix that should be in the next update.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 14, 2012, 06:41:43 pm
Sambuca,

the update is not good . now  advanced ip camera died when i try to view camera



 
10      12/14/12 15:39:16.755           CMD_Get_Video_Frame: sUrl: http://10.1.1.88:80/snapshot.cgi <0xb632eb70>
10      12/14/12 15:39:16.972           CMD_Get_Video_Frame: data size: 36476 <0xb632eb70>
10      12/14/12 15:39:16.972           Socket::SendMessage type 4 id 0 from 196 to 57 <0xb632eb70>
Return code: 134
3       12/14/12 15:39:16       196 (spawning-device)   Device died... count=13/50 dev=196
Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on December 14, 2012, 09:55:56 pm
Sorry about that, I've committed a fix. It should be available once posde has run a new build.

regards,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 15, 2012, 11:52:53 am
without words, simply fantastic, great job

thank you

Carlos

Title: Re: [SOLVED] IP Camera in 1004
Post by: Marie.O on December 15, 2012, 12:34:08 pm
Fix has been built. Please test.
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on December 15, 2012, 12:44:40 pm
works ....

like I said .


"without words, simply fantastic, great job"

thank you

Carlos
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on January 04, 2013, 10:26:08 am
Sambuca ,

on motion detection no image was registered on alerts logs this is correct ?

Title: Re: [SOLVED] IP Camera in 1004
Post by: sambuca on January 04, 2013, 11:00:08 am
I'm not really sure. I think that maybe you need to set this up in the "Wizard | Security - Video links" first.

br,
sambuca
Title: Re: [SOLVED] IP Camera in 1004
Post by: cfernandes on January 04, 2013, 11:05:25 am
i have configured,   
but on secure logs only show a small picture with  text  photo not available.