Revision 75cef49f mainbox/main.c

View differences:

mainbox/main.c
5 5
#include <strings.h>
6 6
#include <stdio.h>
7 7

  
8
#define SLEEP_MS 250
8
#define SLEEP_MS 10//250
9 9

  
10 10
static struct tool_t tools[] = {
11
  TOOL_DECL("testa", 4),
12
  TOOL_DECL("testb", 5)
11
  TOOL_DECL("test1", 1),
12
  TOOL_DECL("test2", 2),
13
  TOOL_DECL("test3", 3),
14
  TOOL_DECL("test4", 4),
15
  TOOL_DECL("test5", 5),
16
  TOOL_DECL("test6", 6),
17
  TOOL_DECL("test7", 7),
18
  TOOL_DECL("test8", 8),
19
  TOOL_DECL("test9", 9)
13 20
};
14 21

  
15 22
#define N_TOOLS (sizeof(tools)/sizeof(struct tool_t))
......
74 81
  i = 0;
75 82
  while (run) {
76 83
    tool_poll(&tools[i]);
84
    event_q_process();
77 85
    usleep(SLEEP_MS * (useconds_t)1000);
78 86
    i = (i+1) % N_TOOLS;
79 87
  }

Also available in: Unified diff