;/*****************************************************************************/ ; OSasm.s: low-level OS commands, written in assembly */ ; Runs on LM4F120/TM4C123/MSP432 ; Lab 4 starter file ; March 25, 2016 ; AREA |.text|, CODE, READONLY, ALIGN=2 THUMB REQUIRE8 PRESERVE8 EXTERN RunPt ; currently running thread EXPORT StartOS EXPORT SysTick_Handler IMPORT Scheduler SysTick_Handler ; 1) Saves R0-R3,R12,LR,PC,PSR CPSID I ; 2) Prevent interrupt during switch ;YOU IMPLEMENT THIS (same as Lab 3) CPSIE I ; 9) tasks run with interrupts enabled BX LR ; 10) restore R0-R3,R12,LR,PC,PSR StartOS ;YOU IMPLEMENT THIS (same as Lab 3) CPSIE I ; Enable interrupts at processor level BX LR ; start first thread ALIGN END