Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Errata]: Sense Hat Emulator does not work under Bookworm #1

Open
bjepson opened this issue Oct 9, 2023 · 0 comments
Open

[Errata]: Sense Hat Emulator does not work under Bookworm #1

bjepson opened this issue Oct 9, 2023 · 0 comments
Assignees

Comments

@bjepson
Copy link
Contributor

bjepson commented Oct 9, 2023

Contact Details

[email protected]

What format of the book has this error? You may select more than one option.

Print, PDF, ePub

What language of the book has this error?

English (EN)

Page Number or Section

Chapter 7

Detailed description

At the time of publication, the Sense Hat Emulator did not work under the newest, Debian Bookworm-based version of Raspberry Pi OS. Scratch 3 did not support Raspberry Pi 5 at the time of publication, either.

However, you can install a version of the Sense Hat Emulator, along with a version of Thonny that can talk to the emulator, with these commands:

sudo apt install libgirepository1.0-dev gcc libcairo2-dev pkg-config python3-dev gir1.2-gtk-4.0 libopenblas-dev
python3 -m venv ~/sense-emu-env
source ~/sense-emu-env/bin/activate
pip3 install pycairo PyGObject sense-emu thonny

Whenever you want to run the Sense Hat Emulator, you'll need to open a Terminal, run . ~/sense-emu-env/bin/activate, then run the Sense Hat Emulator with sense_emu_gui. If you want to use Thonny with the Sense Hat Emulator, you need to run thonny from the terminal after you run the activate command.

You may also find that some Sense Hat Emulator sensors, such as humidity, do not work under 64-bit Bookworm-based Raspberry Pi OS, but will work under the 32-bit version.

A future update to Raspberry Pi OS will eliminate the need for this workaround.

You can more information on virtual environments and why they are required at https://rptl.io/venv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants