forked from M-Labs/artiq-zynq
proto fw: remove downconn debug
This commit is contained in:
parent
9a06848cbb
commit
9ecc3cebb6
|
@ -209,30 +209,6 @@ pub fn print_packetu32(pak: &[u32]) {
|
||||||
println!("============================================");
|
println!("============================================");
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn downconn_debug_main() {
|
|
||||||
downconn_debug_send(&Packet::CtrlRead {
|
|
||||||
addr: 0x00,
|
|
||||||
length: 0x04,
|
|
||||||
});
|
|
||||||
|
|
||||||
const LEN: usize = 40;
|
|
||||||
let mut pak_arr: [u32; LEN] = [0; LEN];
|
|
||||||
let mut i: usize = 0;
|
|
||||||
unsafe {
|
|
||||||
while csr::cxp::downconn_debug_out_dout_valid_read() == 1 {
|
|
||||||
pak_arr[i] = csr::cxp::downconn_debug_out_dout_pak_read();
|
|
||||||
// println!("received {:#04X}", pak_arr[i]);
|
|
||||||
csr::cxp::downconn_debug_out_inc_write(1);
|
|
||||||
i += 1;
|
|
||||||
if i == LEN {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
print_packetu32(&pak_arr)
|
|
||||||
}
|
|
||||||
|
|
||||||
pub fn downconn_debug_send(packet: &Packet) -> Result<(), Error> {
|
pub fn downconn_debug_send(packet: &Packet) -> Result<(), Error> {
|
||||||
let mut buffer: [u8; MAX_PACKET] = [0; MAX_PACKET];
|
let mut buffer: [u8; MAX_PACKET] = [0; MAX_PACKET];
|
||||||
let mut writer = Cursor::new(&mut buffer[..]);
|
let mut writer = Cursor::new(&mut buffer[..]);
|
||||||
|
|
Loading…
Reference in New Issue