LibDriver DS1302
Loading...
Searching...
No Matches
ds1302 extern driver function

ds1302 extern driver modules More...

Collaboration diagram for ds1302 extern driver function:

Functions

uint8_t ds1302_set_reg (ds1302_handle_t *handle, uint8_t reg, uint8_t *buf, uint8_t len)
 set the chip register
uint8_t ds1302_get_reg (ds1302_handle_t *handle, uint8_t reg, uint8_t *buf, uint8_t len)
 get the chip register

Detailed Description

ds1302 extern driver modules

Function Documentation

◆ ds1302_get_reg()

uint8_t ds1302_get_reg ( ds1302_handle_t * handle,
uint8_t reg,
uint8_t * buf,
uint8_t len )

get the chip register

Parameters
[in]*handlepointer to a ds1302 handle structure
[in]regregister address
[out]*bufpointer to a data buffer
[in]lendata buffer length
Returns
status code
  • 0 success
  • 1 read failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1528 of file driver_ds1302.c.

◆ ds1302_set_reg()

uint8_t ds1302_set_reg ( ds1302_handle_t * handle,
uint8_t reg,
uint8_t * buf,
uint8_t len )

set the chip register

Parameters
[in]*handlepointer to a ds1302 handle structure
[in]regregister address
[in]*bufpointer to a data buffer
[in]lendata buffer length
Returns
status code
  • 0 success
  • 1 write failed
  • 2 handle is NULL
  • 3 handle is not initialized
Note
none

Definition at line 1496 of file driver_ds1302.c.