工具与软件:
我们将 DAC8168替换为 AD5648BRUZ、但它没有响应 FW 命令、尝试了复位、尝试了设置为中等级别、但没有人尝试用 TI 器件替换 AD 器件?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
您好、Erin、
FW 工程师报告说、代码测试对 TI 器件没有影响、但确实使 AD 器件的输出达到最大值。
这是用于驱动数模转换器的代码
void AD5648_channel_set (uint8_t channel_index、uint16_t counts、
uint8_t 器件){
如果(计数>= MAX_Counts){
计数= MAX_Counts;
}
HVB_SPI_INIT (HV_AD5648_DEVICE);
SPIBuff[0]= 3和0x0F;
SPIBuff[1]=((channel_index << 4)和0xf0)|((计数>> 10)和0x0000000f);
SPIBuff[2]=((计数>> 2)和0x000000ff);
SPIBuff[3]=((计数<< 6)和0x000000C0);
WriteSPI (4、器件);/*将其发送到 ad5648 *
返回;
}
用于写入和更新 DAC 地址的命令位始终为3。
接下来的4个位是要更改的通道、然后是用于设置输出的14个数据位。
此致、
Lee