2 /*-------------------------------------------------------------------------
3 Register Declarations for ATMEL 89x55 Processors
5 Written By - Bernd Bartmann
6 Bernd.Bartmann@picard.isdn.cs.tu-berlin.de (1999)
7 based on reg51.h by Sandeep Dutta sandeep.dutta@usa.net
8 KEIL C compatible definitions are included
10 This program is free software; you can redistribute it and/or modify it
11 under the terms of the GNU General Public License as published by the
12 Free Software Foundation; either version 2, or (at your option) any
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24 In other words, you are welcome to use, share and improve this program.
25 You are forbidden to forbid anyone else to use, share and improve
26 what you give them. Help stamp out software-hoarding!
27 -------------------------------------------------------------------------*/
32 /* BYTE addressable registers */
63 /* BIT addressable registers */
154 sbit at 0xC8 T2CON_0 ;
155 sbit at 0xC9 T2CON_1 ;
156 sbit at 0xCA T2CON_2 ;
157 sbit at 0xCB T2CON_3 ;
158 sbit at 0xCC T2CON_4 ;
159 sbit at 0xCD T2CON_5 ;
160 sbit at 0xCE T2CON_6 ;
161 sbit at 0xCF T2CON_7 ;
163 sbit at 0xC8 CP_RL2 ;
183 /* BIT definitions for bits that are not directly accessible */
228 #define T0_GATE_ 0x08
232 #define T1_GATE_ 0x80
237 #define T0_MASK_ 0x0F
238 #define T1_MASK_ 0xF0
248 /* Interrupt numbers: address = (number * 8) + 3 */
249 #define IE0_VECTOR 0 /* 0x03 external interrupt 0 */
250 #define TF0_VECTOR 1 /* 0x0b timer 0 */
251 #define IE1_VECTOR 2 /* 0x13 external interrupt 1 */
252 #define TF1_VECTOR 3 /* 0x1b timer 1 */
253 #define SI0_VECTOR 4 /* 0x23 serial port 0 */
254 #define TF2_VECTOR 5 /* 0x2B timer 2 */
255 #define EX2_VECTOR 5 /* 0x2B external interrupt 2 */