1- In the leds-tdc example, we find that the orange led is really too bright. We could replace the 1k5 resistor with 4k7, but it might be possible to make it less "loud" without using the soldering iron. Make you proposal. Unfortunately there is no feasible solution for the orange led, but other pins are able to do that -- not the other leds, either, unfortunately. 3- Think about memory management in a microcontroller (malloc/free or lack thereof) and evaluate what would be the best approach and API. 3- Figure how to measure the WCET of a task. 4- Imagine you have problems with a PCB that you designed. The prototypes were good but production items (different manufacturerer) fail for thermal issues, and you feel with your finger that copper is thinner than the prototypes. You need to check that it the copper thickness is really 35um (and not, say, 20um). You can cut the PCB, actually you brought home a fragment (see a real sample of the device at http://hsw2020.gnudd.com/pcb-fragment.jpg). How would you measure the thickness of the copper? 5- Think about a filesystem for microcontrollers. The code must be as small as possible (4kB of machine code, or 2kB, or even 1kB if possible), we need to access files by name, write support is useful (but a filesystem without write support is better than no filesystem), and if we write we must respect the block-size of the hosting hardware (e.g. 32b/64b for eeprom or 64k/128k for bigger flash memory). How would you design the filesystem? 6- What is suboptimal in the "struct task" as it appears in the slides? Here it is again: struct task { char *name; void *arg; int (*init)(void *arg, struct task *t); int (*job)(void *arg, struct task *t); unsigned long nextrun, period; }; 7- What is the bug in the scheduler as it appears in the slides? Here it is again: while (1) { for (best = t = task_first; t < task_last; t++) if (time_before(t->nextrun, best->nextrun) best = t; while (time_before(jiffies, best->nexrun) ; best->job(best->arg, t); /* and possibly manage retval */ best->nextrun += best->period; /* BUG! */ }

8- Looking at lib/task.c and include/task.h, you'll find how I handle diagnostic messages (the "verbose" argument). It's bad in my opinion, can you make it better?