kernel_initialize. STMicroelectronics OS20
Advertisement
Advertisement
16.2 OS20 function descriptions 16 Alphabetical list of functions
kernel_initialize
Initialize for preemptive scheduling
Synopsis
#include <kernel.h> int kernel_initialize( void );
Arguments
None
Results
Returns 0 for success, -1 if an error occurs.
Errors
Failure is caused by insufficient space to create the necessary data structures.
Description kernel_initialize() must be called before any tasks are created. It creates and initializes the task and queue data structures.
After the structures are created the calling process is initialized as the root task in the system.
kernel_initialize() installs a default mutual exclusion for the C run-time system. This may be disabled if it is not required; see
Note: 1 On the ST20-C2, if this function is called at high priority, it returns executing at low priority.
This is a requirement for the correct functioning of the OS20 kernel.
2 This function may be called automatically if st20cc runtime os20 is specified when linking; see
Chapter 2: Getting started on page 9 . It is important that this function is not called
twice.
Callable from
Not applicable (must be called before scheduler starts).
See also
187
ADCS 7473749D
Download
Advertisement