]> oss.titaniummirror.com Git - tinyos-2.x.git/blobdiff - apps/tests/deluge/SerialBlink/BlinkC.nc
Match the serial byte with the led that is toggled.
[tinyos-2.x.git] / apps / tests / deluge / SerialBlink / BlinkC.nc
index ef32ef406541dac0c38d7c88292e252bb01ebc63..a14d5d489290c575f32f2ab8810d050615cde60d 100644 (file)
@@ -57,11 +57,11 @@ implementation
 
   event void Timer0.fired()
   {
-    char *payload = call AMSend.getPayload(&byte_msg);
+    char *payload = call AMSend.getPayload(&byte_msg, 1);
     dbg("BlinkC", "Timer 0 fired @ %s.\n", sim_time_string());
 #ifndef BLINK_REVERSE
-    call Leds.led1Toggle();
-    payload[0] = 1;
+    call Leds.led0Toggle();
+    payload[0] = 0;
 #else
     call Leds.led2Toggle();
     payload[0] = 2;