aboutsummaryrefslogtreecommitdiff
path: root/kernel/ctrl.c
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2011-11-02 02:54:40 +0000
committerDimitri Sokolyuk <demon@dim13.org>2011-11-02 02:54:40 +0000
commit87dd379c89dbe9b63dd3ab0f20f002a20d789c47 (patch)
treeafc0c66c7641377fd5228fd5a6aee5b35dc99a24 /kernel/ctrl.c
parente754d6f8f1288fa3ae5032ef675f35268a484c79 (diff)
major update: lot of bugfixes, lot of changes
- let compiler handle stack pointer arithmetic: switch to 16bit - improve update(): deadline depends on incremental release - resolve timing issues, new time convertion macros - major simplification of scheduler, most of garbage removed - new overflow interrupt for cycle counter, resolves also timing problems - simplify pwm generation, lookup tables are deferred, switch to 4bit - add blocking on shared values - remove garbage in lcd module and some bugfixes - add alternative reboot command to uart command interpreter - KISS
Diffstat (limited to 'kernel/ctrl.c')
-rw-r--r--kernel/ctrl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/ctrl.c b/kernel/ctrl.c
index 3becb49..720002e 100644
--- a/kernel/ctrl.c
+++ b/kernel/ctrl.c
@@ -26,15 +26,15 @@ ctrl(void *arg)
{
struct ctrlarg *a = arg;
- update(0, MSEC(500));
+ update(now(), MSEC(500));
for (;;) {
- sprintf(a->lcd->first, "the time is now:");
+ sprintf(a->lcd->first, "%8lx", now());
sprintf(a->lcd->second, "%4d:%.2d:%.2d:%.2d",
a->clock->d,
a->clock->h,
a->clock->m,
a->clock->s);
- sleep(SOFT, MSEC(500));
+ update(MSEC(500), MSEC(750));
}
}