Features Documentation Examples Repository Blog Contact

Kernel API

This API provides access to all services of the CMRX RTOS and covers all callbacks CMRX might have into integrators’s code. This API is designed to be cross-platform compatible and from the userspace point of view, it is presented as functions that can be called.

For certain purposes, mainly for customization, CMRX might require integrator to provide some callbacks that CMRX can call. These callbacks are also cross-platform compatible and allow the integrator to customize some basic services such as clock source and power management.

Type Definitons

typedef uint8_t Thread_t

Data type used for thread IDs.

typedef uint8_t Process_t

Data type used for process IDs.

Macros

NULL

NULL is not a C name, rather than POSIX one. Introduce it here so we can have a named null pointer rather than a magic constant.


Interrupt Service Routines

Kernel services accessible from interrupt service handlers.

IRQ management

CMRX offers a tiny set of hardware-oriented services that allow manipulating the status of interrupt request lines.

Mutexes / Futexes

Basic synchronization primitives for use inside one process.

Named constants for errors

Types of errors system calls in CMRX can return.

Notifications

API for synchronization on shared objects.

Notify_flags

Flags that further specify the behavior of calls in notification group.

Remote Procedure Calls

API to perform calls that execute in foreign process.

Shared memory

API to declare memory as shared between two processes.

Signals

API for sending signals and handling incoming signals.

Standard API

API providing standardized access to various aspects required by userland.

Static initialization

Mechanisms provided for application designer to statically initialize objects.

Threading functions

Functions providing support for manipulation of system execution state.

Timers

API to interrupt, or periodically schedule execution of a thread.

Timing provider API

API providing clock source to the kernel.

64kB of protected memory ought to be enough for everyone.