Voice Molly monitor (kiosk)
A monitor attached to a Voice Molly device can show her portrait all the time. The device does not set this up by itself: follow this runbook on the device.
Status: the pinned certificate flag was checked in a Chromium-based browser and the GPU flags on a Pi 5 without a display. A full run on a real monitor has not been done yet, so treat the compositor step as a starting point. How closely the mouth keeps up with the speaker has not been judged on real hardware either.
1. Give the kiosk user access to the GPU
The user who runs Chromium needs the render and video groups (without them Chromium falls back to software drawing, which a Pi cannot keep up with):
sudo usermod -aG render,video <kiosk-user>Log in again for the groups to apply.
2. Find the certificate’s pin
The kiosk opens the same HTTPS page as everyone else, on the loopback address. The certificate is self-signed, so tell Chromium to trust this one key and nothing else:
SPKI=$(sudo openssl x509 -in /var/lib/quazzar-voice/tls/cert.pem -pubkey -noout \
| openssl pkey -pubin -outform der | openssl dgst -sha256 -binary | base64)
echo "$SPKI"The device keeps this certificate for ten years. If you delete it, the device makes a new one and the pin must be taken again.
Why not a plain-HTTP port for the monitor
The form on the monitor must be able to sign in, and it does so through the same login API, with a session cookie that only travels over HTTPS. A plain-HTTP listener could only show the portrait, or would have to expose sign-in without TLS. The device therefore has one page and one address, and the monitor is not a special case. --ignore-certificate-errors-spki-list accepts only this key, unlike --ignore-certificate-errors, which accepts anything.
3. Start Chromium
chromium --kiosk --noerrdialogs --disable-infobars --no-first-run \
--user-data-dir="$HOME/.config/molly-kiosk" \
--ignore-certificate-errors-spki-list="$SPKI" \
https://127.0.0.1/face--user-data-dir is required: Chromium ignores the pin without it. If the device has no permission to use port 443 the page is on port 8443: use https://127.0.0.1:8443/face (journalctl -u quazzar-voice | grep "local web UI" prints the address).
Run it under a small Wayland compositor such as cage (cage -- chromium …), started when the kiosk user logs in on the console.
4. Check the GPU without a monitor
chromium --headless=new --ozone-platform=headless --use-gl=angle --use-angle=gles-egl \
--user-data-dir=/tmp/molly-gpu --ignore-certificate-errors-spki-list="$SPKI" \
--screenshot=/tmp/face.png --window-size=1280,720 https://127.0.0.1/face--virtual-time-budget will not finish on this page because its event stream stays open; give Chromium a real wait or use the remote debugging port if the screenshot comes out too early.
Measured on a Pi 5 (V3D GPU): 1280×720 runs at 52 frames per second and 1920×1080 at 21–23, limited by filling pixels. The page therefore draws at most about 1280×720 internal pixels on larger screens and stretches them, and lowers its quality further if the frame rate stays under 27.
What to expect
- With nobody speaking, the monitor shows a free form that changes each time it comes back.
- A recognised owner’s voice turns it into a face for the conversation. Guests and unknown voices keep the free form.
- To sign in on the monitor, hold the top-right corner for 5 seconds or say «Молли, открой настройки». The form has on-screen digits, so the PIN needs no keyboard. A recovery code has letters and does need one: keep a USB keyboard at hand for the day your voice is not recognised.
- The mouth follows Molly’s real speech, and her expression follows the answer. Both come over the page’s event stream, which also works with several pages open.
A session on the monitor ends 5 minutes after the last touch, mouse or key input, and the screen returns to the portrait by itself. The server enforces it, for sessions signed in from the loopback address the kiosk uses, and a page polling in the background does not count as input. Long jobs started from the monitor, such as an update or a benchmark, carry on after it ends. Sessions from phones and laptops keep their 30 minutes.