instantiated file-description and fixed style

This commit is contained in:
joxe 2010-02-02 21:41:54 +00:00
parent 09c3ba2753
commit 97b7a9a209

View file

@ -28,12 +28,13 @@
* *
* This file is part of the Contiki operating system. * This file is part of the Contiki operating system.
* *
* $Id: test-button.c,v 1.4 2010/02/02 21:17:32 joxe Exp $ * $Id: test-button.c,v 1.5 2010/02/02 21:41:54 joxe Exp $
*/ */
/** /**
* \file * \file
* A brief description of what this file is. * An example of how to use the button and light sensor on
* the Tmote Sky platform.
* \author * \author
* Adam Dunkels <adam@sics.se> * Adam Dunkels <adam@sics.se>
*/ */
@ -58,7 +59,7 @@ PROCESS_THREAD(test_button_process, ev, data)
PROCESS_WAIT_EVENT_UNTIL(ev == sensors_event && PROCESS_WAIT_EVENT_UNTIL(ev == sensors_event &&
data == &button_sensor); data == &button_sensor);
leds_toggle(LEDS_ALL); leds_toggle(LEDS_ALL);
if (!active) { if(!active) {
/* activate light sensor */ /* activate light sensor */
SENSORS_ACTIVATE(light_sensor); SENSORS_ACTIVATE(light_sensor);
printf("Light: %d\n", light_sensor.value(0)); printf("Light: %d\n", light_sensor.value(0));