Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1186 | savelij | 1 | ifndef __regpadaukinc ; avoid multiple inclusion |
2 | __regpadaukinc equ 1 |
||
3 | |||
4 | save |
||
5 | listing off ; no listing over this file |
||
6 | |||
7 | ;**************************************************************************** |
||
8 | ;* * |
||
9 | ;* AS 1.42 - File REGPADAUK.INC * |
||
10 | ;* * |
||
11 | ;* Sinn : contains SFR and Bit Definitionen for Padauk MCUs * |
||
12 | ;* * |
||
13 | ;**************************************************************************** |
||
14 | |||
15 | ;---------------------------------------------------------------------------- |
||
16 | ; Helper Macros |
||
17 | |||
18 | _bfield macro {INTLABEL},reg,start,count |
||
19 | __LABEL__ equ ((1<<(count+start))-1)-((1<<start)-1) |
||
20 | endm |
||
21 | |||
22 | ;---------------------------------------------------------------------------- |
||
23 | ; include proper CPU-specific register definitions |
||
24 | |||
25 | switch MOMCPUNAME |
||
26 | case "PMC150","PMS150" |
||
27 | include "pdk/pmx150.inc" |
||
28 | |||
29 | case "PMC131","PMS131","PMS130" |
||
30 | include "pdk/pmx130.inc" |
||
31 | |||
32 | case "PMS132","PMS132B" |
||
33 | include "pdk/pms132.inc" |
||
34 | |||
35 | case "PMS133","PMS134" |
||
36 | include "pdk/pms133.inc" |
||
37 | |||
38 | case "PMS152" |
||
39 | include "pdk/pms152.inc" |
||
40 | |||
41 | case "PFS154","PMS154B","PMS154C" |
||
42 | include "pdk/pxs154.inc" |
||
43 | |||
44 | case "PFS173" |
||
45 | include "pdk/pfs173.inc" |
||
46 | |||
47 | case "PMS232","PMC232" |
||
48 | include "pdk/pmx232.inc" |
||
49 | |||
50 | case "PMS234","PMC234" |
||
51 | include "pdk/pmx234.inc" |
||
52 | |||
53 | case "PMC251" |
||
54 | include "pdk/pmc251.inc" |
||
55 | |||
56 | case "PMC271","PMS271" |
||
57 | include "pdk/pmx271.inc" |
||
58 | |||
59 | case "PMC884","MCS11" |
||
60 | include "pdk/pmc884.inc" |
||
61 | |||
62 | case "DF69" |
||
63 | include "pdk/df69.inc" |
||
64 | |||
65 | elsecase |
||
66 | error "wrong processor type set: only PMC150, PMS150, PMC131, PMS131, PMS130, PMS132, PMS132B," |
||
67 | error "PMS133, PMS134, PMS152, PFS154, PMS154B, PMS154C, PFS173, PMS232, PMC232, PMS234," |
||
68 | fatal "PMC234, PMC251, PMC271, PMS271, PMC884, MCS11, DF69 allowed." |
||
69 | endcase |
||
70 | |||
71 | if MOMPASS=1 |
||
72 | message "Padauk SFR Definitions (C) 2020 Alfred Arnold" |
||
73 | endif |
||
74 | |||
75 | ;---------------------------------------------------------------------------- |
||
76 | ; Common Stuff in CPU Core |
||
77 | |||
78 | flag sfr 0x00 ; ACC Status Flag Register |
||
79 | OV bit io(flag).3 ; Overflow |
||
80 | AC bit io(flag).3 ; Auxiliary Carry |
||
81 | C bit io(flag).1 ; Carry |
||
82 | CF bit C |
||
83 | Z bit io(flag).0 ; Zero |
||
84 | |||
85 | sp sfr 0x02 ; Stack Pointer |
||
86 | |||
87 | ifndef __numcpus |
||
88 | __numcpus equ 1 |
||
89 | endif |
||
90 | |||
91 | if __numcpus>1 |
||
92 | RESET0_vect label 0x0000 ; Reset FPP0 |
||
93 | RESET1_vect label 0x0001 ; Reset FPP1 |
||
94 | elseif |
||
95 | RESET_VECT label 0x0000 ; Reset |
||
96 | endif |
||
97 | if __numcpus>7 |
||
98 | RESET2_vect label 0x0002 ; Reset FPP2 |
||
99 | RESET3_vect label 0x0003 ; Reset FPP3 |
||
100 | RESET4_vect label 0x0004 ; Reset FPP4 |
||
101 | RESET5_vect label 0x0005 ; Reset FPP5 |
||
102 | RESET6_vect label 0x0006 ; Reset FPP6 |
||
103 | RESET7_vect label 0x0007 ; Reset FPP7 |
||
104 | endif |
||
105 | INT_vect label 0x0010 ; Interrupt |
||
106 | |||
107 | if __numcpus>1 |
||
108 | fppen sfr 0x01 ; FPP Unit Enable Register |
||
109 | gdio sfr 0x07 ; General Data for I/O |
||
110 | endif |
||
111 | |||
112 | if __numcpus>7 |
||
113 | fppres sfr 0x3f ; FPPA Reset Register |
||
114 | endif |
||
115 | |||
116 | ;---------------------------------------------------------------------------- |
||
117 | |||
118 | restore ; allow listing again |
||
119 | |||
120 | endif ; __regpadaukinc |