UROS is micro real-time operating system designed for embedded system.
- ARM Cortex-M3 processor
- Stellaris LM3S6965 Evaluation Board (QEMU)
- Ubuntu 12.04 LTS (GNU/Linux 3.2.0-23-generic x86_64)
- binutils 2.26
- gcc 4.6.3
On the described environment above, compile and run can easily be executed by make
command.
$ make
$ make run
Some predefined sample tasks run at the same time. QEMU is executed with the -nographic
option and all outputs from UART is displayed on the standard output (console). QEMU can be stopped by pressing C-a x
.
This RTOS is begin developed to aim at being a minimal, simple and efficient kernel and the specification is based on OSEK/VDX.
The task task_id is moved from SUSPENDED state to READY state.
The calling task is moved into SUSPENDED state and the internal resources which the calling task has owned is released.
N/A
Resource management is essentially the same thing as mutex.
Resource res_id is allocated for the current task. Another task cannot get or release the resource until allocating task release it. If another task tries to get the resource, the task is enqueued into the wait list for this resource and moved to WAITING state.
Resource res_id is released by the current task. If the wait list for this resource is not empty, one of them are dequeued from the list and moved to READY state.
Event objects are assigned to each task and used to inform that events occured.
Event object which the task task_id has is ORed with the given event. If the result is matched with an event that the task is waiting for, the state of the task is changed to READY state.
Event object which the task task_id has is cleared by the given event.
Return the event which the task task_id has.
The wait event is set to the calling task and the task is moved to WAIT state and waits until any wait events arrive. If the wait event occurs, the task is moved to READY state and wait is cleared automatically.
Alarm objects manage time expiration. If it expires, it activates a task, set event to a task or executes call back routine. Each alarm is tied up a counter object which counts system timer ticks.
Return the alarm alarm_id information into alarm_base. Alarm_base contains maxallowedvalue, ticksperbase, mincycle.
- maxallowedvalue defines the maximum allowed counter value.
- ticksperbase defines the number of ticks required to reach a counter specific unit.
- mincycle defines the minimum allowed counter value for the cycle-parameter.
Return the relative value in ticks since previous expiration occured.
Set the relative alarm which expires after increment and every cycle count.
Set the absolute alarm which expires at start and every cycle count.
Stop alarm alarm_id.