38 #include <sys/select.h>
47 #include "dev/button-sensor.h"
48 #include "dev/pir-sensor.h"
49 #include "dev/vib-sensor.h"
51 PROCINIT(&etimer_process, &tcpip_process);
53 SENSORS(&pir_sensor, &vib_sensor, &button_sensor);
59 printf(
"Starting Contiki\n");
69 autostart_start(autostart_processes);
73 setvbuf(stdout, (
char *)
NULL, _IONBF, 0);
86 FD_SET(STDIN_FILENO, &fds);
87 if(select(1, &fds,
NULL,
NULL, &tv) < 0) {
89 }
else if(FD_ISSET(STDIN_FILENO, &fds)) {
91 if(read(STDIN_FILENO, &c, 1) > 0) {
92 serial_line_input_byte(c);
103 log_message(
char *m1,
char *m2)
105 printf(
"%s%s\n", m1, m2);