After finishing wiring all the components in the new enclosure (see updated post below) I decided to make some changes to the software. First step was to load it in a proper IDE with code inspection. And what a shocker that was. It was full off incorrect indentations (which are very important with python), unnecessary semi colons and some minor stuff like incorrect commenting. So after fixing as many errors and warnings as I could it was time to strip out the upload to Tumblr and gif generation code. Luckily parameters where named in a way that makes sense. The code is pretty easy to read and removing the unwanted bits was pretty straight forward. The end result is a nice clean program with no unwanted functionality. Hopefully this proves to be a more stable program too but time will tell. The modified program is attached at the bottom of this post. My next experiment was saving the photos onto USB drive. Although it's pretty straight forward saving to USB drive I discovered that removing the USB without corrupting it is very tricky. Therefor I think I prefer to store the photos locally on the microSD card and copy to another device after the event. That should reduce the risk of corrupting all the photos by not properly removing the USB device. Also a power failure might corrupt the USB device. Update: There are two little tweaks to be made to the pi OS. 1. I get a low voltage warning now and then. This can be disabled by adding the line: 'avoid_warnings=1' to /boot/config.txt 2. Disable the screensaver. go to /etc/lightdm/lightdm.conf file and add in the [SeatDefaults] section the following command: xserver-command=X -s 0 -dpms ![]()
7 Comments
Daniel Kürsten
23/4/2017 08:28:58 am
Hi George,
Reply
George
23/4/2017 08:50:50 am
Hello and thank you. As part of the zipped project file you will find a file names 'config.py. In that file you will have to declare your monitor resolution for your Photo Booth. I assume you already configured the display driver for your Pi in /boot/config.txt.
Reply
Daniel Kürsten
23/4/2017 09:03:23 am
Hi George,
George
23/4/2017 09:19:49 am
It wouldn't hurt checking the display driver. You should find something in /boot/config.txt along the lines of:
Reply
Daniel Kürsten
23/4/2017 09:32:42 am
Thank you very much for your advice. I already changed the camera resolution to the maximum of version 2 which I am using. I will try to change the config.txt 👍
Daniel Kürsten
25/4/2017 07:07:02 am
I tried serveral display settings, but it is always the same. The preview has a smaller view as the taken picture.
Daniel Kürsten
26/4/2017 07:52:43 am
I found out what's the problem.
Reply
Your comment will be posted after it is approved.
Leave a Reply. |
AuthorGeorge Timmermans, Research Toolmaker, Software Engineer and Tinkerer Archives
April 2023
Categories |