The fbdev_flush mechanism works great for targeting a single display. I would like to take advantage of the hardware stack on the RPi 4 and use both HDMI outputs. Currently when I write to /dev/fb0 both of my displays show the program output. I went looking to see if there was a secondary frame buffer (/dev/fb1) but there is not.
In doing research on this topic it seems that DRM is being used on the RPi4, and that to choose a display for my app, I will need to target the display through DRM (/sys/class/drm/card0 , card1 etc.)
Has anyone written a port for displaying selectively on the RPi4 yet? If so, could you help me get started? There doesn’t seem to be a lot of resources on how to use DRM to choose the output.
Please feel free to correct my assumptions. I’m still learning this framework.
/dev/fb0 on the Raspberry Pi 4 appears to simply emulate a framebuffer for compatibility. I think you would have to write a new driver that operates using the DRM kernel APIs and not the
I found a site that appears to have a tutorial on how to get started with the DRM APIs. They do appear significantly more cumbersome to use than
Perhaps there is another way to get
fb1 to show up without needing to use the DRM APIs. This forum thread looks relevant.
@embeddedt Thank you very much for your reply.
I was able to get 2 frame buffers to be available in /dev/ with the following configuation in /boot/config.txt
I think the key was commenting out:
Hopefully this will help someone else in the future.