Word:
#define Word_Reg (*(volatile unsigned long *)0x12345678)
Half-Word:
#define HW_Reg (*(volatile unsigned int *)0x876543219)
Char:
#define C_Reg (*(volatile unsigned char *)0xabcd1234)
例如....
就寫成下面這樣
#define SRCPND (*(volatile unsigned long *)0x4A000000)
#define IISFIFO (*(volatile unsigned int *)0x55000010)
#define rFUNC_ADDR_REG (*(volatile unsigned char *)0x52000140)
0 comments:
Post a Comment