projects
/
bertos.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add reg definition for adc driver.
[bertos.git]
/
bertos
/
drv
/
kbd.c
diff --git
a/bertos/drv/kbd.c
b/bertos/drv/kbd.c
index b36a5a4801c0806103cc2895eec84424e8e4c9cc..fc6232c7a40d0c96229a588ace82fb075752c3c2 100644
(file)
--- a/
bertos/drv/kbd.c
+++ b/
bertos/drv/kbd.c
@@
-33,7
+33,6
@@
*
* \brief Keyboard driver (implementation)
*
*
* \brief Keyboard driver (implementation)
*
- * \version $Id$
*
* \author Bernie Innocenti <bernie@codewiz.org>
* \author Stefano Fedrigo <aleph@develer.com>
*
* \author Bernie Innocenti <bernie@codewiz.org>
* \author Stefano Fedrigo <aleph@develer.com>
@@
-154,7
+153,7
@@
static void kbd_softint(UNUSED_ARG(iptr_t, arg))
timer_add(&kbd_timer);
}
timer_add(&kbd_timer);
}
-#else
+#else
#error "Define keyboard poll method"
#endif /* CONFIG_KBD_POLL */
#error "Define keyboard poll method"
#endif /* CONFIG_KBD_POLL */
@@
-177,10
+176,11
@@
keymask_t kbd_peek(void)
{
keymask_t key = 0;
{
keymask_t key = 0;
-// FIXME: make it optional
+#if CONFIG_KBD_SCHED
/* Let other tasks run for a while */
extern void schedule(void);
schedule();
/* Let other tasks run for a while */
extern void schedule(void);
schedule();
+#endif
/* Extract an event from the keyboard buffer */
IRQ_DISABLE;
/* Extract an event from the keyboard buffer */
IRQ_DISABLE;
@@
-236,7
+236,7
@@
void kbd_addHandler(struct KbdHandler *handler)
KbdHandler *node;
List *list;
KbdHandler *node;
List *list;
- cpuflags_t flags;
+ cpu
_
flags_t flags;
IRQ_SAVE_DISABLE(flags);
/* Choose between raw and coocked handlers list */
IRQ_SAVE_DISABLE(flags);
/* Choose between raw and coocked handlers list */
@@
-473,7
+473,7
@@
void kbd_init(void)
MOD_CHECK(timer);
/* Add kbd handler to soft timers list */
MOD_CHECK(timer);
/* Add kbd handler to soft timers list */
- event_initSoft
I
nt(&kbd_timer.expire, kbd_softint, NULL);
+ event_initSoft
i
nt(&kbd_timer.expire, kbd_softint, NULL);
timer_setDelay(&kbd_timer, ms_to_ticks(KBD_CHECK_INTERVAL));
timer_add(&kbd_timer);
timer_setDelay(&kbd_timer, ms_to_ticks(KBD_CHECK_INTERVAL));
timer_add(&kbd_timer);