mirror of
https://github.com/m-labs/artiq.git
synced 2024-12-25 11:18:27 +08:00
firmware: program I2C switch on Sayma RTM
This commit is contained in:
parent
66b3132c28
commit
b5501aaf00
@ -11,6 +11,7 @@ const ADDRESS: u8 = 0x68;
|
||||
|
||||
#[cfg(any(soc_platform = "kasli",
|
||||
soc_platform = "sayma_amc",
|
||||
soc_platform = "sayma_rtm",
|
||||
soc_platform = "kc705"))]
|
||||
fn pca9548_select(address: u8, channels: u8) -> Result<()> {
|
||||
i2c::start(BUSNO).unwrap();
|
||||
@ -202,6 +203,8 @@ pub fn setup(settings: &FrequencySettings, input: Input) -> Result<()> {
|
||||
}
|
||||
#[cfg(soc_platform = "sayma_amc")]
|
||||
pca9548_select(0x70, 1 << 4)?;
|
||||
#[cfg(soc_platform = "sayma_rtm")]
|
||||
pca9548_select(0x77, 1 << 5)?;
|
||||
#[cfg(soc_platform = "kc705")]
|
||||
pca9548_select(0x74, 1 << 7)?;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user