Raspberry Pi (Part 5)

Gingerbread House

Gingerbread House

$ sudo apt-get update
$ sudo apt-get dist-upgrade

$ python -m venv my-env
$ source my-env/bin/activate

$ pip install --upgrade pip setuptools wheel
$ pip install opencv-contrib-python

$ python
>>> import cv2
>>> print(cv2.__version__)

$ pip install --upgrade luma.oled
$ sudo raspi-config

$ curl -o holiday.mp4 https://download-video.akamaized.net/...

$ vi holiday.py
$ python holiday.py

Raspberry Pi Imager

I selected the Micro SD card

I clicked YES to include WIFI and logon credentials

I clicked YES

SD card was moved from Macbook to Raspberry Pi

I plugged in the Raspberry Pi and used ping to access

I connected to the Raspberry Pi using secure shell (ssh)

I executed $ sudo apt-get update

I executed $ sudo apt-get dist-upgrade

I created a python environment, activated the environment and ran pip install
$ python -m venv my-env
$ source my-env/bin/activate
$ pip install --upgrade pip setuptools wheel

I ran $ pip install opencv-contrib-python
I ran import cv2 to ensure that OpenCV was properly installed

I ran $ pip install --upgrade luma.oled
library for the mini oled display

I ran $ sudo raspi-config
I selected the Interface Options menu option

I selected the I2C menu option

I selected Yes

I selected Ok

I selected Finish

I created and ran holiday.py
Notice that the cv.imshow("Img", frame) line is commented out

holiday.py

I wired up two displays