Page 10 of 22

Re: Surveillance camera based on BuildRoot and Motion

Posted: Tue Nov 25, 2014 7:58 am
by ccrisan
The reboot loop usually happens when the wifi is configured but the connection does not succeed for some reason. It behaves like a software watchdog, resetting the system in case of connection issues. Make sure you:
(a) have a supported wifi adapter (i.e. you're seeing it as wlan0 when issuing an iwconfig)
(b) you have a WPA-enabled network (as opposed to WEP)
(c) you have correctly set your wifi network details (check the /data/etc/wpa_supplicant.conf)

Of course you'll need to do all these using your working Ethernet connection and a remote login with SSH/putty.
htfb wrote:Like the look of this.

Have had software running from fresh image on SD card, with Ethernet connection. When I try to enable wifi from within software using web page, I add SSID and key, then click on Apply button. I then end up with endless loop where from watching RPi indicator lights, it looks like it is rebooting all the time. Am I missing something? (I've had wifi working with Raspian on another SD card, so the dongle is ok). Thanks

Re: Surveillance camera based on BuildRoot and Motion

Posted: Tue Nov 25, 2014 10:28 pm
by maddogdave
The latest image is now working on my A+. Thanks for the very speedy update CCrisan.

Re: Surveillance camera based on BuildRoot and Motion

Posted: Thu Nov 27, 2014 8:15 am
by htfb
Following on from my failure to get wifi working, I have just re-read an older post in this thread that mentions that the SSID name should not have spaces - is that correct? My router has a name that contains two words with a space between them. This has worked with everything else since I got it!

Does the Wireless Network feature in the Advanced Settings section of the config work? I tried that but got into the endless reboot loop - maybe because of my SSID name containing a space?

Thanks

Re: Surveillance camera based on BuildRoot and Motion

Posted: Thu Nov 27, 2014 7:33 pm
by Thaui
What answer do you expect? Change the SSID for testing and you will get a result. Good luck

Re: Surveillance camera based on BuildRoot and Motion

Posted: Thu Nov 27, 2014 10:19 pm
by htfb
Thaui - the response I hoped for would be for someone to confirm that a space in the SSID can be a problem. I do not want to change my SSID to test this because it then means my current setup would become unavailable to my family while I mess about with my RPi.

I have used my wifi USB dongle successfully with my RPi and Raspbian, using my SSID containing a space. To me, I should be able to use the same SSID with this software.

Re: Surveillance camera based on BuildRoot and Motion

Posted: Fri Nov 28, 2014 3:14 pm
by Luky
htfb wrote:Thaui - the response I hoped for would be for someone to confirm that a space in the SSID can be a problem. I do not want to change my SSID to test this because it then means my current setup would become unavailable to my family while I mess about with my RPi.

I have used my wifi USB dongle successfully with my RPi and Raspbian, using my SSID containing a space. To me, I should be able to use the same SSID with this software.

An SSID with a space does not work for me.
Without a space works perfectly!

Re: Surveillance camera based on BuildRoot and Motion

Posted: Fri Nov 28, 2014 4:27 pm
by DougieLawson
Are you enclosing the string with a space in quotes?

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sat Nov 29, 2014 2:45 pm
by cyrakuse
Hi,

in motion pie, is it possible to have a picture joined with the mail notification ?

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 07, 2014 6:18 pm
by ccrisan
Hello there,

I have released a new version. Here's what's new:
* full-screen camera frame fix when viewing a remote motionEye camera
* camera frames now indicate motion detection visually by turning to a redish color
* added minimum motion frames option support (in motion detection settings)
* max. motion threshold setting is now 20%, default event gap is now 10 seconds and default movie quality is now 85%
* added a visual feedback when shutting down from UI
* libjpeg turbo is now used to improve performance (thanks go to https://github.com/jjrojoc for the tip)
* logging and console login are now enabled on tty1 over the framebuffer (console on HDMI, in other words)
* SFTP is now enabled for easier access, using the root account
* the PI is rebooted if ethernet connection is lost for 20 seconds
* kernel updated to 3.12.34
* rpi-firmware & rpi-userland updated to latest versions

Updating to this version using the Software Update function is possible only from 20141123. Users of older versions need to write the image on their SD cards manually.

Re: Surveillance camera based on BuildRoot and Motion

Posted: Fri Dec 19, 2014 5:55 pm
by bench2010
Bro, thanks for this amazing software and the awesome updates. I appreciate your work!

I want to build an outdoor enclosure. Anyone have any tips? Is an outdoor dummy cam a good option?

Sorry if this is off topic.

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sat Dec 20, 2014 9:56 am
by Thaui
I build an outdoor surveillance cam with an empty camra enclosure like this

http://www.ebay.de/itm/Aluminium-Kamera ... 1c33e530e9

You have sufficient space and you can include the USB power supply as well in the box. This will avoid losses in the power supply cable. You also have sufficient space for a wifi adapter with external antenna. The second hole in the casing you can fix the antenna with some silicon. Another article is here but wih some other firmware which never worked reliable

http://www.raspberrypi.org/turn-your-pi ... lance-cam/
Good luck

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 21, 2014 2:30 pm
by FreakHavoc
First of all, thanks to ccrisan for developing motionPie, its great!

If you have a Raspberry pi camera module, you might want to capture images using the 2592x1944 resolution. Currently, the highest selectable resolution in motionPie is 1600x1200. To enable the highest resolution, follow these steps:

1) Login to the Pi using Putty or similar software. User name: root, password: the last eight numbers or letters in the Pi name displayed in the top left corner of the motionPie interface.

2) Type the following two commands:

Code: Select all

mount -o remount,rw /
nano /programs/motioneye/src/v4l2ctl.py
3) Scroll down to the line saying "resolutions.add((1600, 1200))" at around line 114. Below this, insert

Code: Select all

resolutions.add((2592, 1944))
4) Hit CTRL+X and answer "y"

5) To restart the Pi, type "reboot".

6) Wait a minute or two, and when you log into the motionPie interface again the higher resolution should be available.

I have tested this using a Raspberry Pi model B with a wired connection, set to save a still image every 60 seconds. It works very well, with the preview window refreshing every other second or so. Thanks to ccrisan for providing me with the necessary information to test this. Hopefully the 2592x1944 resolution can be included in later versions of motionPie!

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 21, 2014 8:12 pm
by geppetto
Hmmmmm....
Trying motionpi with my model B and noir camera.

Logged into the IP address and up pops the screen with the live picture showing as camera 1.

What I'm not getting are the setup menus.
It's just a blank space to the right of the camera preview box...
Am I doing something silly?

Phil

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 21, 2014 8:19 pm
by geppetto
Sorry guys, scrub that...
I wasn't logging in as admin....

Working now

Phil

Re: Surveillance camera based on BuildRoot and Motion

Posted: Wed Dec 24, 2014 8:36 am
by aquadat0r
how many IP cameras can the Pi manage with motionPie?

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sat Dec 27, 2014 7:02 pm
by Boothy
Hi All from a real newbie

When I try to boot motionpie from sd card on a B+ model it goes through boot sequence but stops at line asking for login, cursor flashes but does not allow me to input anything:-

Starting motioneye: done

welcome to motionpie
mp- 5____5741 login _

I have tried several version with no change, am I missing something ?

Thanks in advance

Boothy

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 28, 2014 9:17 am
by ccrisan
Read this: https://github.com/ccrisan/motionPie#first-boot. Use your browser, not your HDMI-connected monitor.
Boothy wrote:Hi All from a real newbie

When I try to boot motionpie from sd card on a B+ model it goes through boot sequence but stops at line asking for login, cursor flashes but does not allow me to input anything:-

Starting motioneye: done

welcome to motionpie
mp- 5____5741 login _

I have tried several version with no change, am I missing something ?

Thanks in advance

Boothy

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 28, 2014 11:09 am
by Boothy
ccrisan many Thanks for a quick response, I am getting my head around it now, I will try this later

boothy

Re: Surveillance camera based on BuildRoot and Motion

Posted: Sun Dec 28, 2014 7:03 pm
by ccrisan
Hello to everyone!

Santa's been busy working on a new version of motionPie: 20141228 has been released. I've been meaning to have it ready for Christmas but it seems I have underestimated the required work. The following changes have been made since the last stable version:
* The authentication mechanism has been completely rewritten and is now based on a request signature, rather than the good old HTTP Basic Auth. This not only improves security but also makes it compatible with most of the platforms and devices used these days.
* The v4l2-ctl program has been patched to work again. One of the users noticed it had been broken for a while. Real time video controls should work again.
* Drivers for the various USB ethernet adapters are now included.
* There's an FTP server enabled by default that accepts anonymous logins and allows easy downloading of media files.
* The writeimage.sh script has been enhanced to allow tweaking of SSH, SMB and FTP services. More precisely, it is now possible to enable/disable any of these services, make them require authentication or allow remote write access.
* When changing the admin password in the UI, the root password of the system is updated accordingly (by default it is still the S/N of the PI). This applies to all types of administrative logins and has been introduced for security reasons.
* The reboot button is back (some users seem to find it useful).
* The automatic brightness option is back as well (but don't blame me if it does not work as you expect).
* The number of files is now shown on the group button in the media browser.
* It is now possible to remove an entire group of media files using a big red "delete" button.
* The timelapse function has been rewritten to overcome some issues. It now works well for remote motionEye cameras and displays a progress bar to help estimating the remaining time to completion.

You will need to manually download and install 20141228, since it's marked as "prerelease". Santa might have had a few drinks while working on it and chances are that stability issues and other errors appear. Please test it as much as you can and come back with your feedback so I can fix any problems and release a stable version.

Calin.

P.S. Download the image from here: https://github.com/ccrisan/motionPie/re ... g/20141228.

Re: Surveillance camera based on BuildRoot and Motion

Posted: Mon Dec 29, 2014 4:39 pm
by 130mbit
Hi ccrisan, good work on motionpie!

I'm having issues with the Samba setup on my Motionpie install. I've set it up to connect to my main PC (Ubuntu 14.10) which has an SMB directory set up, but the Motionpie install doesn't appear to mount it until I go into the admin page, make a superficial change to the config, apply it, then revert it back to the working config (very strange). It will then quite happily write to the directory on my PC (until I reboot either the Pi or the PC).

My setup is as follows:

Pi

/data/etc/thread-1.conf

Code: Select all

 @working_schedule_type outside
# @enabled on
# @name Camera1
# @webcam_resolution 100
# @network_share_name motioneye
# @network_server 192.168.0.91
# @motion_detection on
# @network_username ben
# @storage_device network-share
# @preserve_movies 182
# @preserve_pictures 0
# @network_password password123
# @id 1
# @working_schedule
# @webcam_server_resize off


lightswitch 50
snapshot_interval 0
noise_level 31
ffmpeg_output_movies on
stream_motion off
target_dir /data/media/motioneye_192_168_0_91_motioneye_ben
text_double on
height 480
width 640
stream_quality 85
threshold 6060
quality 85
post_capture 4
on_event_end /programs/motioneye/eventrelay.py stop %t
text_left Cam1
pre_capture 2
noise_tune on
picture_filename
locate_motion_style redbox
locate_motion_mode off
contrast 0
stream_maxrate 5
output_pictures off
hue 0
saturation 0
stream_localhost off
videodevice /dev/video0
ffmpeg_variable_bitrate 0
ffmpeg_video_codec msmpeg4
text_changes off
movie_filename %Y-%m-%d/%H-%M-%S
event_gap 10
auto_brightness off
stream_port 8081
rotate 270
text_right %Y-%m-%d\n%T
on_event_start /programs/motioneye/eventrelay.py start %t
brightness 0
ffmpeg_bps 150528
framerate 7
emulate_motion off
/var/log/motioneye.log (snippet taken after a reboot)

Code: Select all

2014-12-29 16:14:49: INFO: executing "/sbin/reboot"
^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^$
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:15:16: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
2014-12-29 16:15:16: INFO: cleanup started
2014-12-29 16:15:16: INFO: wsswitch started
2014-12-29 16:15:16: INFO: thumbnailer started
2014-12-29 16:15:17: INFO: server started
2014-12-29 16:15:48: ERROR: authentication failed for user admin
2014-12-29 16:15:50: WARNING: control hue not found for device /dev/video0
2014-12-29 16:15:50: WARNING: control hue not found for device /dev/video0
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:20:15: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:25:15: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:30:15: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
PC

$testparm results:

Code: Select all

[motioneye]
        path = /home/ben/motioneye
        valid users = ben
        read only = No
        guest ok = Yes
The password entered for

Code: Select all

smbpasswd -a ben
on my PC matches the password entered on the config page on MotionPie.

Any ideas?

Re: Surveillance camera based on BuildRoot and Motion

Posted: Tue Dec 30, 2014 9:53 am
by ccrisan
Hi,

It's difficult to tell what the problem might be in these cases. There's one thing though, you have both "guest ok = yes" and "valid users = ben". Do you plan to use this share authenticated or not? What is your "map to guest" setting's value?

You can try to manually mount the share (from an SSH on your PI) and see what happens:

Code: Select all

mount.cifs //192.168.0.91/motioneye /data/media/some_dir -o username=something,password=something
or

Code: Select all

mount.cifs //192.168.0.91/motioneye /data/media/some_dir -o guest
Make sure the mount succeeds and that the resulted mount at /data/media/some_dir is writable. Let me know of any errors that might be printed by the command.
130mbit wrote:Hi ccrisan, good work on motionpie!

I'm having issues with the Samba setup on my Motionpie install. I've set it up to connect to my main PC (Ubuntu 14.10) which has an SMB directory set up, but the Motionpie install doesn't appear to mount it until I go into the admin page, make a superficial change to the config, apply it, then revert it back to the working config (very strange). It will then quite happily write to the directory on my PC (until I reboot either the Pi or the PC).

My setup is as follows:

Pi

/data/etc/thread-1.conf

Code: Select all

 @working_schedule_type outside
# @enabled on
# @name Camera1
# @webcam_resolution 100
# @network_share_name motioneye
# @network_server 192.168.0.91
# @motion_detection on
# @network_username ben
# @storage_device network-share
# @preserve_movies 182
# @preserve_pictures 0
# @network_password password123
# @id 1
# @working_schedule
# @webcam_server_resize off


lightswitch 50
snapshot_interval 0
noise_level 31
ffmpeg_output_movies on
stream_motion off
target_dir /data/media/motioneye_192_168_0_91_motioneye_ben
text_double on
height 480
width 640
stream_quality 85
threshold 6060
quality 85
post_capture 4
on_event_end /programs/motioneye/eventrelay.py stop %t
text_left Cam1
pre_capture 2
noise_tune on
picture_filename
locate_motion_style redbox
locate_motion_mode off
contrast 0
stream_maxrate 5
output_pictures off
hue 0
saturation 0
stream_localhost off
videodevice /dev/video0
ffmpeg_variable_bitrate 0
ffmpeg_video_codec msmpeg4
text_changes off
movie_filename %Y-%m-%d/%H-%M-%S
event_gap 10
auto_brightness off
stream_port 8081
rotate 270
text_right %Y-%m-%d\n%T
on_event_start /programs/motioneye/eventrelay.py start %t
brightness 0
ffmpeg_bps 150528
framerate 7
emulate_motion off
/var/log/motioneye.log (snippet taken after a reboot)

Code: Select all

2014-12-29 16:14:49: INFO: executing "/sbin/reboot"
^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^$
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:15:16: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
2014-12-29 16:15:16: INFO: cleanup started
2014-12-29 16:15:16: INFO: wsswitch started
2014-12-29 16:15:16: INFO: thumbnailer started
2014-12-29 16:15:17: INFO: server started
2014-12-29 16:15:48: ERROR: authentication failed for user admin
2014-12-29 16:15:50: WARNING: control hue not found for device /dev/video0
2014-12-29 16:15:50: WARNING: control hue not found for device /dev/video0
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:20:15: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:25:15: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
mount error(5): Input/output error
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
2014-12-29 16:30:15: ERROR: failed to mount smb share "//192.168.0.91/motioneye" at "/data/media/motioneye_192_168_0_91_motioneye_ben"
PC

$testparm results:

Code: Select all

[motioneye]
        path = /home/ben/motioneye
        valid users = ben
        read only = No
        guest ok = Yes
The password entered for

Code: Select all

smbpasswd -a ben
on my PC matches the password entered on the config page on MotionPie.

Any ideas?

Re: Surveillance camera based on BuildRoot and Motion

Posted: Wed Dec 31, 2014 2:20 pm
by Boothy
Apologies another newbie question here

To tidy up my port forwarding on router
Is there a simple way to change the default port setting (80) ? Should I be changing in motioneye settings.py ? or motionpie config settings.

Many Thanks again for a brilliant app\program

Boothy

Re: Surveillance camera based on BuildRoot and Motion

Posted: Wed Dec 31, 2014 2:32 pm
by ccrisan
Either use writeimage.sh with -p option (from a Linux box) or edit /programs/motioneye/settings.py and change the PORT to whatever you need.
Boothy wrote:Apologies another newbie question here

To tidy up my port forwarding on router
Is there a simple way to change the default port setting (80) ? Should I be changing in motioneye settings.py ? or motionpie config settings.

Many Thanks again for a brilliant app\program

Boothy

Re: Surveillance camera based on BuildRoot and Motion

Posted: Wed Dec 31, 2014 2:38 pm
by Boothy
Thanks

Re: Surveillance camera based on BuildRoot and Motion

Posted: Thu Jan 01, 2015 4:18 pm
by shh200
Hi,

Have only {"prompt": true, "error": "unauthorized"} text on firefox when trying to watch live feed on full screen window, whats wrong?
IE gives prompt do you want open or save frame.json from (ipaddress)

BTW Thaks for great job!