Special handling for log and defmt

This commit is contained in:
Ulf Lilleengen 2022-11-09 10:04:37 +01:00
parent bd5ef80bec
commit a3a58e8e4a
Failed to extract signature

View File

@ -172,6 +172,10 @@ impl<'d, RS: RadioSwitch> SubGhzRadio<'d, RS> {
self.radio.read_buffer(ptr, &mut buf[..len as usize])?;
self.radio.set_standby(StandbyClk::Rc)?;
#[cfg(feature = "defmt")]
trace!("RX done: {=[u8]:#02X}", &mut buf[..len as usize]);
#[cfg(feature = "log")]
trace!("RX done: {:02x?}", &mut buf[..len as usize]);
return Ok((len as usize, RxQuality::new(rssi, snr as i8)));
}