1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12:
13:
14:
15: 16: 17: 18: 19:
20:
21: #ifndef __DEV_ADC_M367_H__
22: #define __DEV_ADC_M367_H__
23:
24: #define DEV_ADC_UNITNM (2)
25: #define DEV_ADC_UNIT0 (0)
26: #define DEV_ADC_UNIT1 (1)
27:
28: #define ADC_CH_NUM (4)
29:
30: 31: 32:
33: #define ADA_BASE (0x40050000UL)
34: #define ADB_BASE (0x40051000UL)
35:
36: #define ADxCLK (0x00)
37:
38:
39: #define ADxMOD0 (0x04)
40: #define ADxMOD1 (0x08)
41: #define ADxMOD2 (0x0C)
42: #define ADxMOD3 (0x10)
43: #define ADxMOD4 (0x14)
44: #define ADxMOD5 (0x18)
45: #define ADxMOD6 (0x1C)
46:
47:
48: #define ADxCMPCR0 (0x24)
49: #define ADxCMPCR1 (0x28)
50:
51:
52: #define ADxCMP0 (0x2C)
53: #define ADxCMP1 (0x30)
54:
55:
56: #define ADxREG00 (0x34)
57: #define ADxREG01 (0x38)
58: #define ADxREG02 (0x3C)
59: #define ADxREG03 (0x40)
60: #define ADxREG04 (0x44)
61: #define ADxREG05 (0x48)
62: #define ADxREG06 (0x4C)
63: #define ADxREG07 (0x50)
64:
65:
66: #define ADxMOD0_ADS (1<<0)
67: #define ADxMOD1_DACON (1<<7)
68:
69:
70: #define ADMD_CHFIX_SINGLE 0x00
71: #define ADMD_CHSCAN_SINGLE 0x01
72:
73: 74: 75:
76: #define INTNO_INTADA 43
77: #define INTNO_INTADB 47
78:
79: #endif