Work in progress.... 0xC000000 + [0, 100, 200, 300] + 0x0 Mask, 0:don't mask, 1: mask interrupt 0x4 Direction 0:input, 1: output 0x8 Output 0:output low, 1: output high 0xc Trigger Type 0:level, 1: edge 0x10 Edge Trigger 0:falling, 1: rising 0x14 Level Trigger 0:low, 1: high level detect 0x18 Sleep Mask 0:don't mask, 1: mask trigger in sleep mode 0x1c Sleep Out 0:low, 1: high in sleep mode 0x20 Batt Fault Output 0:low, 1: high in batt_fault 0x24 Interrupt Status 0:none, 1: detect 0x28 Alt Function 0:normal control 1:LED register control 0x2c Sleep Conf 0: disable gposlpout in normal mode, enable gposlpout in sleep mode 1: autosleep 0x30 Pin status RO 0:disabled 1: enabled >---------------( 0xC000000 )---------------< 0xC000000: ffff fc7f 0000 0000 0xC000010: 0000 0000 ffff 0000 0xC000020: 0000 0000 0000 000c 0xC000030: 0180 **h4150** 0c000000 | ffff fe7f 0000 0000 0c000010 | 0000 0000 ffff 0000 0c000020 | 0000 0000 0000 000c 0c000030 | 0180 **h4350** *** h4150 ** *** h4350 *** ,------------ || ,------------ 10 |,----------- || |,----------- 9 ||,---------- || ||,---------- 8 ||| ,-------- || ||| ,-------- 7 ||| |,------- || ||| |,------- 6 serial power 0000 0001 1000 0000 || 0000 0001 1000 0000 status || out ii i || i i dir >---------------( 0xC000100 )---------------< 0xC000100: ffff dfbf 1c00 0000 0xC000110: 0000 0000 ffff 0000 0xc000120: 0000 0000 0000 000c 0xc000130: 1c40 ** h4150 ** 0c000100 | fffd dfbd 1c05 0002 0c000110 | 0002 0000 ffff 0000 0c000120 | 0000 0000 0000 000c 0c000130 | 1c45 ** h4350 ** *** h4150 *** *** h4350 *** ,---------------- || ,---------------- (1<<12) | lcd power | ,-------------- || | ,-------------- (1<<11) | connect lcd | |,------------- || | |,------------- (1<<10) | lcd bl pwr | || ,-------- || | || ,-------- (1<< 6) | | || | ,--- || | || | ,--- (1<< 2) | | || | |,-- || | || | |,-- (1<< 1) | x | || | ||,- || | || | ||,- (1<< 0) | 0001 1100 0100 0000 || 0001 1100 0100 0101 | status || e | edge type || r | trig type 1 11 || 1 11 1 1 | out i i || i i i | dir || x | mask int pfw 0xC000100 1 0xfffd pfw 0xC000104 1 0xdfbd pfw 0xC000108 1 0x1c05 pfw 0xC00010c 1 0x0002 pfw 0xC000110 1 0x2 >---------------( 0xC000200 )---------------< 0x0c000200 : ffff ffff 4700 0000 0x0c000210 : 0000 0000 ffff 4000 0x0c000220 : 4000 0000 0003 000c 0x0c000230 : 4700 ** h4150 ** 0x0c000200 | ffff fff7 4700 0000 0x0c000210 | 0000 0000 ffff 4000 0x0c000220 | 4000 0000 003b 000c 0x0c000230 | 4703 ** h4350 ** *** h4150 ** *** h4350 *** ,------------------- || ,------------------- 15: bluetooth |,------------------ || |,------------------ 14: || ,---------------- || || ,---------------- 12: bluetooth || | ,-------------- || || | ,-------------- 11: 802.11b || | |,------------- || || | |,------------- 10: || | ||,------------ || || | ||,------------ 9: || | |||,----------- || || | |||,----------- 8: || | |||| || || | |||| ,------- 5: keyboard related || | |||| || || | |||| |,------ 4: keyboard related || | |||| || || | |||| || ,---- 3: keyboard related || | |||| ,-- || || | |||| || | ,-- 1: green led || | |||| |,- || || | |||| || | |,- 0: red led 0100 0111 0000 0000 || 0100 0111 0000 0011 | status 11 || 11 1 11 | alt func 1 || 1 | batt fault outp 1 || 1 | sleep outp 1 111 || 1 111 | output lvl i | dir pfw 0xC000204 1 0xfff7 pfw 0xC000228 1 0x003b >---------------( 0xC000300 )---------------< 0c000300 : ff03 ef03 0f02 00fc 0c000310 : 0080 0000 ff83 0100 0c000320 : 0100 0000 0000 000c 0c000330 : 1f06 **h4150** 0c000300 | ff7b ef7b 0e03 0084 0c000310 | 0080 0000 fffb 0100 0c000320 | 0100 0000 0000 000c 0c000330 | 1e07 **h4350** *** h4150 ** *** h4350 *** ,----------------- || ,----------------- 14 USB enable | ,--------------- || | ,--------------- 12 | | ,------------- || | | ,------------- 11 | | |,------------ || | | |,------------ 10 | | ||,----------- || | | ||,----------- 9 | | |||,---------- || | | |||,---------- 8 | | |||| ,-------- || | | |||| ,-------- 7 x | | |||| |,------- || | | |||| |,------- 6 | | |||| ||,------ || | | |||| ||,------ 5 | | |||| |||,----- || | | |||| |||,----- 4 | | |||| |||| ,--- || | | |||| |||| ,--- 3 | | |||| |||| |,-- || | | |||| |||| |,-- 2 x // record button? | | |||| |||| ||,- || | | |||| |||| ||,- 1 | | |||| |||| |||, || | | |||| |||| |||, 0 USB pullup 0001 1111 0000 0110 || 0001 1110 0000 0111 status 1 || 1 batt fault outp 1 || 1 sleep outp xxx xx || x Sleep Mask rfff ff || r f edge type eeee ee || e e trig type 1111 1 || 111 11 out i iiii ii || i i i dir xxxx xx || x x mask int pfw 0xC000300 1 0xff7b pfw 0xC000304 1 0xef7b pfw 0xC000308 1 0x0e03 pfw 0xC00030c 1 0x0084 pfw 0xC000318 1 0xfffb /////////////////////////////////////// \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< LED >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ ////////////////////////////////////// LED 0 Base 0x0c000700 LED 1 Base 0x0c000800 TimeBase 0x0 /* R/W 7 bits */ PeriodTime 0x4 /* R/W 12 bits */ DutyTime 0x8 /* R/W 12 bits */ AutoStopCount 0xc /* R/W 16 bits */ or ??? /* LEDCNTL : LED Control Reg */ #define LEDTBS (1<<0) /* LED time base set */ #define LEDEN (1<<4) /* LED ON/OFF 0:off, 1:on */ #define LEDSTP (1<<5) /* LED ON/OFF auto stop set 0:disable, 1:enable */ #define LEDMSK pfw 0x0c000700 1 0x00000000 pfw 0x0c000704 1 0x00000000 pfw 0x0c000708 1 0x00000000 pd 0x0c000700 16 pfw 0x0c000800 1 0x00000000 pfw 0x0c000804 1 0x00000000 pfw 0x0c000808 1 0x00000000 pd 0x0c000800 16 pfw 0x0c000700 1 0x00000016 // cycle length red pfw 0x0c000704 1 0x00000101 pfw 0x0c000708 1 0x00000081 // // how long led stays on ?? pfw 0x0c000800 1 0x00000016 // cycle length green 0x0000001a = short length (fast blink) 0x00000014 = long length (slow blink) pfw 0x0c000804 1 0x00000101 pfw 0x0c000808 1 0x00000081 // how long led stays on 0x000000ff = long lighton - short lightoff. 0x00000011 = long lightoff - short lighton. right amber blink (green+red blink) 0c000700 | 00000016 00000101 00000081 00000000 | ................ 0c000800 | 00000016 00000101 00000081 00000000 | ................ pfw 0x0c000700 1 0x00000016 pfw 0x0c000704 1 0x00000101 pfw 0x0c000708 1 0x00000081 pfw 0x0c000800 1 0x00000016 pfw 0x0c000804 1 0x00000101 pfw 0x0c000808 1 0x00000081 right amber solid (green+red solid) 0c000700 | 00000016 00000001 00000002 00000000 | ................ 0c000800 | 00000016 00000001 00000002 00000000 | ................ pfw 0x0c000700 1 0x00000016 pfw 0x0c000704 1 0x00000001 pfw 0x0c000708 1 0x00000002 pfw 0x0c000800 1 0x00000016 pfw 0x0c000804 1 0x00000001 pfw 0x0c000808 1 0x00000002