|
From: Jochen R. <jo...@pa...> - 2003-06-11 11:12:43
|
OK, next installment:
Based on my testing with fbset and fbi the frame buffer now
supports the following modes:
640x480-60 8/16/32bpp
800x600-60 16bpp
1024x768-60 8/16bpp
I added some modes to /etc/fb.modes, for instance this 32bpp
mode here:
mode "640x480-60"
# D: 25.175 MHz, H: 31.469 kHz, V: 59.94 Hz
geometry 640 480 640 480 8
timings 39722 48 16 33 10 96 2
endmode
mode "640x480-60-32"
# D: 25.175 MHz, H: 31.469 kHz, V: 59.94 Hz
geometry 640 480 640 480 32
timings 39722 48 16 33 10 96 2
endmode
To change modes at the console, run fbset -a 640x480-60-32 . If this
does not work, then please email me the driver debug messages from
/var/log/messages. If possible, please change the #if 0 in line 1511
and 1515 of s3trio.c to #if 1 so I can see the register settings.
I had to patch fbi to get it to properly display in true color modes:
diff -urN -x config* -x Makefile* fbi-1.23/main.c fbi-1.23-j1/main.c
--- fbi-1.23/main.c Mon Feb 4 04:34:09 2002
+++ fbi-1.23-j1/main.c Wed Jun 11 03:45:24 2003
@@ -366,10 +366,16 @@
case 15:
case 16:
for (out = 0; out < owidth; out++) {
+ unsigned short s;
in = (out << 16) >> shift;
- ptr2[out] = lut_red[buffer[in*3]] |
+ s = lut_red[buffer[in*3]] |
lut_green[buffer[in*3+1]] |
lut_blue[buffer[in*3+2]];
+#if 0
+ ptr2[out] = (s>>8)|(s<<8);
+#endif
+ ptr[2*out+0] = s;
+ ptr[2*out+1] = s>>8;
}
ptr2 += owidth;
return (char*)ptr2;
@@ -385,9 +391,14 @@
case 32:
for (out = 0; out < owidth; out++) {
in = (out << 16) >> shift;
+#if 0
ptr4[out] = lut_red[buffer[in*3]] |
lut_green[buffer[in*3+1]] |
lut_blue[buffer[in*3+2]];
+#endif
+ ptr[4*out+2] = buffer[3*in+0];
+ ptr[4*out+1] = buffer[3*in+1];
+ ptr[4*out+0] = buffer[3*in+2];
}
ptr4 += owidth;
return (char*)ptr4;
The X server seems to have a similar endianness problem. I am
investigating that at the moment.
When running X, make sure you set up the XFConfig-4 properly, see
linux/Documentation/fb/framebuffer.txt for instructions.
Patch is here:
http://networkstation.sourceforge.net/patch-2.4.19-ns1000-20030610.gz
Regards,
Jochen
|