ds1631.h File Reference

#include "pic_utils.h"
#include "config.h"

Include dependency graph for ds1631.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define __ds1631_h   defined
#define ds1631_access_config   0xAC
#define ds1631_access_th   0xA1
#define ds1631_access_tl   0xA2
#define ds1631_bit_delay()   delay_us(20)
#define ds1631_read_temp   0xAA
#define ds1631_software_por   0x54
#define ds1631_start_convert   0x51
#define ds1631_stop_convert   0x22

Functions

uns8 convert_to_dec1 (uns8 data)
uns8 convert_to_dec2 (uns8 data)
uns8 convert_to_dec2b (uns8 data)
void ds1631_get_config ()
void ds1631_get_temp ()
uns16 ds1631_get_temp (uns8 control, uns8 command)
uns8 ds1631_read_and_ack (uns8 last)
uns8 ds1631_read_config (uns8 control, uns8 command)
void ds1631_set_config ()
void ds1631_setup ()
void ds1631_start ()
void ds1631_stop ()
void ds1631_write_and_ack (uns8 data)
void ds1631_write_config (uns8 control, uns8 command, uns8 data)
void ds1631_write_convert (uns8 control, uns8 command)


Define Documentation

#define __ds1631_h   defined

Definition at line 2 of file ds1631.h.

#define ds1631_access_config   0xAC

Definition at line 27 of file ds1631.h.

#define ds1631_access_th   0xA1

Definition at line 25 of file ds1631.h.

#define ds1631_access_tl   0xA2

Definition at line 26 of file ds1631.h.

 
#define ds1631_bit_delay (  )     delay_us(20)

#define ds1631_read_temp   0xAA

Definition at line 24 of file ds1631.h.

#define ds1631_software_por   0x54

Definition at line 28 of file ds1631.h.

#define ds1631_start_convert   0x51

Definition at line 22 of file ds1631.h.

#define ds1631_stop_convert   0x22

Definition at line 23 of file ds1631.h.


Function Documentation

uns8 convert_to_dec1 ( uns8  data  ) 

Definition at line 205 of file ds1631.c.

uns8 convert_to_dec2 ( uns8  data  ) 

Definition at line 226 of file ds1631.c.

uns8 convert_to_dec2b ( uns8  data  ) 

Definition at line 183 of file ds1631.c.

void ds1631_get_config (  ) 

void ds1631_get_temp (  ) 

uns16 ds1631_get_temp ( uns8  control,
uns8  command 
)

Definition at line 136 of file ds1631.c.

References ds1631_read_and_ack(), ds1631_start(), ds1631_stop(), ds1631_write_and_ack(), READ, uns16, and WRITE.

Here is the call graph for this function:

uns8 ds1631_read_and_ack ( uns8  last  ) 

Definition at line 56 of file ds1631.c.

References change_pin, clear_pin, ds1631_bit_delay, ds1631_read_mode(), ds1631_write_mode(), set_pin, test_pin, and uns8.

Referenced by ds1631_get_temp(), and ds1631_read_config().

Here is the call graph for this function:

Here is the caller graph for this function:

uns8 ds1631_read_config ( uns8  control,
uns8  command 
)

Definition at line 118 of file ds1631.c.

References ds1631_read_and_ack(), ds1631_start(), ds1631_stop(), ds1631_write_and_ack(), READ, uns8, and WRITE.

Here is the call graph for this function:

void ds1631_set_config (  ) 

void ds1631_setup (  ) 

Definition at line 157 of file ds1631.c.

References make_output, and set_pin.

void ds1631_start (  ) 

Definition at line 15 of file ds1631.c.

References clear_pin, ds1631_bit_delay, ds1631_write_mode(), and set_pin.

Referenced by ds1631_get_temp(), ds1631_read_config(), ds1631_write_config(), and ds1631_write_convert().

Here is the call graph for this function:

Here is the caller graph for this function:

void ds1631_stop (  ) 

Definition at line 29 of file ds1631.c.

References clear_pin, ds1631_bit_delay, ds1631_write_mode(), and set_pin.

Referenced by ds1631_get_temp(), ds1631_read_config(), ds1631_write_config(), and ds1631_write_convert().

Here is the call graph for this function:

Here is the caller graph for this function:

void ds1631_write_and_ack ( uns8  data  ) 

Definition at line 91 of file ds1631.c.

References clear_pin, ds1631_bit_delay, ds1631_read_mode(), ds1631_write_byte(), ds1631_write_mode(), and set_pin.

Referenced by ds1631_get_temp(), ds1631_read_config(), ds1631_write_config(), and ds1631_write_convert().

Here is the call graph for this function:

Here is the caller graph for this function:

void ds1631_write_config ( uns8  control,
uns8  command,
uns8  data 
)

Definition at line 106 of file ds1631.c.

References ds1631_start(), ds1631_stop(), ds1631_write_and_ack(), and WRITE.

Here is the call graph for this function:

void ds1631_write_convert ( uns8  control,
uns8  command 
)

Definition at line 80 of file ds1631.c.

References ds1631_start(), ds1631_stop(), and ds1631_write_and_ack().

Here is the call graph for this function:


Generated on Mon Apr 28 08:01:26 2008 for Pic Pack by  doxygen 1.5.5