forked from M-Labs/artiq
1
0
Fork 0

Firmware: AD9117 Add check presence of clk comment

This commit is contained in:
linuswck 2023-09-18 12:58:39 +08:00 committed by Sébastien Bourdeauducq
parent 85abb1da2c
commit 372008cb66
1 changed files with 1 additions and 0 deletions

View File

@ -53,6 +53,7 @@ pub fn init() -> Result<(), &'static str> {
debug!("DAC AD9117 Channel {} has incorrect hardware version. VERSION reg: {:02x}", channel, reg);
return Err("DAC AD9117 hardware version is not equal to 0x0A");
}
// Check for the presence of DCLKIO and CLKIN
let reg = read(channel, CLKMODE_REG)?;
if reg >> 4 & 1 != 0 {
debug!("DAC AD9117 Channel {} retiming fails. CLKMODE reg: {:02x}", channel, reg);