Frame buffer relation to console

Hello,

I have build LVGL sample project and run it on Raspberry Pi. It runs fine when I run it from terminal tty1 and it looks crappy when I run it from graphic desktop.

I would like my application always be shown on tty1, no matter in which console it was started from. How to achieve that?

I found my applications uses frame buffer /dev/fb0 device in order to show it’s controls. Is frame buffer somehow related to terminal console?

My understanding is that framebuffers and TTYs are separate objects on Linux which happen to draw to the same screen. Your application is being drawn on the framebuffer, not a TTY, meaning it will not be possible for it to “share” with the desktop.

If you want it to look proper on a desktop I would suggest using SDL instead.