h0tm
Posts: 1
Joined: Wed Jul 17, 2019 7:02 pm
Location: Lebanon

How to run this code

Wed Jul 17, 2019 7:13 pm

I am new with python and raspberry pi.
I am facing the problem when compiling this code.
It always gives me that the import files are missing and i don t know how to solve it.
I would so much appreciate if someone helps me to run this code on raspberry pi,
Github Link :
https://github.com/Billwilliams1952/PiCameraApp

Andyroo
Posts: 4226
Joined: Sat Jun 16, 2018 12:49 am
Location: Lincs U.K.

Re: How to run this code

Wed Jul 17, 2019 7:47 pm

Welcome to the forum.

Python programs are normally made up of modules that add functions to the language and are not always included in the operating system install.

To bring them on to you machine you use a program called pip (or pip3 for Python 3).

A basic intro can be found https://www.w3schools.com/python/python_pip.asp

Identifying what you need can be a bit hit and miss as there did not seem to be a list on GITHUB so you may have to go through the errors, identify the names and then load them :shock:
Need Pi spray - these things are breeding in my house...

ghp
Posts: 1402
Joined: Wed Jun 12, 2013 12:41 pm
Location: Stuttgart Germany
Contact: Website

Re: How to run this code

Wed Jul 17, 2019 8:19 pm

In the github readme file, there is a chapter "Installation", which covers basic installation. In 'API Reference', there is a list of dependencies. picamera, RPI.GPIO should be available on a Pi. For PIL, Pillow, there is a remark "The Pillow fork of the Python Image Library. One issue is with PIL ImageTk under Python 3.x. It was not installed on my RPI. If you have similar PIL Import Errors use: sudo apt-get install python3-pil.imagetk."

It would help the get a printout on which exact errors you get when running the software.

Andyroo
Posts: 4226
Joined: Sat Jun 16, 2018 12:49 am
Location: Lincs U.K.

Re: How to run this code

Wed Jul 17, 2019 8:23 pm

:oops:

Does anyone want to buy a set of glasses?
Need Pi spray - these things are breeding in my house...

Return to “Python”