This is the example kiosk application for followings,
git clone https://github.com/nerves-web-kiosk/kiosk_example.git
cd kiosk_example
export MIX_TARGET=rpi4
mix deps.get
mix firmware
mix burn
Then,
- Insert SD to your rpi4
- Connect micro HDMI cable to your rpi4 and display
- Boot it!!
We will see Phoenix LiveDashboard on your display!!!
We can change the URL to use KioskExample.change_url("http://example.com")
on IEx console over SSH.
And there are some functions in KioskExample
module which lead browser to famous URL. Enjoy!!
To change the screen orientation, use the method described below.
- Create
rootfs_overlay/etc/xdg/weston/weston.ini
- Edit it like following
[output]
name=DSI-1
[email protected]
transform=rotate-270
The transform key can be rotate-(90|180|270)
.
The original source is available here, but it's not very human-readable. For a more readable version, see this man page.