struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / device / include / rab / r3ka.h
blob016928ad8edb1a8d04eed39d3441f32297080b33
1 /*-------------------------------------------------------------------------
2 r3ka.h - definitions on the built in I/O ports for the Rabbit 3000A
3 for use with SDCC
5 Copyright (C) 2020, Philipp Klaus Krause <pkk AT spth.de>
7 This library is free software; you can redistribute it and/or modify it
8 under the terms of the GNU General Public License as published by the
9 Free Software Foundation; either version 2, or (at your option) any
10 later version.
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this library; see the file COPYING. If not, write to the
19 Free Software Foundation, 51 Franklin Street, Fifth Floor, Boston,
20 MA 02110-1301, USA.
22 As a special exception, if you link this library with other files,
23 some of which are compiled with SDCC, to produce an executable,
24 this library does not by itself cause the resulting executable to
25 be covered by the GNU General Public License. This exception does
26 not however invalidate any other reasons why the executable file
27 might be covered by the GNU General Public License.
28 -------------------------------------------------------------------------*/
30 #ifndef __R3KA_H__
31 #define __R3KA_H__ 1
33 #ifndef _RABREG
34 #define _RABREG(addr, reg) __sfr __banked __at(addr) reg
35 #endif
37 #include "r3k.h"
39 _RABREG(0x000C, SWDTR); // Secondary Watchdog Timer Register
41 _RABREG(0x0095, QDC1HR); // Quad Decode Count 1 High Register
42 _RABREG(0x0097, QDC2HR); // Quad Decode Count 2 High Register
44 _RABREG(0x0300, RTUER); // Real Time Clock User Enable Register
45 _RABREG(0x0320, SPUER); // Slave Port User Enable Register
46 _RABREG(0x0330, PAUER); // Parallel Port A User Enable Register
47 _RABREG(0x0338, PFUER); // Parallel Port F User Enable Register
48 _RABREG(0x0340, PBUER); // Parallel Port B User Enable Register
49 _RABREG(0x0348, PGUER); // Parallel Port G User Enable Register
50 _RABREG(0x0350, PCUER); // Parallel Port C User Enable Register
51 _RABREG(0x0358, ICUER); // Input Capture C User Enable Register
52 _RABREG(0x0360, PDUER); // Parallel Port D User Enable Register
53 _RABREG(0x0370, PEUER); // Parallel Port E User Enable Register
54 _RABREG(0x0380, IBUER); // I/O Bank User Enable Register
55 _RABREG(0x0388, PWUER); // PWM User Enable Register
56 _RABREG(0x0390, QDUER); // Quad Decode User Enable Register
57 _RABREG(0x0398, IUER); // External Interrupt User Enable Register
58 _RABREG(0x03A0, TAUER); // Timer A User Enable Register
59 _RABREG(0x03B0, TBUER); // Timer B User Enable Register
60 _RABREG(0x03C0, SAUER); // Serial Port A User Enable Register
61 _RABREG(0x03C8, SEUER); // Serial Port E User Enable Register
62 _RABREG(0x03D0, SBUER); // Serial Port B User Enable Register
63 _RABREG(0x03D8, SFUER); // Serial Port F User Enable Register
64 _RABREG(0x03E0, SCUER); // Serial Port C User Enable Register
65 _RABREG(0x03F0, SDUER); // Serial Port D User Enable Register
67 _RABREG(0x0420, EDMR); // Enable Dual Mode Register
69 _RABREG(0x0440, WPCR); // Write Protect Control Register
71 _RABREG(0x0444, STKKCR); // Stack Limit Control Register
72 _RABREG(0x0445, STKLLR); // Stack Low Limit Register
73 _RABREG(0x0446, STKHLR); // Stack High Limit Register
75 _RABREG(0x0448, RAMSR); // RAM Segment Register
77 _RABREG(0x0460, WPLR); // Write Protect Low Register
78 _RABREG(0x0461, WPHR); // Write Protect High Register
79 _RABREG(0x0480, WPSAR); // Write Protect Segment A Register
80 _RABREG(0x0481, WPSALR); // Write Protect Segment A Low Register
81 _RABREG(0x0482, WPSAHR); // Write Protect Segment A High Register
82 _RABREG(0x0484, WPSBR); // Write Protect Segment B Register
83 _RABREG(0x0485, WPSBLR); // Write Protect Segment B Low Register
84 _RABREG(0x0486, WPSBHR); // Write Protect Segment B High Register
86 #endif