source: rtems/cpukit/libcsupport/include/motorola/mc68230.h @ 7945944

4.104.114.84.95
Last change on this file since 7945944 was 7945944, checked in by Ralf Corsepius <ralf.corsepius@…>, on 01/28/05 at 08:04:27

New header guards.

  • Property mode set to 100644
File size: 1.7 KB
Line 
1/**
2 * @file rtems/motorola/mc68230.h
3 */
4
5/*
6 * mc68230.h -- Low level support code for the Motorola 68230 Parallel
7 *              Interface/Timer (PIT)
8 *
9 * Modified by Doug McBride, Colorado Space Grant College
10 *
11 * Format taken partly from RTEMS code and mostly from Motorola IDP user's
12 * manual.  RTEMS copyright information below.
13 *
14 *  COPYRIGHT (c) 1989-1999.
15 *  On-Line Applications Research Corporation (OAR).
16 *
17 *  The license and distribution terms for this file may be
18 *  found in the file LICENSE in this distribution or at
19 *  http://www.rtems.com/license/LICENSE.
20 *
21 *  $Id$
22 */
23
24#ifndef _RTEMS_MOTOROLA_MC68230_H
25#define _RTEMS_MOTOROLA_MC68230_H
26
27/* Some Motorola IDP User manual defines: */
28#define PIT_ADDR        0x00c01003              /* base address of the PIT */
29#define REGOFF  0x04                            /* Difference between addresses */
30#define VECT    64
31#define H1VECT  0x00
32#define H2VECT  0x01
33#define H3VECT  0x02
34#define H4VECT  0x03
35
36/*
37 * mc68230 register offsets
38 */
39#define PGCR    0x00
40#define PSRR    1*REGOFF
41#define PADDR   2*REGOFF
42#define PBDDR   3*REGOFF
43#define PCDDR   4*REGOFF
44#define PIVR    5*REGOFF
45#define PACR    6*REGOFF
46#define PBCR    7*REGOFF
47#define PADR    8*REGOFF
48#define PBDR    9*REGOFF
49#define PAAR    10*REGOFF
50#define PBAR    11*REGOFF
51#define PCDR    12*REGOFF
52#define PITSR   13*REGOFF
53#define TCR             16*REGOFF
54#define TIVR    17*REGOFF
55#define CPRH    19*REGOFF
56#define CPRM    20*REGOFF
57#define CPRL    21*REGOFF
58#define CNTRH   23*REGOFF
59#define CNTRM   24*REGOFF
60#define CNTRL   25*REGOFF
61#define TSR             26*REGOFF
62
63/* Some RTEMS style defines: */
64#ifndef VOL8
65#define VOL8( ptr )   ((volatile uint8_t   *)(ptr))
66#endif
67
68#define MC68230_WRITE( reg, data ) \
69   *(VOL8(PIT_ADDR+reg)) = (data)
70
71#define MC68230_READ( reg, data ) \
72   (data) = *(VOL8(PIT_ADDR+reg))
73
74#endif
Note: See TracBrowser for help on using the repository browser.