]> oss.titaniummirror.com Git - tinyos-2.x.git/commitdiff
Bug fix for problem noted by David Moss. The radio does not switch
authorjwhui <jwhui>
Wed, 17 Jan 2007 05:14:18 +0000 (05:14 +0000)
committerjwhui <jwhui>
Wed, 17 Jan 2007 05:14:18 +0000 (05:14 +0000)
frequencies until either (i) transmitting a packet or (ii) turning off
then on receive mode. The fix is to turn off then on receive mode.

tos/chips/cc2420/CC2420ControlP.nc

index 639fc9c1f7e61a4657e97329d5a56934604feacb..38464cb4b3375e50877a5c390652bcc5ce977e7f 100644 (file)
@@ -266,10 +266,14 @@ implementation {
     }
 
     call CSN.clr();
+    call SRFOFF.strobe();
     call FSCTRL.write( ( 1 << CC2420_FSCTRL_LOCK_THR ) |
                       ( ( (channel - 11)*5+357 ) << CC2420_FSCTRL_FREQ ) );
     call PANID.write( 0, (uint8_t*)id, sizeof( id ) );
     call CSN.set();
+    call CSN.clr();
+    call SRXON.strobe();
+    call CSN.set();
     call SyncResource.release();
     
     post syncDone_task();