RTEMS 6.1-rc5
Loading...
Searching...
No Matches
Data Fields
i2c_rtc_base Struct Reference

#include <i2c-rtc.h>

Data Fields

rtems_mutex mutex
 
const char * i2c_bus_path
 
uint8_t i2c_addr
 
bool initialized
 
int(* hw_init )(struct i2c_rtc_base *ctx)
 
size_t clock_offset
 
struct {
   size_t   year
 
   size_t   month
 
   size_t   wkday
 
   size_t   day
 
   size_t   hour
 
   size_t   min
 
   size_t   sec
 
order
 

Detailed Description

Base context for the driver.

Field Documentation

◆ clock_offset

size_t i2c_rtc_base::clock_offset

Offset of the start of the clock register block.

◆ hw_init

int(* i2c_rtc_base::hw_init) (struct i2c_rtc_base *ctx)

Hardware initialization function. Will be called once when the RTC is used for the first time. Can return 0 on success or anything else on error. In an error case, it will be called again on the next use.

◆ i2c_addr

uint8_t i2c_rtc_base::i2c_addr

I2C address.

◆ i2c_bus_path

const char* i2c_rtc_base::i2c_bus_path

The path of the I2C bus device.

◆ initialized

bool i2c_rtc_base::initialized

Whether the RTC has already been initialized. Used internally.

◆ mutex

rtems_mutex i2c_rtc_base::mutex

Just initialize with RTEMS_MUTEX_INITIALIZER('mcp7940').

◆ 

struct { ... } i2c_rtc_base::order

Order of the fields of the date.


The documentation for this struct was generated from the following file: