27
votes
How to start Motion in daemon mode on RPi running Raspbian Jessie
To enable motion to run as a daemon on startup do the following:
Edit /etc/default/motion
and change start_motion_daemon=no to start_motion_daemon=yes
Next enable motion by entering the following ...
17
votes
Accepted
Motion-daemon: /var/log/motion/motion.log permission denied
Gotcha! For testing I started motion with sudo motion -b. Therefore, /var/log/motion/motion.log was written with root:root. After removing /var/log/motion and reboot, the motion-daemon was up and ...
11
votes
RasPi Camera Board and Motion
to load the model after each reboot, use this setting
sudo nano /etc/modules
enter bcm2835-v4l2
exist and save the fle
sudo reboot
7
votes
Where does 'Motion' web cam interface store image files?
The default directory is /var/lib/motion
which is set in the /etc/motion/motion.conf file
using the target_dir variable
7
votes
Motion-daemon: /var/log/motion/motion.log permission denied
There are three ways to fix the problem. All are really the same, just from different angles. That is to make sure that the user starting motion has the access permission to write into the /var/log/...
6
votes
Accepted
"Failed to open video device /dev/video0 no such file or directory" with normal working usb camera in motion
Problem Solved!!
What I did was:
1) Removed Motion from Raspberry Pi using
sudo apt-get --purge remove motion
2) Disabled Raspberry Pi Camera in raspi-config and rebooted the Pi
3) Installed ...
6
votes
Protect my motion webcam stream with a password (motion.conf)
To setup a username and password with motion, you need to edit motion configuration file.
Steps
Open terminal
Type sudo nano /etc/motion/motion/conf
Add in a new line stream_auth_method 1
Add in a ...
6
votes
Unable to open video device
Try this:
sudo modprobe bcm2835-v4l2
if works then put above line in /etc/rc.local to run this at boot time.
5
votes
Motion filming can't get on real speed
Check out this thread:
https://www.raspberrypi.org/forums/viewtopic.php?t=75240
With the updated binary you can get 15FPS on the live stream. If you set output_pictures ON, you can collect up to 15 ...
4
votes
Can't access motion server
Using motion V4.0 this helpful parameters are:
# change the following options in your motion.conf from on to off
stream_localhost off
stream_port 8081
webcontrol_localhost off
webcontrol_port 8080
4
votes
Accepted
Unable to open video device
A short Google search for Device doesn't support VIDIOC_G_STD gave these two links:
Raspberry Pi • View topic - Motion errors for RPi camera
Unable to open video device · Issue #147 · ccrisan/...
4
votes
4-5 (multiple) USB Cameras on one raspberry
If they are USB cameras... you can preview the stream on demand using any software you like.. as long as you say which USB device you are using.
You could even use a desktop application to take ...
4
votes
how to delete motion images raspberry pi 3
Welcome to stack exchange!
Use the sudo and chmod commands. to give the everyone(the default user) access to the folder, simply change into the directory(folder) the folder is in using the command ...
4
votes
Accepted
Is there a way to reload motion.conf without restarting the motion service?
In addition to the answer from @p4ulmac you get the pid with ps -e | grep motion. If you like to control your services with systemd then there is no need to handle with the pid. You can simply:
rpi ~$...
4
votes
Accepted
How to Detect Which Side of an Object is Facing Up
You need to use 3 axes accelerometer to sense which side of your cube is facing up. Accelerometers sense the gravity g and the acceleration due to motion.
Eg. when you roll dice, one of the axis will ...
4
votes
Motion security
It's simple. There is some TLS feature for the web interface and also for the stream port.
Generate your certificate files:
apt-get install openssl
openssl genrsa -out /etc/motion/motion.key 4096
...
3
votes
Accepted
Where does 'Motion' web cam interface store image files?
The default target directory should be your actual working directory.
E.g. if you startet motion in your terminal from /home/pi, the saved images should be located there.
If your want to change this ...
3
votes
How to start Motion in daemon mode on RPi running Raspbian Jessie
Confirmed for stretch (v9) as well.
you can also use
$ ps -ef | grep motion
to see if motion is running
3
votes
Motion configuration: on_event_start not working
If you try to use on_event_start in motion to do something with GPIO, you will discover that user motion has no access to /dev/mem. So a Python script that wants to activate a relay through a GPIO pin ...
3
votes
Motion filming can't get on real speed
You have to go into the .conf file and change stream_maxrate to the desired framerate.
3
votes
Protect my motion webcam stream with a password (motion.conf)
netcam_userpass is to connect motion to a webcam that is protected by a username and password. This can happen for instance, if you are running a webcam program on a cellphone and have set a username/...
3
votes
Recording video using Motion regardless of motion detection
I found the answer. As stated here, we have the command 'output_all'; which makes the exact thing that I wanted - allowing you to create continuous film:
output_all
Type: Boolean
Range / ...
3
votes
unable to open video device and grey screen
I tried the answer mentioned and it didn't quite work for me. I did find that appending
# load camera driver
bcm2835-v4l2
to /etc/modules worked like a charm. Obviously the commented out part is ...
3
votes
Accepted
Raspberry PI 3 as NVR
The Pi3 has more CPU power than the A20 and bit more than the BananaPi. But in order to monitor 8 different cameras, it may not be enough, even if it is only for simple motion detection.
...
3
votes
Motion 4.0 Server working but not streaming
Fixed it.
I had the streaming port and the HTTP control on the same port.
I changed the control port to 8082 and then I could see the live stream on 8081
3
votes
Motion-daemon: /var/log/motion/motion.log permission denied
I have tested all answers but no solution. After I reboot the raspberry pi, problem still there. Follow the procedure below to fix the problem.
Create another directory:
sudo mkdir /home/log/...
3
votes
Is there a way to reload motion.conf without restarting the motion service?
Based on the following page, Motion Guide - Getting It Running: Signals (sent with e.g. kill command)
It would appear that you can send the following command;
kill -s SIGHUP pid
where pid is the ...
3
votes
Accepted
Does HC-SR501 detect motion of objects (non-living things)
You have not given a link to the sensor so this is an assumption.
Assuming the HC-SR501 is an infra-red sensor it detects a change in infra-red, i.e. change in temperature.
If the objects you want ...
3
votes
motion not encrypted even with https
The motion doesn't encrypt video streams. I mean, it hasn't an online video/FFmpeg/RTSP encryption feature As I read a long time ago, it's not related to https.
Motion sends video streams over a ...
2
votes
Running script in motion
This configuration works for me:
on_motion_detected /usr/bin/python /home/myuser/Scripts/MyScript.py
Of course, the script must have the correct permissions to be executed by the motion process. ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
motion × 183camera × 47
raspbian × 22
raspicam × 22
webcam × 22
streaming-video × 15
python × 14
picamera × 13
pi-3 × 11
sensor × 11
video × 8
pi-2 × 6
permissions × 6
gpio × 5
networking × 5
usb × 5
pi-4 × 5
security × 5
pi-zero × 4
ffmpeg × 4
mmal × 4
wifi × 3
ssh × 3
pi-zero-w × 3
cron × 3