4.104.114.84.95
Last change
on this file since 5a23ca84 was
509dc7c1,
checked in by Joel Sherrill <joel.sherrill@…>, on 07/30/98 at 21:27:51
|
Added getRealTime() and setRealTime().
Reimplemented checkRealTime() to use RTEMS internal routine.
|
-
Property mode set to
100644
|
File size:
1021 bytes
|
Rev | Line | |
---|
[c932d85] | 1 | /* |
---|
| 2 | * Real Time Clock (MK48T08) for RTEMS on Score603e |
---|
| 3 | * |
---|
| 4 | * Based on MVME162 TOD by: |
---|
| 5 | * COPYRIGHT (C) 1997 |
---|
| 6 | * by Katsutoshi Shibuya - BU Denken Co.,Ltd. - Sapporo - JAPAN |
---|
| 7 | * ALL RIGHTS RESERVED |
---|
| 8 | * |
---|
| 9 | * The license and distribution terms for this file may be |
---|
| 10 | * found in the file LICENSE in this distribution or at |
---|
| 11 | * http://www.OARcorp.com/rtems/license.html. |
---|
| 12 | * |
---|
| 13 | * $Id$ |
---|
| 14 | */ |
---|
| 15 | |
---|
| 16 | |
---|
| 17 | #ifndef TOD_H |
---|
| 18 | #define TOD_H |
---|
| 19 | |
---|
| 20 | #ifdef __cplusplus |
---|
| 21 | extern "C" { |
---|
| 22 | #endif |
---|
| 23 | |
---|
[509dc7c1] | 24 | /* |
---|
| 25 | * Set the RTC. |
---|
| 26 | */ |
---|
| 27 | |
---|
| 28 | int setRealTime( |
---|
| 29 | rtems_time_of_day *tod |
---|
| 30 | ); |
---|
[c932d85] | 31 | |
---|
[509dc7c1] | 32 | /* |
---|
| 33 | * Get the time from the RTC. |
---|
| 34 | */ |
---|
| 35 | |
---|
| 36 | void getRealTime( |
---|
| 37 | rtems_time_of_day *tod |
---|
| 38 | ); |
---|
| 39 | |
---|
| 40 | /* |
---|
| 41 | * Read real time from RTC and set it to RTEMS' clock manager |
---|
| 42 | */ |
---|
| 43 | |
---|
| 44 | void setRealTimeToRTEMS(); |
---|
| 45 | |
---|
| 46 | /* |
---|
| 47 | * Read time from RTEMS' clock manager and set it to RTC |
---|
| 48 | */ |
---|
| 49 | |
---|
| 50 | void setRealTimeFromRTEMS(); |
---|
| 51 | |
---|
| 52 | /* |
---|
| 53 | * Return the difference between RTC and RTEMS' clock manager time in minutes. |
---|
| 54 | * If the difference is greater than 1 day, this returns 9999. |
---|
| 55 | */ |
---|
[c932d85] | 56 | |
---|
[509dc7c1] | 57 | int checkRealTime(); |
---|
[c932d85] | 58 | |
---|
| 59 | #ifdef __cplusplus |
---|
| 60 | } |
---|
| 61 | #endif |
---|
| 62 | |
---|
| 63 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.