= 2009-02-01 = * [備忘] 舊的 sarge repository 會留在 http://archive.debian.org/debian/dists/sarge/ * [參考] http://lists.debian.org/debian-user/2008/11/msg02570.html == BUGFIX: jfbterm (5) == * (續 [wiki:jazz/08-11-15 08-11-15@GMT-6 BUGFIX: jfbterm (1)]) * (續 [wiki:jazz/08-11-16 08-11-16@GMT-6 BUGFIX: jfbterm (2)]) * (續 [wiki:jazz/08-11-17 08-11-17@GMT-6 BUGFIX: jfbterm (3)]) * (續 [wiki:jazz/09-01-14 09-01-14@GMT+8 BUGFIX: jfbterm (4)]) {{{ #!C #include #include #include #include // include frame buffer header files #include int main(void) { int fbfd = 0 ; // frame buffer file description /* Get device independent unchangeable information about a frame buffer * device and a specific video mode by FBIOGET_FSCREENINFO ioctl. */ struct fb_fix_screeninfo finfo; fbfd = open( "/dev/fb0" , O_RDWR ); if ( !fbfd ) { printf( "Error: cannot open framebuffer device.\n" ); exit(1); } printf("The framebuffer device was opened successfully.\n"); /* Get fixed screen information */ if ( ioctl ( fbfd , FBIOGET_FSCREENINFO , &finfo ) ) { printf("Error reading fixed screen information.\n"); exit(2); } else { printf("Succesfully Read the Fixed Screen Information\n"); } printf("fb_fix_screeninfo.smem_len = %d\n", finfo.smem_len); printf("fb_fix_screeninfo.mmio_len = %d\n", finfo.mmio_len); } }}}