#Motion Microservices Motion sensor, WebSocket app, Video stream services for raspberry Pi
##HOW TO START:
1. Set up Pi Camera Official page
2. Set up PIR sensor Official page
3. Install Flask-Sockets Official page
4. Meet with Flask python framework Tutorial help
5. Load and compile ffmpeg :
sudo mkdir ffmpeg
sudo chown pi:users ffmpeg
git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg
cd ffmpeg
./configure
make
sudo make install
6. Set up YouTube live stream channel Video help
7. Change /motion/video/sensor.py
file with credentials from youtube account :
channel = "UCx3Qtn--------HUqQ"
streamKey = "zvt2-xxxx-xxxx-xxxx"
##HOW TO RUN :
There is 2 micro services that also daemons with start / stop / restart options :
1. PIR sensor /motion/sensor/app.py
2. Flask web app with video stream support /motion/video/app.py
####To start / stop full service :
cd motion/
sh start.sh
sh stop.sh