41#define AD5628_CMD(x) ((0x000F & (int32_t)(x)) << 24)
42#define AD5628_ADDR(x) ((0x000F & (int32_t)(x)) << 20)
43#define AD5628_DATA_BITS(x) ((0x0FFF & (int32_t)(x)) << 8)
46#define AD5628_CMD_WRITE_INPUT_N 0
47#define AD5628_CMD_UPDATE_DAC_N 1
48#define AD5628_CMD_WRITE_INPUT_N_UPDATE_ALL 2
49#define AD5628_CMD_WRITE_INPUT_N_UPDATE_N 3
50#define AD5628_CMD_POWERDOWN 4
51#define AD5628_CMD_LOAD_CLEAR_CODE 5
52#define AD5628_CMD_LOAD_LDAC_REG 6
53#define AD5628_CMD_RESET 7
54#define AD5628_CMD_SET_INT_REF 8
57#define AD5628_ADDR_DAC_A 0x00
58#define AD5628_ADDR_DAC_B 0x01
59#define AD5628_ADDR_DAC_C 0x02
60#define AD5628_ADDR_DAC_D 0x03
61#define AD5628_ADDR_DAC_E 0x04
62#define AD5628_ADDR_DAC_F 0x05
63#define AD5628_ADDR_DAC_G 0x06
64#define AD5628_ADDR_DAC_H 0x07
65#define AD5628_ADDR_DAC_ALL 0x0F
68#define AD5628_INT_REF_OFF 0
69#define AD5628_INT_REF_ON 1
72#define AD5628_POWER_MODE(x) ((0x03 & (uint16_t) (x)) << 8)
74#define AD5628_PWRDN_NONE 0
75#define AD5628_PWRDN_1K 1
76#define AD5628_PWRDN_100K 2
77#define AD5628_PWRDN_3STATE 3
80#define AD5628_CODE_0X0000 0
81#define AD5628_CODE_0X8000 1
82#define AD5628_CODE_0XFFFF 2
83#define AD5628_CODE_NOP 3
112 uint32_t register_value);
void ad5628_power_mode(struct ad5628_dev *dev, uint8_t pwr_mode, uint8_t channel)
Sets the device in a specific power mode.
Definition ad5628.c:116
int32_t ad5628_init(struct ad5628_dev **device, struct ad5628_init_param init_param)
Initializes the communication peripheral and the initial Values for AD5628 Board and resets the devic...
Definition ad5628.c:52
void ad5628_reset(struct ad5628_dev *dev)
Resets the device.
Definition ad5628.c:139
int32_t ad5628_remove(struct ad5628_dev *dev)
Free the resources allocated by ad5628_init().
Definition ad5628.c:87
void ad5628_set_input_register(struct ad5628_dev *dev, uint32_t register_value)
Writes a 32-bit data-word to the Input Register of the device.
Definition ad5628.c:151
struct ad7616_init_param init_param
Definition ad7616_sdz.c:107
Header file of SPI Interface.
struct no_os_spi_desc * spi_desc
Definition ad5628.h:87
struct no_os_spi_init_param spi_init
Definition ad5628.h:92
Definition ad9361_util.h:63
Structure holding SPI descriptor.
Definition no_os_spi.h:180
Structure holding the parameters for SPI initialization.
Definition no_os_spi.h:128