主题 : DirectFB 程序运行出错!No supported modes found in /etc/fb.modes and current mode not supported! 复制链接 | 浏览器收藏 | 打印
级别: 新手上路
UID: 52907
精华: 0
发帖: 7
金钱: 35 两
威望: 7 点
综合积分: 14 分
注册时间: 2011-07-27
最后登录: 2018-02-08
楼主  发表于: 2012-10-11 16:18

 DirectFB 程序运行出错!No supported modes found in /etc/fb.modes and current mode not supported!

本人使用的是mini2440,内核版本为:
[root@FriendlyARM bin]# uname -a                                                
Linux FriendlyARM 2.6.32.2-FriendlyARM #1 Tue Oct 9 17:37:20 CST 2012 armv4tl un

这两天一直在移植DirectFB, 程序编译都成功了,但最后在板子上运行tool里面的程序 dfbinfo 总是出错,运行如下:
[root@FriendlyARM bin]# ./arm-dfbinfo

   ~~~~~~~~~~~~~~~~~~~~~~~~~~| DirectFB 1.6.2 |~~~~~~~~~~~~~~~~~~~~~~~~~~
        (c) 2001-2012  The world wide DirectFB Open Source Community
        (c) 2000-2004  Convergence (integrated media) GmbH
      ----------------------------------------------------------------

(*) DirectFB/Core: Single Application Core. (2012-10-11 05:41) [ DEBUG ][ TRACE ]
(*) Direct/Memcpy: Using armasm_memcpy()
(*) Direct/Thread: Started 'Fusion Dispatch' (-1) [MESSAGING OTHER/OTHER 0/0] <8388608>...
(*) Direct/Thread: Started 'VT Switcher' (-1) [CRITICAL OTHER/OTHER 0/0] <8388608>...
(*) Direct/Thread: Started 'VT Flusher' (-1) [DEFAULT OTHER/OTHER 0/0] <8388608>...
(*) DirectFB/FBDev: Found 's3c2410fb' (ID 0) with frame buffer at 0x338c0000, 150k (MMIO 0x00000000, 0k)
(*) DirectFB/Graphics: Generic Software Rasterizer 0.7 (directfb.org)
(!) DirectFB/FBDev: No supported modes found in /etc/fb.modes and current mode not supported!
(-) [  729: -STACK- ]
sh: nm: not found
  #0  0x40df73c4 in ?? () from /opt/FriendlyARM/dfb/lib/directfb-1.6-0/systems/libdirectfb_fbdev.so [0x40df0000]
  #1  0x40df7d3c in ?? () from /opt/FriendlyARM/dfb/lib/directfb-1.6-0/systems/libdirectfb_fbdev.so [0x40df0000]
  #2  0x400fe78c in dfb_layer_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #3  0x400bb168 in dfb_core_part_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #4  0x400b74a0 in dfb_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #5  0x40061074 in DirectFB::ICore_Real::Initialize() () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #6  0x4005c6dc in CoreDFB_Initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #7  0x400b7ef8 in dfb_core_arena_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #8  0x400af8a0 in dfb_core_create () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
sh: nm: not found
  #9  0x0000886c in DirectFBCreate () from ./arm-dfbinfo [0x8000]
  #10 0x00008980 in ?? () from ./arm-dfbinfo [0x8000]

(!) DirectFB/FBDev: Current mode's pixelformat: rgba 5/11, 6/5, 5/0, 0/0 (16bit)
(-) [  729: -STACK- ]
  #0  0x40df73c4 in ?? () from /opt/FriendlyARM/dfb/lib/directfb-1.6-0/systems/libdirectfb_fbdev.so [0x40df0000]
  #1  0x40df7d3c in ?? () from /opt/FriendlyARM/dfb/lib/directfb-1.6-0/systems/libdirectfb_fbdev.so [0x40df0000]
  #2  0x400fe78c in dfb_layer_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #3  0x400bb168 in dfb_core_part_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #4  0x400b74a0 in dfb_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #5  0x40061074 in DirectFB::ICore_Real::Initialize() () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #6  0x4005c6dc in CoreDFB_Initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #7  0x400b7ef8 in dfb_core_arena_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #8  0x400af8a0 in dfb_core_create () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #9  0x0000886c in DirectFBCreate () from ./arm-dfbinfo [0x8000]
  #10 0x00008980 in ?? () from ./arm-dfbinfo [0x8000]

(!) DirectFB/Core/layers: Failed to initialize layer 0!
    --> A general initialization error occured
(-) [  729: -STACK- ]
  #0  0x400fe78c in dfb_layer_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #1  0x400bb168 in dfb_core_part_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #2  0x400b74a0 in dfb_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #3  0x40061074 in DirectFB::ICore_Real::Initialize() () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #4  0x4005c6dc in CoreDFB_Initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #5  0x400b7ef8 in dfb_core_arena_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #6  0x400af8a0 in dfb_core_create () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #7  0x0000886c in DirectFBCreate () from ./arm-dfbinfo [0x8000]
  #8  0x00008980 in ?? () from ./arm-dfbinfo [0x8000]

(!) DirectFB/Core: Could not initialize 'layer_core' core!
    --> A general initialization error occured
(-) [  729: -STACK- ]
  #0  0x400bb168 in dfb_core_part_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #1  0x400b74a0 in dfb_core_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #2  0x40061074 in DirectFB::ICore_Real::Initialize() () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #3  0x4005c6dc in CoreDFB_Initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #4  0x400b7ef8 in dfb_core_arena_initialize () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #5  0x400af8a0 in dfb_core_create () from /opt/FriendlyARM/dfb/lib/libdirectfb-1.6.so.0 [0x40025000]
  #6  0x0000886c in DirectFBCreate () from ./arm-dfbinfo [0x8000]
  #7  0x00008980 in ?? () from ./arm-dfbinfo [0x8000]

(!) [Fusion Dispatch 441.621] (  731) *** Assertion [(buf) != NULL] failed *** [fusion.c:2856 in event_dispatcher_loop()]
(-) [  731: -STACK- 'Fusion Dispatch']
(#) DirectFBError [DirectFBCreate() failed]: A general initialization error occured
[root@FriendlyARM bin]#





用的屏幕是3.5寸的:
[root@FriendlyARM bin]# fbset

mode "240x320-100"
        # D: 10.000 MHz, H: 33.003 kHz, V: 100.010 Hz
        geometry 240 320 240 320 16
        timings 100000 20 37 2 6 6 2
        accel false
        rgba 5/11,6/5,5/0,0/0
endmode




directfbrc文件如下,放在/目录下的:
[root@FriendlyARM bin]# cat /etc/directfbrc
system=fbdev                                                                  
fbdev=/dev/fb0                                                                
wm=default                                                                      
mode=320x240                                                                  
depth=16                                                                        
pixelformat=RGB16



在网上查找这个问题查了好久都不知道如何解决,曾看到有位在ubuntu上碰到这个错误,说是frame buffer未启动,可是我这板子上的frame buffer难道没启动?

哪位大牛帮我看看阿,不胜感谢哈~!!!!




*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
1楼  发表于: 2012-10-11 17:50

 Re:DirectFB 程序运行出错!No supported modes found in /etc/fb.modes and current mode not support ..

把/etc/directfbrc里的mode=320x240改成240x320或者干脆去掉呢?
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
级别: 新手上路
UID: 52907
精华: 0
发帖: 7
金钱: 35 两
威望: 7 点
综合积分: 14 分
注册时间: 2011-07-27
最后登录: 2018-02-08
2楼  发表于: 2012-10-11 22:01
修改了,以及后来把mode这行给删了,甚至把这个配置文件删了,出错信息还是一样,我甚至怀疑我这个配置文件是不是都没读进去,我做了个实验室,将system=fbdev 修改为fbdev = x11 ,将   /dev/fb0 改成/dev/xx ,出错打印信息还是一模一样,难道这配置文件压根就不读在我这?
级别: 新手上路
UID: 52907
精华: 0
发帖: 7
金钱: 35 两
威望: 7 点
综合积分: 14 分
注册时间: 2011-07-27
最后登录: 2018-02-08
3楼  发表于: 2012-10-11 22:02

 回 1楼(kasim) 的帖子

恩?
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
4楼  发表于: 2012-10-12 21:36
引用第2楼chengyang59于2012-10-11 22:01发表的  :
修改了,以及后来把mode这行给删了,甚至把这个配置文件删了,出错信息还是一样,我甚至怀疑我这个配置文件是不是都没读进去,我做了个实验室,将system=fbdev 修改为fbdev = x11 ,将   /dev/fb0 改成/dev/xx ,出错打印信息还是一模一样,难道这配置文件压根就不读在我这?

也许可以试试用"strace"工具追踪一下执行的过程,看看到底是什么导致的这个出错信息。
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."