Static initialization

These mechanisms are provided, so that various structures are generated into application image. These replace need to call os routines manually. Currently it is possible to statically initialize processes and threads.

Function-like Macros

VTABLE

CMRX only allows remote procedure calls to objects whose vtable pointers point to structures that are considered VTable definitions.

Mark every VTABLE structure instance with this macro to make it work for remote procedure calls.

OS_APPLICATION_MMIO_RANGE(application, from, to)

This macro allows to define a range of addresses accessible by the application code. Typical use is when user-space drivers are given access to certain address range where a peripheral resides.

OS_APPLICATION_MMIO_RANGES(application, from, to, from2, to2)

This macro allows to define a range of addresses accessible by the application code. Typical use is when user-space drivers are given access to certain address range where a peripheral resides.

This macro differs from OS_APPLICATION_MMIO_RANGE

OS_APPLICATION(application)

This will create userspace process entry in process table. Process is used to contain information on MPU configuration all threads bound to this process can use.

OS_THREAD_CREATE(application, entrypoint, data, priority, core)

Use this to automatically create thread upon kernel start. With this you don’t need to call thread_create()

application name of process/application you want to bind your thread to.

entrypoint entrypoint function name. This function will be given control once thread starts.

data user-defined data passed to entrypoint function.

priority thread priority of newly created thread

← Standard API Threading functions →