Quantcast
Viewing all articles
Browse latest Browse all 1264

Python • Re: How to install picamera2

PiCamera2 manual: "As of mid-September 2022, Picamera2 is pre-installed in all Raspberry Pi OS images"
If you create the venv with system packages it will then have the system wide (already installed) version of picamera2

Code:

mkdir my_projectcd my_projectpython -m venv --system-site-packages envsource env/bin/activate
If I do that on my Pi5 running Bookworm 64-bit, then a python script in the venv works fine. It has this import:

Code:

from picamera2 import Picamera2, Preview

Statistics: Posted by neilgl — Mon Mar 18, 2024 10:10 am



Viewing all articles
Browse latest Browse all 1264

Trending Articles