1
2
3
4
5
6
7
8#ifndef mcf5307_h
9#define mcf5307_h
10
11
12
13
14#define INT_RAM_SIZE 4096
15
16
17#define SYPCR_SWTAVAL 0x02
18#define SYPCR_SWTA 0x04
19#define SYPCR_SWT(x) ((x&0x3)<<3)
20#define SYPCR_SWP 0x20
21#define SYPCR_SWRI 0x40
22#define SYPCR_SWE 0x80
23
24
25#define CSMR_V 0x01
26#define CSMR_UD 0x02
27#define CSMR_UC 0x04
28#define CSMR_SD 0x08
29#define CSMR_SC 0x10
30#define CSMR_CI 0x20
31#define CSMR_AM 0x40
32#define CSMR_WP 0x100
33
34
35#define DACR_PM_CONTINUOUS 0x04
36#define DACR_IP_PRECHG_ALL 0x08
37#define DACR_PORT_SZ_32 0
38#define DACR_PORT_SZ_8 (1<<4)
39#define DACR_PORT_SZ_16 (2<<4)
40#define DACR_IMRS_INIT_CMD (1<<6)
41#define DACR_CMD_PIN(x) ((x&7)<<8)
42#define DACR_CASL(x) ((x&3)<<12)
43#define DACR_RE (1<<15)
44
45
46#define CSCR_BSTW 0x08
47#define CSCR_BSTR 0x10
48#define CSCR_BEM 0x20
49#define CSCR_PS(x) ((x&0x3)<<6)
50#define CSCR_AA 0x100
51#define CSCR_WS ((x&0xf)<<10)
52
53
54#define MCFSIM_ICR_AUTOVEC 0x80
55#define MCFSIM_ICR_LEVEL0 0x00
56#define MCFSIM_ICR_LEVEL1 0x04
57#define MCFSIM_ICR_LEVEL2 0x08
58#define MCFSIM_ICR_LEVEL3 0x0c
59#define MCFSIM_ICR_LEVEL4 0x10
60#define MCFSIM_ICR_LEVEL5 0x14
61#define MCFSIM_ICR_LEVEL6 0x18
62#define MCFSIM_ICR_LEVEL7 0x1c
63
64#define MCFSIM_ICR_PRI0 0x00
65#define MCFSIM_ICR_PRI1 0x01
66#define MCFSIM_ICR_PRI2 0x02
67#define MCFSIM_ICR_PRI3 0x03
68
69#endif
70
71