The status byte returned by the command over SPI is not important in this
particular case, so we ignore it intentionally.  In order to get a receive()
event fired, the radio must be in the proper state, and therefore
beginRead() will always succeeds.  

The status byte is important when the radio driver is attempting to change
the state of the radio, and needs to verify the radio's status.

-David




-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Liusand
Sent: Thursday, March 13, 2008 6:35 PM
To: tinyos-help@millennium.berkeley.edu
Subject: [Tinyos-help] Question on CC2420ReceiveP.nc in TinyOS 2.0.2

Hi,

I noticed that, in CC2420ReceiveP.nc from TinyOS 2.0.2, the receive() 
function calls RXFIFO.beginRead() without checking its return value. But as 
stated in CC2420Fifo.nc, beginRead() is supposed to "return status byte 
returned when sending the last address byte of the SPI transaction". So does

this mean the return value is not important and beginRead() will always 
succeed?

Thanks,

Sha 

_______________________________________________
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


_______________________________________________
Tinyos-help mailing list
Tinyos-help@millennium.berkeley.edu
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to