Barebones scheduler for Cortex-M3