Author Topic: Kernel for a320 with ILI9338 LCD- helps with "blueish" display  (Read 15093 times)

darth_llamah (OP)

  • Posts: 311
Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« on: November 08, 2011, 12:40:15 pm »
Hi :)
I'm a happy owner of Dingoo a320 unfortunately with ILI9338 lcd.
For your pleasure:
Modified OpenDingux kernel with not-so-blue image
This is first try so don't expect perfect colours and please do tell me if in your opinion image needs to be tweaked.
For now blue colour "brightness" is set to 75% of original value, red and green are original.

Note: this kernel will work only for ILI9338 LCD

Installation- copy zImage_ili9338 to SD card and rename it to zImage

Download:
http://dl.dropbox.com/u/14106051/dingux/zImage_ili9338
MD5: 85DBC47CBB91F3E2919E8E02B71452E5

EDIT:
And some pics
Original kernel:


Modified kernel:



EDIT:
A "60% of blue" version, nothing more changed:
http://dl.dropbox.com/u/14106051/dingux/zImage_ili9338_60
MD5: 3A3B090E8ACE47C8B207BC32D260AC2E
and updated kernel patch:
http://dl.dropbox.com/u/14106051/dingux/lcd60.patch
« Last Edit: January 26, 2012, 12:38:33 pm by darth_llamah »

K-77

  • * Former Staff
  • Posts: 343
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #1 on: November 09, 2011, 08:12:18 pm »
I have this screen too and i haven't see nothing blueish. These unpredictable chinese people and they screens...  :o

Pozdrawiam Karol  :P

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #2 on: November 11, 2011, 02:23:53 pm »
Maybe your lcd is from a different batch (not-that-cheaply-manufctured) than mine.
Try to play Castlevania: Harmony Of Dissonance (GBA) and compare image with real GBA or gba emulator (vba, vba-m etc)....

ps. r?wnież pozdrawiam ;)
« Last Edit: November 11, 2011, 02:27:03 pm by darth_llamah »

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #3 on: December 23, 2011, 12:51:49 pm »
I don't know I've tried in Picodrive and I really can't tell the difference but it's because most of the Genesis games already look ok on Dingux. I've tried to take pictures but It's quite hard. I think there's an improvement, but I'm not sure (maybe it's a placebo effect)
I'm trying to install the gba emulator because this console have the worse games regarding colours but the OD emulator doesn't work for me. I could tell the difference inmediately only looking at those games running in OD. You only have to run mario kart (in native the sky is all washed in glaring white) to see if this is working or not.

I guess I cannot use this zimage into Sience Kernel, right? That way I could use fba, snes and such.
« Last Edit: December 23, 2011, 12:56:40 pm by CREATICA »

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #4 on: December 23, 2011, 02:05:16 pm »
I don't know I've tried in Picodrive and I really can't tell the difference but it's because most of the Genesis games already look ok on Dingux. I've tried to take pictures but It's quite hard. I think there's an improvement, but I'm not sure (maybe it's a placebo effect)
I'm trying to install the gba emulator because this console have the worse games regarding colours but the OD emulator doesn't work for me.
You need gba bios in gbsp folder, in gmenu2x shortcut use Browser
Quote
I could tell the difference inmediately only looking at those games running in OD. You only have to run mario kart (in native the sky is all washed in glaring white) to see if this is working or not.
Also Castlevania series are hard to play, especially Aria Of Sorrow.

Quote
I guess I cannot use this zimage into Sience Kernel, right? That way I could use fba, snes and such.
I didn't touch "legacy" Dingux kernel however here is the patch for ILI9338 driver (rev1)

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #5 on: December 23, 2011, 04:22:39 pm »
I figured it out. I've tested another bios on a former version of gpsp and it works.

Here you have the link to the comparative shots with your fix (I don't know the reason why this forum isn't capable to show them) and Ili8993.

http://imageshack.us/f/715/mario1600x1200.jpg/

http://imageshack.us/f/577/specialctforces1600x120.jpg/

I think it works, but having more testers would be completely recommendable.

Castlevania Aria of Sorrow stills looks like crap. The problem is black colour doesn't exist in that game.

You've mentioned you reduced the blue channel to 75%, now try to reduce it to 50% and let's see what happens. It's all about contrast.

Anyway, great job.
« Last Edit: December 23, 2011, 04:26:08 pm by CREATICA »

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #6 on: December 23, 2011, 04:31:47 pm »
You've mentioned you reduced the blue channel to 75%, now try to reduce it to 50% and let's see what happens. It's all about contrast.
I've already tried that, with 50% of blue image is too green-ish.
I'll make a 60% version (most likey after x-mas ;) )

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #7 on: December 23, 2011, 04:38:02 pm »
You've mentioned you reduced the blue channel to 75%, now try to reduce it to 50% and let's see what happens. It's all about contrast.
I've already tried that, with 50% of blue image is too green-ish.
I'll make a 60% version (most likey after x-mas ;) )


Ok man. I think you're on the right track, anyway. If the 60% blue channel update doesn't work I think the obvious trick is playing with the others channels. I'll be waiting for the new version.
Happy Xmas!

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #8 on: December 23, 2011, 04:53:06 pm »
Ok man. I think you're on the right track, anyway. If the 60% blue channel update doesn't work I think the obvious trick is playing with the others channels.
There is no need to change green and red, they both are displayed correctly. Only blue is way too bright.
I can try to use other gamma curve (4 are available) but only if current solution is not enough

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #9 on: December 23, 2011, 05:10:04 pm »


And I don't know, I'm looking at genesis games and now they look gorgeous. Maybe the only error is on the GBA, the emulator or something.
I'll try the Dingux patch. I guess I only have to rename the file to zImage, right?
Trial and error, that's the process.

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #10 on: December 23, 2011, 05:13:28 pm »
I'll try the Dingux patch. I guess I only have to rename the file to zImage, right?
Trial and error, that's the process.
Patch is to be applied on kernel sources (for kernel makers), it is not a zImage/rootfs

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #11 on: December 23, 2011, 05:18:50 pm »
I'll try the Dingux patch. I guess I only have to rename the file to zImage, right?
Trial and error, that's the process.
Patch is to be applied on kernel sources (for kernel makers), it is not a zImage/rootfs

Ok thanks for the aclaration (I'm not a developer myself so it's better I don't touch that). Thanks.

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #12 on: December 27, 2011, 11:45:36 am »
Could you make a version of this fix for Sience Kernel? There's a lot of blue too. Just asking.

lorderok

  • Guest
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #13 on: January 16, 2012, 05:34:34 pm »
If you don't mind me asking, how do you change the color balance like this? Is there a program, or coding language you need to know?
« Last Edit: January 16, 2012, 05:37:33 pm by lorderok »

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #14 on: January 16, 2012, 08:09:20 pm »
Could you make a version of this fix for Sience Kernel? There's a lot of blue too. Just asking.
It would be better to ask Sience, necessary patch is provided (I didn't play with legacy Dingux at all)

If you don't mind me asking, how do you change the color balance like this? Is there a program, or coding language you need to know?
First of all- get the manual and read it.
In this case I've added custom "color lookup table" setting to LCD driver. This table is responsible for converting 5bit input color value to 6bit output required by LCD panel. Hardware default is "input *2" but this doesn't work good for blue ;) , current version has max blue set to 44 (was 63). Also all the work is done in hardware so this doesn't affect performance
TBH I'm not skilled in any coding language, just c and c++ (very) basics, I just know how to mess with code ;)

pcercuei

  • Posts: 1675
    • My devblog
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #15 on: January 16, 2012, 08:12:47 pm »
You could make it configurable through /sys, so that it can be changed at runtime.

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #16 on: January 16, 2012, 08:15:29 pm »
You could make it configurable through /sys, so that it can be changed at runtime.
I'm not sure, it's in hardware init (unless there is a way to reset lcd from within the system)

lorderok

  • Guest
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #17 on: January 19, 2012, 10:37:06 pm »
It would be really nice to see a 60% one for the Legacy kernel, though. 

CREATICA

  • Posts: 195
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #18 on: January 20, 2012, 09:25:28 pm »
It would be really nice to see a 60% one for the Legacy kernel, though.

I agree. It would be terrific.

darth_llamah (OP)

  • Posts: 311
Re: Kernel for a320 with ILI9338 LCD- helps with "blueish" display
« Reply #19 on: January 21, 2012, 09:19:49 pm »
I'll try to make "60%" kernels for both OD and Dingux but I can't promise (work, work, work...)