ports_def.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef _M68HC11_PORTS_DEF_H
00022 #define _M68HC11_PORTS_DEF_H
00023
00024
00025 #define M6811_S_BIT 0x80
00026 #define M6811_X_BIT 0x40
00027 #define M6811_H_BIT 0x20
00028 #define M6811_I_BIT 0x10
00029 #define M6811_N_BIT 0x08
00030 #define M6811_Z_BIT 0x04
00031 #define M6811_V_BIT 0x02
00032 #define M6811_C_BIT 0x01
00033
00034
00035
00036
00037
00038
00039
00040
00041 #define M6811_PORTA 0x00
00042 #define M6811__RES1 0x01
00043 #define M6811_PIOC 0x02
00044 #define M6811_PORTC 0x03
00045 #define M6811_PORTB 0x04
00046 #define M6811_PORTCL 0x05
00047 #define M6811__RES6 0x06
00048 #define M6811_DDRC 0x07
00049 #define M6811_PORTD 0x08
00050 #define M6811_DDRD 0x09
00051 #define M6811_PORTE 0x0A
00052 #define M6811_CFORC 0x0B
00053 #define M6811_OC1M 0x0C
00054 #define M6811_OC1D 0x0D
00055 #define M6811_TCTN 0x0E
00056 #define M6811_TCTN_H 0x0E
00057 #define M6811_TCTN_L 0x0F
00058 #define M6811_TIC1 0x10
00059 #define M6811_TIC1_H 0x10
00060 #define M6811_TIC1_L 0x11
00061 #define M6811_TIC2 0x12
00062 #define M6811_TIC2_H 0x12
00063 #define M6811_TIC2_L 0x13
00064 #define M6811_TIC3 0x14
00065 #define M6811_TIC3_H 0x14
00066 #define M6811_TIC3_L 0x15
00067 #define M6811_TOC1 0x16
00068 #define M6811_TOC1_H 0x16
00069 #define M6811_TOC1_L 0x17
00070 #define M6811_TOC2 0x18
00071 #define M6811_TOC2_H 0x18
00072 #define M6811_TOC2_L 0x19
00073 #define M6811_TOC3 0x1A
00074 #define M6811_TOC3_H 0x1A
00075 #define M6811_TOC3_L 0x1B
00076 #define M6811_TOC4 0x1C
00077 #define M6811_TOC4_H 0x1C
00078 #define M6811_TOC4_L 0x1D
00079 #define M6811_TOC5 0x1E
00080 #define M6811_TOC5_H 0x1E
00081 #define M6811_TOC5_L 0x1F
00082 #define M6811_TCTL1 0x20
00083 #define M6811_TCTL2 0x21
00084 #define M6811_TMSK1 0x22
00085 #define M6811_TFLG1 0x23
00086 #define M6811_TMSK2 0x24
00087 #define M6811_TFLG2 0x25
00088 #define M6811_PACTL 0x26
00089 #define M6811_PACNT 0x27
00090 #define M6811_SPCR 0x28
00091 #define M6811_SPSR 0x29
00092 #define M6811_SPDR 0x2A
00093 #define M6811_BAUD 0x2B
00094 #define M6811_SCCR1 0x2C
00095 #define M6811_SCCR2 0x2D
00096 #define M6811_SCSR 0x2E
00097 #define M6811_SCDR 0x2F
00098 #define M6811_ADCTL 0x30
00099 #define M6811_ADR1 0x31
00100 #define M6811_ADR2 0x32
00101 #define M6811_ADR3 0x33
00102 #define M6811_ADR4 0x34
00103 #define M6811__RES35 0x35
00104 #define M6811__RES36 0x36
00105 #define M6811__RES37 0x37
00106 #define M6811__RES38 0x38
00107 #define M6811_OPTION 0x39
00108 #define M6811_COPRST 0x3A
00109 #define M6811_PPROG 0x3B
00110 #define M6811_HPRIO 0x3C
00111 #define M6811_INIT 0x3D
00112 #define M6811_TEST1 0x3E
00113 #define M6811_CONFIG 0x3F
00114
00115
00116
00117 #define M6811_NOSEC 0x08
00118 #define M6811_NOCOP 0x04
00119 #define M6811_ROMON 0x02
00120 #define M6811_EEON 0x01
00121
00122
00123 #define M6811_BYTE 0x10
00124 #define M6811_ROW 0x08
00125 #define M6811_ERASE 0x04
00126 #define M6811_EELAT 0x02
00127 #define M6811_EEPGM 0x01
00128
00129
00130 #define M6811_STAF 0x80
00131 #define M6811_STAI 0x40
00132 #define M6811_CWOM 0x20
00133 #define M6811_HNDS 0x10
00134 #define M6811_OIN 0x08
00135 #define M6811_PLS 0x04
00136 #define M6811_EGA 0x02
00137 #define M6811_INVB 0x01
00138
00139
00140 #define M6811_R8 0x80
00141 #define M6811_T8 0x40
00142 #define M6811__SCCR1_5 0x20
00143 #define M6811_M 0x10
00144 #define M6811_WAKE 0x08
00145
00146
00147 #define M6811_TIE 0x80
00148 #define M6811_TCIE 0x40
00149 #define M6811_RIE 0x20
00150 #define M6811_ILIE 0x10
00151 #define M6811_TE 0x08
00152 #define M6811_RE 0x04
00153 #define M6811_RWU 0x02
00154 #define M6811_SBK 0x01
00155
00156
00157 #define M6811_TDRE 0x80
00158 #define M6811_TC 0x40
00159 #define M6811_RDRF 0x20
00160 #define M6811_IDLE 0x10
00161 #define M6811_OR 0x08
00162 #define M6811_NF 0x04
00163 #define M6811_FE 0x02
00164 #define M6811__SCSR_0 0x01
00165
00166
00167 #define M6811_TCLR 0x80
00168 #define M6811__BAUD_6 0x40
00169 #define M6811_SCP1 0x20
00170 #define M6811_SCP0 0x10
00171 #define M6811_RCKB 0x08
00172 #define M6811_SCR2 0x04
00173 #define M6811_SCR1 0x02
00174 #define M6811_SCR0 0x01
00175
00176 #define M6811_BAUD_DIV_1 (0)
00177 #define M6811_BAUD_DIV_3 (M6811_SCP0)
00178 #define M6811_BAUD_DIV_4 (M6811_SCP1)
00179 #define M6811_BAUD_DIV_13 (M6811_SCP1|M6811_SCP0)
00180
00181
00182 #define M6811_SPIE 0x80
00183 #define M6811_SPE 0x40
00184 #define M6811_DWOM 0x20
00185 #define M6811_MSTR 0x10
00186 #define M6811_CPOL 0x08
00187 #define M6811_CPHA 0x04
00188 #define M6811_SPR1 0x02
00189 #define M6811_SPR0 0x01
00190
00191
00192 #define M6811_SPIF 0x80
00193 #define M6811_WCOL 0x40
00194 #define M6811_MODF 0x20
00195
00196
00197 #define M6811_CCF 0x80
00198 #define M6811_SCAN 0x20
00199 #define M6811_MULT 0x10
00200 #define M6811_CD 0x08
00201 #define M6811_CC 0x04
00202 #define M6811_CB 0x02
00203 #define M6811_CA 0x01
00204
00205
00206 #define M6811_FOC1 0x80
00207 #define M6811_FOC2 0x40
00208 #define M6811_FOC3 0x20
00209 #define M6811_FOC4 0x10
00210 #define M6811_FOC5 0x08
00211
00212
00213 #define M6811_OC1M7 0x80
00214 #define M6811_OC1M6 0x40
00215 #define M6811_OC1M5 0x40
00216 #define M6811_OC1M4 0x40
00217 #define M6811_OC1M3 0x08
00218
00219
00220 #define M6811_OC1D7 0x80
00221 #define M6811_OC1D6 0x40
00222 #define M6811_OC1D5 0x20
00223 #define M6811_OC1D4 0x10
00224 #define M6811_OC1D3 0x08
00225
00226
00227 #define M6811_OM2 0x80
00228 #define M6811_OL2 0x40
00229 #define M6811_OM3 0x20
00230 #define M6811_OL3 0x10
00231 #define M6811_OM4 0x08
00232 #define M6811_OL4 0x04
00233 #define M6811_OM5 0x02
00234 #define M6811_OL5 0x01
00235
00236
00237 #define M6811_EDG1B 0x20
00238 #define M6811_EDG1A 0x10
00239 #define M6811_EDG2B 0x08
00240 #define M6811_EDG2A 0x04
00241 #define M6811_EDG3B 0x02
00242 #define M6811_EDG3A 0x01
00243
00244
00245 #define M6811_OC1I 0x80
00246 #define M6811_OC2I 0x40
00247 #define M6811_OC3I 0x20
00248 #define M6811_OC4I 0x10
00249 #define M6811_OC5I 0x08
00250 #define M6811_IC1I 0x04
00251 #define M6811_IC2I 0x02
00252 #define M6811_IC3I 0x01
00253
00254
00255 #define M6811_OC1F 0x80
00256 #define M6811_OC2F 0x40
00257 #define M6811_OC3F 0x20
00258 #define M6811_OC4F 0x10
00259 #define M6811_OC5F 0x08
00260 #define M6811_IC1F 0x04
00261 #define M6811_IC2F 0x02
00262 #define M6811_IC3F 0x01
00263
00264
00265 #define M6811_TOI 0x80
00266 #define M6811_RTII 0x40
00267 #define M6811_PAOVI 0x20
00268 #define M6811_PAII 0x10
00269 #define M6811_PR1 0x02
00270 #define M6811_PR0 0x01
00271 #define M6811_TPR_1 0x00
00272 #define M6811_TPR_4 0x01
00273 #define M6811_TPR_8 0x02
00274 #define M6811_TPR_16 0x03
00275
00276
00277 #define M6811_TOF 0x80
00278 #define M6811_RTIF 0x40
00279 #define M6811_PAOVF 0x20
00280 #define M6811_PAIF 0x10
00281
00282
00283 #define M6811_DDRA7 0x80
00284 #define M6811_PAEN 0x40
00285 #define M6811_PAMOD 0x20
00286 #define M6811_PEDGE 0x10
00287 #define M6811_RTR1 0x02
00288 #define M6811_RTR0 0x01
00289
00290
00291 #define M6811_ADPU 0x80
00292 #define M6811_CSEL 0x40
00293 #define M6811_IRQE 0x20
00294 #define M6811_DLY 0x10
00295 #define M6811_CME 0x08
00296 #define M6811_CR1 0x02
00297 #define M6811_CR0 0x01
00298
00299
00300 #define M6811_RBOOT 0x80
00301 #define M6811_SMOD 0x40
00302 #define M6811_MDA 0x20
00303 #define M6811_IRV 0x10
00304 #define M6811_PSEL3 0x08
00305 #define M6811_PSEL2 0x04
00306 #define M6811_PSEL1 0x02
00307 #define M6811_PSEL0 0x01
00308
00309 #define M6811_IO_SIZE (0x40)
00310
00311
00312
00313 extern volatile unsigned char _io_ports[];
00314
00315 #endif
00316
|