#144895 - Noda - Fri Nov 09, 2007 12:02 am
hmm I don't get why it's not working well, as according to Gbatek it should work...
here is my code to change master brightness:
I use 3D on both screen using the REG_CAPTURE method.
using setBrightness(-31) for example has absolutely no effect, whereas the screen should have become black.. :(
Any idea?
Last edited by Noda on Fri Nov 09, 2007 2:11 am; edited 1 time in total
here is my code to change master brightness:
Code: |
// adjust screens brightness
void setBrightness(s8 bright) { // mode: fade to black/white u16 mode = 1 << 14; if (bright < 0) { mode = 2 << 14; bright = -bright; } if (bright > 31) bright = 31; // adjust main screen brightness *(volatile u16 *)(BRIGHTNESS) = bright + mode; // adjust sub screen brightness *(volatile u16 *)(SUB_BRIGHTNESS) = bright + mode; } |
I use 3D on both screen using the REG_CAPTURE method.
using setBrightness(-31) for example has absolutely no effect, whereas the screen should have become black.. :(
Any idea?
Last edited by Noda on Fri Nov 09, 2007 2:11 am; edited 1 time in total