Leastrio
Rotate scenic app on RPI 5" Touch Display 2
Hi everyone, ive been trying to get my scenic app working on a rpi4 w/ a rpi 5” touch display 2 however I cant get it working how I would like. The issue comes from how the touch display 2 by default is a portrait screen, so if I run the app as it is it displays in a rotation I do not want, I want to be able to use the app and screen in a landscape orientation. I don’t necessarily need to flip everything on the screen its fine if just the app is rotated. From what I understand I need the following in my config:
opts: [
rotate: (3 * :math.pi()) / 2,
pin: {0, 0},
translate: {0, 0}
],
However that doesn’t work the app just never appears on the display.
When I try and do:
opts: [
rotate: (3 * :math.pi()) / 2,
pin: {0, 0},
translate: {500, 500}
],
I can see the app in the correct orientation and it does look to be about 500 down and 500 to the right (considering the 1280 x 720 resolution) so to me it looks like I should just set the translation to 0, 0. But like I said above the app just disappears. I am using scenic & scenic_driver_local v0.12.0-rc.0 (if thats important) because I have to use cairo-fb as drm doesnt work.
Most Liked
Leastrio
Ahhh yup that revealed the issue! I had blindly updated the scenic stuff to the 0.12 rc and didnt realize I had to change some of my code. Unfortunately I am fighting a battle with nixos and getting scenic_driver_local to compile for the rpi4 might take a while. I got it to compile scenic locally and it showed the issue locally but now I just gotta get it to work for the rpi4
Popular in Questions
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #elixirconf-us
- #advent-of-code
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #hex









