- // the most likely place for busy channel
- rssiBusy += readRegister(RF230_PHY_RSSI) - (rssiBusy >> 2);
+ // the most likely place for busy channel, with no TRX_END interrupt
+ if( irq == RF230_IRQ_RX_START )
+ {
+ temp = readRegister(RF230_PHY_RSSI) & RF230_RSSI_MASK;
+
+ rssiBusy += temp - (rssiBusy >> 2);
+
+#ifdef RF230_RSSI_ENERGY
+ temp = readRegister(RF230_PHY_ED_LEVEL);
+#endif
+
+ call PacketRSSI.set(rxMsg, temp);
+ }
+ else
+ call PacketRSSI.clear(rxMsg);