linux Framebuffer 调试
来源:互联网 发布:图片恶搞软件 编辑:程序博客网 时间:2024/05/22 02:18
将当期屏幕黑掉
# echo 1 > /sys/class/graphics/fb0/blank
以下转自:http://www.armadeus.com/wiki/index.php?title=FrameBuffer
On this page you will find usefull informations to have a working Linux Framebuffer on your board.
Contents
[hide]- 1 Introduction
- 2 Kernel configuration
- 3 Userland
- 4 Tips
- 5 Other usefull ESC sequences
- 6 Links
Introduction
Linux Framebuffer is the lowest level (standardized) API for userspace programs to access video capabilities of the system you're running on. It allows you to directly "draw" your graphics in the video memory. Some higher level librairies can be put on top of the Framebuffer for more portability: SDL, Qt/Embedded, GTK, DirectFB, etc...
Kernel configuration
Instructions to configure Linux kernel were moved to Talk:FrameBuffer and are only given as references or if you want to change the default LCD.
Userland
- Framebuffer device can be accessed with /dev/fb0.
- You can activate some tools from the Buildroot's menuconfig:
$ make menuconfig
Package Selection for the target ... Graphic libraries and applications (graphic/text) ---> ... [*] fbgrab [*] fbtest [*] fbv ... ---> Graphic libraries and applications (graphic/text) ---> fbset/fbv/fbgrab
- For example to grab a snapshot of the framebuffer:
# fbgrab /tmp/snapshot.png
- For example to display an image using standard image file formats PNG, GIF...:
# fbv myimage.png
Tips
- To stop blinking cursor:
# echo 0 > /sys/class/graphics/fbcon/cursor_blink
also possible at boot time (with 3.x recent kernels):
BIOS> setenv extrabootargs vt.global_cursor_default=0
- To make it blinking again:
# echo 1 > /sys/class/graphics/fbcon/cursor_blink
- To grab a screenshot of a running Framebuffer application, use FBGrab
- To enter in Framebuffer sleep mode:
# echo 1 > /sys/class/graphics/fb0/blank
- To leave Framebuffer sleep power mode:
# echo 0 > /sys/class/graphics/fb0/blank
- To set "sleep mode"/screensaver entering time (where X is a time in minute; 0 = never):
# echo -e '\033[9;X]' > /dev/tty1 (from serial console)
or
# echo -e '\033[9;X]' (from framebuffer console)
or to set it at each boot, use /etc/inittab:
tty1::sysinit:echo -e '\033[9;X]'
Other usefull ESC sequences
- To (definitly) hide cursor:
# echo -e '\033[?17;0;0c' > /dev/tty1 (from serial console)
or
# echo -e '\033[?17;0;0c' (from framebuffer console)
- inverse screen on:
# echo -e '\033[?5h' > /dev/tty1
- inverse screen off:
# echo -e '\033[?5l' > /dev/tty1
- linux Framebuffer 调试
- linux framebuffer
- Linux Framebuffer
- linux FrameBuffer
- LINUX framebuffer
- Linux framebuffer
- LINUX framebuffer
- Linux Framebuffer
- linux FrameBuffer
- Linux Framebuffer
- linux framebuffer
- linux framebuffer
- LINUX framebuffer
- LCD驱动调试以及Framebuffer
- FrameBuffer的原理 linux开启FrameBuffer
- FrameBuffer Linux下FrameBuffer直接写屏
- linux framebuffer光标消除
- linux下开启FrameBuffer
- Linux内核学习2:内核模块的开发
- httpClient采集到的数据乱码问题完整解决
- Unity 3D需要注意的程序基础
- 文本文件与二进制文件区别
- sring mybatis 注解应用
- linux Framebuffer 调试
- OpenCV学习之Condensation算法
- c程序组织
- ExtJS5之Clear Data Builder
- 别再浪费时间了!如何从细节上真正节省用户的时间
- String.indexOf方法
- 【C/C++】计时函数比较
- Java流程控制
- HDU1042 N! 高精度:计算n!精确值