enhance com debugging

This commit is contained in:
bunnie 2022-07-14 03:49:32 +08:00
parent f6349aada3
commit b83c75bbf0

View file

@ -425,8 +425,9 @@ fn main() -> ! {
trace!("starting main loop");
loop {
let mut msg = xous::receive_message(com_sid).unwrap();
trace!("Message: {:?}", msg);
match FromPrimitive::from_usize(msg.body.id()) {
let opcode: Option<Opcode> = FromPrimitive::from_usize(msg.body.id());
log::debug!("{:?}", opcode);
match opcode {
Some(Opcode::SuspendResume) => xous::msg_scalar_unpack!(msg, token, _, _, _, {
com.txrx(ComState::LINK_SET_INTMASK.verb);
com.txrx(0); // suppress interrupts on suspend