no-OS
ad5593r.h
Go to the documentation of this file.
1 /***************************************************************************/
33 #ifndef AD5593R_H_
34 #define AD5593R_H_
35 
36 #include "stdint.h"
37 #include "ad5592r-base.h"
38 
39 int32_t ad5593r_write_dac(struct ad5592r_dev *dev, uint8_t chan,
40  uint16_t value);
41 int32_t ad5593r_read_adc(struct ad5592r_dev *dev, uint8_t chan,
42  uint16_t *value);
43 int32_t ad5593r_multi_read_adc(struct ad5592r_dev *dev,
44  uint16_t chans, uint16_t *value);
45 int32_t ad5593r_reg_write(struct ad5592r_dev *dev, uint8_t reg,
46  uint16_t value);
47 int32_t ad5593r_reg_read(struct ad5592r_dev *dev, uint8_t reg,
48  uint16_t *value);
49 int32_t ad5593r_gpio_read(struct ad5592r_dev *dev, uint8_t *value);
50 int32_t ad5593r_init(struct ad5592r_dev *dev,
52 
53 #endif /* AD5593R_H_ */
no_os_i2c_write
int32_t no_os_i2c_write(struct no_os_i2c_desc *desc, uint8_t *data, uint8_t bytes_number, uint8_t stop_bit)
I2C Write data to slave device.
Definition: no_os_i2c.c:159
STOP_BIT
#define STOP_BIT
Definition: ad5593r.c:45
AD5593R_MODE_CONF
#define AD5593R_MODE_CONF
Definition: ad5593r.c:38
ad5593r_reg_write
int32_t ad5593r_reg_write(struct ad5592r_dev *dev, uint8_t reg, uint16_t value)
Definition: ad5593r.c:175
AD5592R_REG_ADC_SEQ
@ AD5592R_REG_ADC_SEQ
Definition: ad5592r-base.h:58
ad5592r_software_reset
int32_t ad5592r_software_reset(struct ad5592r_dev *dev)
Definition: ad5592r-base.c:182
AD5593R_ADC_VALUES_BUFF_SIZE
#define AD5593R_ADC_VALUES_BUFF_SIZE
Definition: ad5593r.c:47
ad5593r_reg_read
int32_t ad5593r_reg_read(struct ad5592r_dev *dev, uint8_t reg, uint16_t *value)
Definition: ad5593r.c:205
ad5593r_reg_write
int32_t ad5593r_reg_write(struct ad5592r_dev *dev, uint8_t reg, uint16_t value)
Definition: ad5593r.c:175
ad5592r_dev::i2c
struct no_os_i2c_desc * i2c
Definition: ad5592r-base.h:117
ad5593r_gpio_read
int32_t ad5593r_gpio_read(struct ad5592r_dev *dev, uint8_t *value)
Definition: ad5593r.c:236
ad5593r_write_dac
int32_t ad5593r_write_dac(struct ad5592r_dev *dev, uint8_t chan, uint16_t value)
Definition: ad5593r.c:66
ad5593r_multi_read_adc
int32_t ad5593r_multi_read_adc(struct ad5592r_dev *dev, uint16_t chans, uint16_t *values)
Definition: ad5593r.c:131
ad5593r.h
Header file of AD5593R driver.
ad5592r_rw_ops::write_dac
int32_t(* write_dac)(struct ad5592r_dev *dev, uint8_t chan, uint16_t value)
Definition: ad5592r-base.h:98
no_os_error.h
Error codes definition.
ad5593r_write_dac
int32_t ad5593r_write_dac(struct ad5592r_dev *dev, uint8_t chan, uint16_t value)
Definition: ad5593r.c:66
ad5593r_reg_read
int32_t ad5593r_reg_read(struct ad5592r_dev *dev, uint8_t reg, uint16_t *value)
Definition: ad5593r.c:205
AD5593R_MODE_ADC_READBACK
#define AD5593R_MODE_ADC_READBACK
Definition: ad5593r.c:40
no_os_hweight16
unsigned int no_os_hweight16(uint16_t word)
ad5593r_gpio_read
int32_t ad5593r_gpio_read(struct ad5592r_dev *dev, uint8_t *value)
Definition: ad5593r.c:236
ad5592r-base.h
Header file of AD5592R Base Driver.
ad5592r_init_param
Definition: ad5592r-base.h:111
ad5593r_rw_ops
const struct ad5592r_rw_ops ad5593r_rw_ops
Definition: ad5593r.c:49
no_os_i2c_read
int32_t no_os_i2c_read(struct no_os_i2c_desc *desc, uint8_t *data, uint8_t bytes_number, uint8_t stop_bit)
I2C Read data from slave device.
Definition: no_os_i2c.c:190
AD5593R_MODE_REG_READBACK
#define AD5593R_MODE_REG_READBACK
Definition: ad5593r.c:43
AD5592R_REG_PD
@ AD5592R_REG_PD
Definition: ad5592r-base.h:67
NO_OS_BIT
#define NO_OS_BIT(x)
Definition: no_os_util.h:45
ad5592r_rw_ops
Definition: ad5592r-base.h:97
RESTART_BIT
#define RESTART_BIT
Definition: ad5593r.c:46
AD5593R_MODE_GPIO_READBACK
#define AD5593R_MODE_GPIO_READBACK
Definition: ad5593r.c:42
init_param
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:113
AD5593R_MODE_DAC_WRITE
#define AD5593R_MODE_DAC_WRITE
Definition: ad5593r.c:39
AD5592R_REG_PD_EN_REF
#define AD5592R_REG_PD_EN_REF
Definition: ad5592r-base.h:74
ad5592r_set_channel_modes
int32_t ad5592r_set_channel_modes(struct ad5592r_dev *dev)
Definition: ad5592r-base.c:203
AD5592R_REG_RESET
@ AD5592R_REG_RESET
Definition: ad5592r-base.h:70
ad5593r_init
int32_t ad5593r_init(struct ad5592r_dev *dev, struct ad5592r_init_param *init_param)
Definition: ad5593r.c:265
ad5593r_read_adc
int32_t ad5593r_read_adc(struct ad5592r_dev *dev, uint8_t chan, uint16_t *value)
Definition: ad5593r.c:89
ad5593r_multi_read_adc
int32_t ad5593r_multi_read_adc(struct ad5592r_dev *dev, uint16_t chans, uint16_t *value)
Definition: ad5593r.c:131
ad5592r_dev
Definition: ad5592r-base.h:115
ad5593r_init
int32_t ad5593r_init(struct ad5592r_dev *dev, struct ad5592r_init_param *init_param)
Definition: ad5593r.c:265
ad5593r_read_adc
int32_t ad5593r_read_adc(struct ad5592r_dev *dev, uint8_t chan, uint16_t *value)
Definition: ad5593r.c:89
ad5592r_dev::ops
const struct ad5592r_rw_ops * ops
Definition: ad5592r-base.h:116