forked from M-Labs/artiq-zynq
cxp FW: update csr
This commit is contained in:
parent
50bc5e591c
commit
d9c13a742d
@ -287,7 +287,7 @@ fn set_operation_linerate(active_channels: u8, with_tag: bool, timer: &mut Globa
|
||||
}
|
||||
|
||||
fn test_counter_reset(channel: u8, with_tag: bool) -> Result<(), Error> {
|
||||
unsafe { (CXP[channel as usize].rx_bootstrap_test_counts_reset_write)(1) };
|
||||
unsafe { (CXP[channel as usize].rx_test_counts_reset_write)(1) };
|
||||
write_u32(MASTER_CHANNEL, TEST_ERROR_COUNT_SELECTOR, channel as u32, with_tag)?;
|
||||
write_u32(MASTER_CHANNEL, TEST_ERROR_COUNT, 0, with_tag)?;
|
||||
write_u64(MASTER_CHANNEL, TEST_PACKET_COUNT_TX, 0, with_tag)?;
|
||||
@ -311,19 +311,19 @@ fn verify_test_result(channel: u8, with_tag: bool) -> Result<(), Error> {
|
||||
// verify camera -> grabber connection test result
|
||||
let camera_test_pak_cnt = read_u64(MASTER_CHANNEL, TEST_PACKET_COUNT_TX, true)?;
|
||||
unsafe {
|
||||
if (CXP[channel as usize].rx_bootstrap_test_packet_counter_read)() != camera_test_pak_cnt as u16 {
|
||||
if (CXP[channel as usize].rx_test_packet_counter_read)() != camera_test_pak_cnt as u16 {
|
||||
info!(
|
||||
"CHANNEL #{} test packet cnt = {}",
|
||||
channel,
|
||||
(CXP[channel as usize].rx_bootstrap_test_packet_counter_read)()
|
||||
(CXP[channel as usize].rx_test_packet_counter_read)()
|
||||
);
|
||||
return Err(Error::UnstableRX);
|
||||
};
|
||||
if (CXP[channel as usize].rx_bootstrap_test_error_counter_read)() > 0 {
|
||||
if (CXP[channel as usize].rx_test_error_counter_read)() > 0 {
|
||||
info!(
|
||||
"CHANNEL #{} test packet error cnt = {}",
|
||||
channel,
|
||||
(CXP[channel as usize].rx_bootstrap_test_error_counter_read)()
|
||||
(CXP[channel as usize].rx_test_error_counter_read)()
|
||||
);
|
||||
return Err(Error::UnstableRX);
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user