User`s manual

ENDAT-K1001 USERS MANUAL
UNICORN COMPUTER CORP.
26
2-7.LCD Brightness Control
1) Inverter Brightness Digital level select:
LCDBK1: Inverter Header (2x3 with 2.0mm)
Pin No. Function Pin No. Function
1
VBL
2
VBL
3
INV-BRT
4
BKL ON/OFF
5
GND
6
GND
2) Brightness Control port address:
This is alternate function with VBIOS (VESA) to offering an easy way to control
the LCD backlight ON and OFF as need. Please follow the instructions of
below for more detail in operation.
Sample code for brightness control (using Turbo C/C++ 3.0):
#define input_port 0xf40
outportb(0x2e,0x87); // Unlock register
outportb(0x2e,0x01); // Unlock register
outportb(0x2e,0x55); // Unlock register
outportb(0x2e,0x55); // Unlock register
outportb(0x2e,0x07); // Set Logic Device number pointer
outportb(0x2f,0x07); // Set Logic Device number
outportb(0x2e,0x25); // Set Multi-Function Pin for GPIO Set1
outportb(0x2f,0x0F); // GP10~17 (Default 01)
outportb(0x2e,0x2A);
outportb(0x2f,0x0F); // Set Bit 1: GPIO / 0:PCIRST
outportb(0x2e,0xC0); // Set Enable Simple GPIO
outportb(0x2f,0x0F); // GP10~17 (Default 01)
outportb(0x2e,0xB0); // Set GPIO Pin Polarity
outportb(0x2f,0x07); // GP10~17(Default 00) 1:Inverting/0: Non-Inverting
outportb(0x2e,0xC8); // Set GPIO Input Mode / Output Mode
outportb(0x2f,0x07); // 0: Inputer ; 1: Output
outportb(0xf40,0xnn); // Set active register is IO Base Address 0F40 “default 30”
// ; 0f40 = 30h Out +0V / 0f40 = 38h Out +5V
// ; 0f40 = 39h Out +2.54V / f40 = 3Ah Out +1.73V
// ; 0f40 = 3bh Out +1.29V / f40 = 3ch Out +1.04V
// ; 0f40 = 3dh Out +0.86V / f40 = 3eh Out +0.74V
// ; f40 = 3fh Out +0.65V
Register configuration:
Bit No 7 6 5 4 3 2 1 0
Map
NA NA NA NA P13 P12 P11 P10