source: rtems/c/src/lib/libbsp/m68k/idp/include/motorola/mc68230.h @ 5bc6237

4.11
Last change on this file since 5bc6237 was 5bc6237, checked in by Joel Sherrill <joel.sherrill@…>, on Mar 9, 2015 at 8:47:47 PM

Move libcsupport/include/motorola/*.h to m68k/idp BSP

These header files were only used by one BSP and they are
hardware dependent. The hardware dependency always made
them bad candidates for where they were in the tree. But
this fixes that.

  • Property mode set to 100644
File size: 2.1 KB
Line 
1/**
2 * @file rtems/motorola/mc68230.h
3 *
4 * Low level support code for the Motorola 68230 Parallel
5 * Interface/Timer (PIT)
6 */
7
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-2011.
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.org/license/LICENSE.
20 */
21
22#ifndef _RTEMS_MOTOROLA_MC68230_H
23#define _RTEMS_MOTOROLA_MC68230_H
24
25/* Some Motorola IDP User manual defines: */
26#define MC68230_PIT_ADDR        0x00c01003              /* base address of the PIT */
27#define MC68230_REGOFF  0x04                            /* Difference between addresses */
28#define MC68230_VECT    64
29#define MC68230_H1VECT  0x00
30#define MC68230_H2VECT  0x01
31#define MC68230_H3VECT  0x02
32#define MC68230_H4VECT  0x03
33
34/*
35 * mc68230 register offsets
36 */
37#define MC68230_PGCR    0x00
38#define MC68230_PSRR    1*MC68230_REGOFF
39#define MC68230_PADDR   2*MC68230_REGOFF
40#define MC68230_PBDDR   3*MC68230_REGOFF
41#define MC68230_PCDDR   4*MC68230_REGOFF
42#define MC68230_PIVR    5*MC68230_REGOFF
43#define MC68230_PACR    6*MC68230_REGOFF
44#define MC68230_PBCR    7*MC68230_REGOFF
45#define MC68230_PADR    8*MC68230_REGOFF
46#define MC68230_PBDR    9*MC68230_REGOFF
47#define MC68230_PAAR    10*MC68230_REGOFF
48#define MC68230_PBAR    11*MC68230_REGOFF
49#define MC68230_PCDR    12*MC68230_REGOFF
50#define MC68230_PITSR   13*MC68230_REGOFF
51#define MC68230_TCR     16*MC68230_REGOFF
52#define MC68230_TIVR    17*MC68230_REGOFF
53#define MC68230_CPRH    19*MC68230_REGOFF
54#define MC68230_CPRM    20*MC68230_REGOFF
55#define MC68230_CPRL    21*MC68230_REGOFF
56#define MC68230_CNTRH   23*MC68230_REGOFF
57#define MC68230_CNTRM   24*MC68230_REGOFF
58#define MC68230_CNTRL   25*MC68230_REGOFF
59#define MC68230_TSR     26*MC68230_REGOFF
60
61/* Some RTEMS style defines: */
62#ifndef MC68230_VOL8
63#define MC68230_VOL8( ptr )   ((volatile uint8_t   *)(ptr))
64#endif
65
66#define MC68230_WRITE( reg, data ) \
67   *(MC68230_VOL8(MC68230_PIT_ADDR+reg)) = (data)
68
69#define MC68230_READ( reg, data ) \
70   (data) = *(MC68230_VOL8(MC68230_PIT_ADDR+reg))
71
72#endif
Note: See TracBrowser for help on using the repository browser.