/* Allows power-up/down of the dc-to-dc converter, DAC and internal amplifiers for the selected channel.  */
void ad5755_set_channel_power(struct ad5755_dev *dev, uint8_t channel, uint8_t pwr_status)
/* Allows power-up/down of the dc-to-dc converter, DAC and internal amplifiers for the selected channel.  */
void ad5755_set_channel_power(struct ad5755_dev *dev, uint8_t channel, uint8_t pwr_status)
{
	uint32_t old_dac_ctrl_reg = 0;
	uint32_t new_dac_ctrl_reg = 0;
	old_dac_ctrl_reg = ad5755_get_register_value(dev,
			   AD5755_RD_CTRL_REG(channel));
	old_dac_ctrl_reg &= ~(AD5755_DAC_INT_ENABLE |
			      AD5755_DAC_DC_DC |
			      AD5755_DAC_OUTEN);
	new_dac_ctrl_reg = old_dac_ctrl_reg | (pwr_status * (AD5755_DAC_INT_ENABLE |
					       AD5755_DAC_DC_DC |
					       AD5755_DAC_OUTEN));
	ad5755_set_control_registers(dev,
				     AD5755_CREG_DAC,
				     AD5755_DAC_A,
				     new_dac_ctrl_reg);
}