Thanks for joining me!
Good company in a journey makes the way seem shorter. — Izaak Walton
For the Embedded Systems project, I am making a type of security system that plays a Maltese radio station when the button is pressed.
https://www.gadgetdaily.xyz/raspberry-pi-motion-detection/ for the motion detection code to be used in this project
https://roderickvella.wordpress.com/2016/09/11/maltese-online-radio-raspberry-pi/ For the radio module
For this project, a flask server was used to display the pictures captured, in case the motion detection code has been triggered. For that, the following resources are needed:
- html files: one for the login and the other is for the display
- open server, to activate the html
Various templates were created for the html files, for the website to be in order. The server script contains a piece of code that reads files (in this case, images) (https://stackoverflow.com/questions/28207761/where-does-flask-look-for-image-files and https://stackoverflow.com/questions/20646822/how-to-serve-static-files-in-flask were mainly used).
The image files were being called from the static folder located in the same folder as the motion detection code and the server script.
Biggest problem was with the lighting, as different lighting counts as pixel change, so the code can activate with the slightest difference in light. Be sure to activate the code when there is no visible light change around.