lvgl / lv_port_linux

LVGL configured to work with a standard Linux framebuffer
MIT License
208 stars 140 forks source link

Shell prompt in application gui #7

Closed blvckcrxw closed 3 years ago

blvckcrxw commented 3 years ago

Hello! First of all thank you for this demo application! It really helps to get a quick overview of lvgl. I've successfully managed to build and run this demo application. However I'm still facing the following issue. Shell prompt always appears in GUI. Even if I change buffer size so that the application match full-screen resolution of my display. It is still there and has active focus, so if one would type anything on connected keyboard the command would appear on the screen and break GUI. Is it possible to disable shell prompt so that user would have a full-screen experience with the application? May be this is just framebuffer restriction?

My setup is following: Board: udoo neo full. OS: Framebuffer yocto image. I have USE_FBDEV and USE_EVDEV enabled in lv_drv_conf.h I use LV_INDEV_TYPE_POINTER to use mouse in GUI (which works correctly for me).

Thank you in advance.

embeddedt commented 3 years ago

I think you will need to use a Linux sysfs command to temporarily disable the framebuffer console, as we currently assume the framebuffer is not being used by any other application (or kernel subsystem). Unfortunately I don't recall how to do it as I haven't needed to in a while.

Alternatively, if you capture all the stdin input and disable echoing it back to the terminal, you can probably achieve the same effect.

blvckcrxw commented 3 years ago

Thank you for the quick reply. I guess I will have to dig deeper into working with console and how to disable it, thanks.

blvckcrxw commented 3 years ago

For anyone who may face this issue in the future. I managed to disable shell prompt using system call ioctl as following: ioctl(fd, KDSETMODE, KD_GRAPHICS)