stmhal: Add os module with a few basic functions.