no-OS
|
Implementation of AD5628 Driver. More...
Functions | |
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 device. More... | |
int32_t | ad5628_remove (struct ad5628_dev *dev) |
Free the resources allocated by ad5628_init(). More... | |
void | ad5628_power_mode (struct ad5628_dev *dev, uint8_t pwr_mode, uint8_t channel) |
Sets the device in a specific power mode. More... | |
void | ad5628_reset (struct ad5628_dev *dev) |
Resets the device. More... | |
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. More... | |
Implementation of AD5628 Driver.
Copyright 2012(c) Analog Devices, Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY ANALOG DEVICES "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL ANALOG DEVICES BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, INTELLECTUAL PROPERTY RIGHTS, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
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 device.
device | - The device structure. |
init_param | - The structure that contains the device initial parameters. |
void ad5628_power_mode | ( | struct ad5628_dev * | dev, |
uint8_t | pwr_mode, | ||
uint8_t | channel | ||
) |
Sets the device in a specific power mode.
dev | - The device structure. |
pwr_mode | - power mode of the device. Example: AD5628_PWRDN_NONE AD5628_PWRDN_1K AD5628_PWRDN_100K AD5628_PWRDN_3STATE |
channel | - The channel or channels that are being configured. Example: AD5628_ADDR_DAC_A AD5628_ADDR_DAC_B ... AD5628_ADDR_DAC_ALL |
int32_t ad5628_remove | ( | struct ad5628_dev * | dev | ) |
Free the resources allocated by ad5628_init().
dev | - The device structure. |
void ad5628_reset | ( | struct ad5628_dev * | dev | ) |
Resets the device.
dev | - The device structure. |
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.
dev | - The device structure. |
register_value | - Value of the register. |