test: jazzrtc.h Source File

Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

# jazzrtc.h

Go to the documentation of this file.

    00001 /*++ BUILD Version: 0002    // Increment this if a change has global effects
    00002
    00003 Copyright (c) 1991  Microsoft Corporation
    00004
    00005 Module Name:
    00006
    00007     jazzrtc.h
    00008
    00009 Abstract:
    00010
    00011     This module is the header file that describes hardware structure
    00012     for the realtime clock on the Jazz R3000 and R4000 system.
    00013
    00014 Author:
    00015
    00016     David N. Cutler (davec) 3-May-1991
    00017
    00018 Revision History:
    00019
    00020 --*/
    00021
    00022 #ifndef _JAZZRTC_
    00023 #define _JAZZRTC_
    00024
    00025 //
    00026 // Define Realtime Clock register numbers.
    00027 //
    00028
    00029 #define RTC_SECOND 0                    // second of minute [0..59]
    00030 #define RTC_SECOND_ALARM 1              // seconds to alarm
    00031 #define RTC_MINUTE 2                    // minute of hour [0..59]
    00032 #define RTC_MINUTE_ALARM 3              // minutes to alarm
    00033 #define RTC_HOUR 4                      // hour of day [0..23]
    00034 #define RTC_HOUR_ALARM 5                // hours to alarm
    00035 #define RTC_DAY_OF_WEEK 6               // day of week [1..7]
    00036 #define RTC_DAY_OF_MONTH 7              // day of month [1..31]
    00037 #define RTC_MONTH 8                     // month of year [1..12]
    00038 #define RTC_YEAR 9                      // year [00..99]
    00039 #define RTC_CONTROL_REGISTERA 10        // control register A
    00040 #define RTC_CONTROL_REGISTERB 11        // control register B
    00041 #define RTC_CONTROL_REGISTERC 12        // control register C
    00042 #define RTC_CONTROL_REGISTERD 13        // control register D
    00043 #define RTC_BATTERY_BACKED_UP_RAM 14    // battery backed up RAM [0..49]
    00044
    00045 //
    00046 // Define Control Register A structure.
    00047 //
    00048
    00049 typedef struct _RTC_CONTROL_REGISTER_A {
    00050     UCHAR RateSelect : 4;
    00051     UCHAR TimebaseDivisor : 3;
    00052     UCHAR UpdateInProgress : 1;
    00053 } RTC_CONTROL_REGISTER_A, *PRTC_CONTROL_REGISTER_A;
    00054
    00055 //
    00056 // Define Control Register B structure.
    00057 //
    00058
    00059 typedef struct _RTC_CONTROL_REGISTER_B {
    00060     UCHAR DayLightSavingsEnable : 1;
    00061     UCHAR HoursFormat : 1;
    00062     UCHAR DataMode : 1;
    00063     UCHAR SquareWaveEnable : 1;
    00064     UCHAR UpdateInterruptEnable : 1;
    00065     UCHAR AlarmInterruptEnable : 1;
    00066     UCHAR TimerInterruptEnable : 1;
    00067     UCHAR SetTime : 1;
    00068 } RTC_CONTROL_REGISTER_B, *PRTC_CONTROL_REGISTER_B;
    00069
    00070 //
    00071 // Define Control Register C structure.
    00072 //
    00073
    00074 typedef struct _RTC_CONTROL_REGISTER_C {
    00075     UCHAR Fill : 4;
    00076     UCHAR UpdateInterruptFlag : 1;
    00077     UCHAR AlarmInterruptFlag : 1;
    00078     UCHAR TimeInterruptFlag : 1;
    00079     UCHAR InterruptRequest : 1;
    00080 } RTC_CONTROL_REGISTER_C, *PRTC_CONTROL_REGISTER_C;
    00081
    00082 //
    00083 // Define Control Register D structure.
    00084 //
    00085
    00086 typedef struct _RTC_CONTROL_REGISTER_D {
    00087     UCHAR Fill : 7;
    00088     UCHAR ValidTime : 1;
    00089 } RTC_CONTROL_REGISTER_D, *PRTC_CONTROL_REGISTER_D;
    00090
    00091 #endif // _JAZZRTC_