Posts

Showing posts from March, 2024

Python 3/PyQt5 + picamera2 on Raspberry Pi, list available cameras.

Image
In previous exercises of Python/PyQt5 GUI to control Raspberry Pi Camera using picamera2 lib , with camera_controls and White Balance , camera is assigned manually in Python code or command line argument. In this exercise (picam2_qt5_global.py), number of cameras attached and cameras info are retrieved by calling Picamera2.global_camera_info(), then run picam2_qt5_.py base on user selection. Code: picam2_qt5_global.py """ Python 3/PyQt5 + picamera2 List available cameras. Run picam2_qt5_.py base on user selection. """ from PyQt5.QtWidgets import (QComboBox, QMainWindow, QApplication, QWidget, QVBoxLayout, QLabel, QLineEdit, QPushButton) from PyQt5.QtCore import QProcess import sys from picamera2 import Picamera2 cameras_info = Picamera2.global_camera_info() num_of_cam = len(cameras_info) if num_of_cam == 0: print("No camera attached! Exit") exit(1) print("number of cameras: ...

Take screenshots of Wayland desktops, works on Raspberry Pi OS (bookworm)

Image
grim is a command-line utility to take screenshots of Wayland desktops. It work on Raspberry Pi OS (bookworm). grim