MityDSP Documentation Index

MityDSP::tcDspRtcDS1305 Class Reference

Instances of this class handle access to the DS1305 real-time clock chip. More...

#include <core/DspRtcDS1305.h>

Inheritance diagram for MityDSP::tcDspRtcDS1305:
MityDSP::tcDspRtcBase

List of all members.

Public Member Functions

 tcDspRtcDS1305 (tcDspMcbsp *apMcbsp, tcDspOutputLatch *apLatch, unsigned int anCSID, unsigned int anYear=Y2K)
 This constructor is used to initialize a DS1305 real-time clock over a specified McBSP interface.
 ~tcDspRtcDS1305 ()
 Default Destructor.
tsCLTime get_time (unsigned short *apHundredths=NULL)
 This routine reads the current time from the real-time clock and returns it as a 32-bit tsCLTime value.
void set_time (tsCLTime asTime)
 This routine provides an alternate interface to the set_time routine, using a tsCLTime value.
void set_time (unsigned int anYear, unsigned int anMonth, unsigned int anDay, unsigned int anHour, unsigned int anMin, unsigned int anSec)
 This routine sets the current time of the real-time clock using discrete year, month, day, hour, minute and second values.

Detailed Description

Instances of this class handle access to the DS1305 real-time clock chip.

See also:
tcDspRtcDS1305 Page

Constructor & Destructor Documentation

tcDspRtcDS1305::tcDspRtcDS1305 ( tcDspMcbsp apMcbsp,
tcDspOutputLatch apLatch,
unsigned int  anCSID,
unsigned int  anYear = Y2K 
)

This constructor is used to initialize a DS1305 real-time clock over a specified McBSP interface.

Parameters:
[in] apMcbsp The tcDspMcbsp object to use for communication.
[in] apLatch The tcDspOutputLatch to use for McBSP chip select.
[in] anCSID The chip select ID to use with apLatch.
[in] anYear Base year for this real-time clock.
tcDspRtcDS1305::~tcDspRtcDS1305 (  ) 

Default Destructor.


Member Function Documentation

tsCLTime tcDspRtcDS1305::get_time ( unsigned short *  apHundredths = NULL  )  [virtual]

This routine reads the current time from the real-time clock and returns it as a 32-bit tsCLTime value.

Returns:
a tsCLTime instance holding the current time.

Implements MityDSP::tcDspRtcBase.

void tcDspRtcDS1305::set_time ( tsCLTime  asTime  )  [virtual]

This routine provides an alternate interface to the set_time routine, using a tsCLTime value.

Parameters:
[in] asTime A tsCLTime structure representing the current time.

Implements MityDSP::tcDspRtcBase.

void tcDspRtcDS1305::set_time ( unsigned int  anYear,
unsigned int  anMonth,
unsigned int  anDay,
unsigned int  anHour,
unsigned int  anMin,
unsigned int  anSec 
) [virtual]

This routine sets the current time of the real-time clock using discrete year, month, day, hour, minute and second values.

The current epoch is updated if required.

Parameters:
[in] anYear Current year.
[in] anMonth Current month (1-12).
[in] anDay Current day (0-31).
[in] anHour Current hour in 24-hour time (0-24).
[in] anMin Current Minute (0-60).
[in] anSec Current Seconds (0-60).

Implements MityDSP::tcDspRtcBase.


  
Generated on Fri Sep 23 16:33:54 2011 for MityDSP Core by  Doxygen Version 1.6.1
Copyright © 2009, Critical Link LLC, All rights reserved.