[Tinyos-2-commits]
CVS: tinyos-2.x/tos/lib/net/Deluge/FlashVolumeManager
FlashVolumeManagerP.nc, 1.6, 1.7
Phil Levis
scipio at users.sourceforge.net
Thu Sep 13 16:10:50 PDT 2007
Update of /cvsroot/tinyos/tinyos-2.x/tos/lib/net/Deluge/FlashVolumeManager
In directory sc8-pr-cvs10.sourceforge.net:/tmp/cvs-serv27056/tos/lib/net/Deluge/FlashVolumeManager
Modified Files:
FlashVolumeManagerP.nc
Log Message:
The big interface switchover for Packet, Send, Receive, and AMSend.
Index: FlashVolumeManagerP.nc
===================================================================
RCS file: /cvsroot/tinyos/tinyos-2.x/tos/lib/net/Deluge/FlashVolumeManager/FlashVolumeManagerP.nc,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** FlashVolumeManagerP.nc 11 Jul 2007 20:59:11 -0000 1.6
--- FlashVolumeManagerP.nc 13 Sep 2007 23:10:18 -0000 1.7
***************
*** 72,76 ****
void sendReply(error_t error, storage_len_t len)
{
! SerialReplyPacket *srpkt = (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg);
if (error == SUCCESS) {
srpkt->error = SERIALMSG_SUCCESS;
--- 72,79 ----
void sendReply(error_t error, storage_len_t len)
{
! SerialReplyPacket *srpkt = (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg, sizeof(SerialReplyPacket));
! if (srpkt == NULL) {
! return;
! }
if (error == SUCCESS) {
srpkt->error = SERIALMSG_SUCCESS;
***************
*** 87,91 ****
{
if (state == S_READ) {
! SerialReplyPacket *serialMsg_payload = (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg);
if (buf == serialMsg_payload->data) {
state = S_IDLE;
--- 90,97 ----
{
if (state == S_READ) {
! SerialReplyPacket *serialMsg_payload = (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg, sizeof(SerialReplyPacket));
! if (serialMsg_payload == NULL) {
! return;
! }
if (buf == serialMsg_payload->data) {
state = S_IDLE;
***************
*** 104,108 ****
if (error == SUCCESS) {
! SerialReplyPacket *srpkt = (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg);
srpkt->data[1] = crc & 0xFF;
srpkt->data[0] = (crc >> 8) & 0xFF;
--- 110,117 ----
if (error == SUCCESS) {
! SerialReplyPacket *srpkt = (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg, sizeof(SerialReplyPacket));
! if (srpkt == NULL) {
! return;
! }
srpkt->data[1] = crc & 0xFF;
srpkt->data[0] = (crc >> 8) & 0xFF;
***************
*** 145,151 ****
SerialReqPacket *srpkt = (SerialReqPacket *)payload;
SerialReplyPacket *serialMsg_payload =
! (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg);
uint8_t img_num = 0xFF;
!
// Converts the image number that the user wants to the real image number
switch (srpkt->img_num) {
--- 154,163 ----
SerialReqPacket *srpkt = (SerialReqPacket *)payload;
SerialReplyPacket *serialMsg_payload =
! (SerialReplyPacket *)call SerialAMSender.getPayload(&serialMsg, sizeof(SerialReplyPacket));
uint8_t img_num = 0xFF;
!
! if (serialMsg_payload == NULL) {
! return msg;
! }
// Converts the image number that the user wants to the real image number
switch (srpkt->img_num) {
More information about the Tinyos-2-commits
mailing list