LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 07-10-2009, 06:38 AM   #1
mostafa
LQ Newbie
 
Registered: Oct 2008
Posts: 6

Rep: Reputation: 0
allegro on embedded linux


Hello all,
I am created a embedded linux and i have installed driver of my grapgic card that is base on linux framebuffer (sisfb). the node /dev/fb0 is exists and The driver work well with other programs such as DirectFB but when i want to run an allegro sample the message is "can not find any graphics driver". I have compiled allegro with framebuffer enabled configuration and i have choosed GFX_FBCON at gfx_init.
For example,I have write this program:

//------------------------------------------------------
#include <stdio.h>
#include <allegro.h>
int main(int argc,char* argv[])
{
//-------------initial allegro------------------
if (allegro_init() != 0)
{
printf("can not initialize allegro.\r\n");
exit(0);
}

set_color_depth(16);

if (set_gfx_mode(GFX_AUTODETECT, 1024, 768, 0, 0) != 0)
{
printf("%s\n",allegro_error);
exit(0);
}
allegro_exit();

return 0;
}
END_OF_MAIN()
//-------------------------


and when i compile and run it this message is appeared:

"Unable to find a suitable graphics driver"

in addition when i want to run setup or gfxinfo programs of allegro this message is also appeared.

The log file of allegro is as follow:

al-unix INFO: Assumed libc encoding is unknown.
al-unix INFO: Assumed libc encoding is unknown.
al-main INFO: Allegro initialised (instance 1)
al-gfx INFO: Called set_gfx_mode(1178738720, 1024, 768, 0, 0).
al-gfx INFO: First call, remembering console state.
al-gfx ERROR: Failed setting graphic driver 1178738720.
al-gfx INFO: Called set_gfx_mode(1396786757, 320, 200, 0, 0).
al-gfx INFO: Trying to set a safe graphics mode.
al-gfx WARNING: The system driver was unable to get a safe mode, I'll try with the specified parameters...
al-gfx INFO: Autodetecting graphic driver.
al-gfx ERROR: Failed setting graphic driver 0.
al-gfx ERROR: Bad bad, not even GFX_SAFE works?
al-gfx INFO: Closing, restoring original console state.
al-gfx INFO: Graphic mode closed.
al-gfx INFO: Called set_gfx_mode(-1, 0, 0, 0, 0).
al-gfx INFO: Closing, restoring original console state.
al-gfx INFO: Graphic mode close
d.


I don't know what to do?
Please help me.
thank a lot.

Last edited by mostafa; 07-12-2009 at 07:55 AM.
 
  


Reply

Tags
framebuffer


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
SDL or Allegro for casual game development under Linux? rylan76 Linux - Games 3 02-17-2009 07:41 AM
Xpert in 8-16 bit microcontroller embedded system now inclining toward embedded linux priyadarshan Linux - Embedded & Single-board computer 2 02-12-2009 04:28 AM
allegro alfont 2.0.6 fails to compile in Arch linux Sussch Linux - Software 0 02-11-2008 02:17 PM
LXer: Embedded Linux as Dependable for Developers as RTOSes, says Embedded Market For LXer Syndicated Linux News 0 01-23-2008 11:40 AM


All times are GMT -5. The time now is 02:59 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration