Editing OS Configuration
The operating system (OS) is the core software layer that manages the hardware and system resources required by all other software components. It ensures efficient memory allocation, controls task scheduling, and maintains the integrity and isolation of each software module. By coordinating these functions, the OS provides a stable and predictable environment for applications and basic software to run reliably.
Adding OS Cores
The OS cores represent the physical cores that are available. It’s possible to configure in what way the core is executed, what task scheduler uses and the OS application among other things.
To add a new OS core, right-click on OS cores and then press Add. Clicking on an OS core open a new window in which you can configure the selected OS core’s various parameters, such as its core stacks and cross-core API call channels.
Adding OS Applications
OS applications are collections of OS objects that are required for an OS to function properly. It is possible to configure which functional objects (like tasks, alarms etc.) belong together by assigning them to an OS application, which can be done through the editor.
To add a new OS application, right-click on OS Applications and then press Add. Click on the OS application to open a window which lets you configure various parameters related to it. You can also expand the OS application and you’ll be presented with further components that can be managed.
Here you can define your API of trusted functions for the selected OS application. Right-click on Trusted Functions and then press Add to add a new trusted function. Clicking on a trusted function opens up a new window where you can configure its signature.
This container operate similarily to the Trusted Functions container, with one key difference: it holds the non-trusted functions. Additionally, in the configuration window, you can adjust the stack size for a non-trusted function—a setting that is not available for trusted functions.
Just as you can define Tasks, ISRs, Alarms, Counters and Schedule Tables for your project, you can do the same for specific OS applications. See the corresponding section on those components to learn more. Note that those components are added the same way, only that you right-click the corresponding subcontainer of your OS application to add and configure them.
Adding Tasks
Tasks are the basic functional objects that performs some form of calculation with possible side effects. All tasks that are available can be viewed in the editor, where it’s also possible to add more tasks to the list.
To add a new task, right-click on Tasks and then press Add. If you click on a task, you can configure it in the new window that appears.
This container allows you to toggle whether the selected task runs at system start up or not by checking/unchecking the checkbox next to it. If you expand this container, you can add which mode this task starts up in.
This container allows you to configure various parameters related to timing protection. The checkbox next to it toggles whether to use this functionality for the selected task or not. It’s also possible to add resource locks here, which is located under its subcontainer, Resource Locks.
Define Interrupt Service Routines
Interrupt Service Routines (ISR) are routines that can interrupt currently executing tasks in order to execute itself instead. In the editor, it is possible to define new ISRs and change various metadata parameters related to their runtime execution.
If you click on an existing ISR, you can change its parameters in a new window. If you want to add resource locks, for example, this is located under .
The checkboxes next to Cross-core channel receiver interrupt and Timing Protection Enabled toggles whether the respective function is enabled for the selected ISR.
Define Events
Events are signals emitted by user-specified tasks. When an event is raised, another extended task may execute. What they mean depends on the task that emits it and the user who defined it.
To add an event, right-click on Events and then click on Add.
Activate Alarms
Alarms can fire once or be set to fire continuously at a set interval. When the alarm activates, an event is raised. In the editor, it’s possible to configure which task is executed and which event is raised when the alarm is activated. Other parameters related to the alarm can be configured as well, such as when the alarm is activated. Note that the alarm has to reference a counter, since the counter defines the time unit which the alarm uses to know when to activate. The counter can be configured in the editor as well.
Configuring the automatic timing of the alarm is done under the Autostart button, which also can be enabled/disabled here.
Adding Counters
Counters keep track of time according to some algorithm. In the editor it’s possible to define counters and different parameters for each, such as:
-
The algorithm
-
Maximum tick value
-
How often to tick
-
And more
To add a new counter, right-click on Counters and press Add. If you click on your new counter, you’ll see a new window with various parameters that can be changed. To set a new driver, for example, you can expand the Driver window. You can also click the arrow next to it to get a list of options available, such duplicating drivers.
Create Schedule Tables
Schedule tables can be used to encapsulate alarms in a way that avoids synchronization issues like race conditions.
To create a schedule table, right-click Schedule Tables in the editor and then click on Add. In your new table, you can see its child, Expiry Points, which contains the points at which the OS activates tasks and/or sets events.
To add a new expiry point:
-
Right-click on Expiry Points and click Add
-
Clicking on an expiry point in the editor opens up a new window in which you can set:
-
Events are triggered by scheduler at the expiry point
-
Tasks are activated
-
Resources
Resource objects are used to manage concurrent access by tasks to a shared resource, such as a memory area. These handle synchronization issues such as race conditions via resource locks.
To add a new resource, right-click Resources in the editor and then click on Add.
Adding Spin Locks
As opposed to resources which provide shared access to shared resources between tasks on the same core, a spin lock offers this access to shared resources between tasks on different cores.
To add a new spin lock, right-click Spin Locks in the editor and then click on Add. If you click on the spin lock, you can configure its parameters, such as which application(s) uses it.
Create Inter OS Application Communicator
IOCs are used for managing the communication between software parts that are located on different OS applications.
In the editor, you can create new IOCs by clicking on IOC, then right-clicking on IOC Communication and press Add. In the new window, you can select the properties of the sending and receiving software parts on different OS applications. It’s also possible to configure the properties of the actual data being sent here.
Memory Protection
Here it is possible to configure various protection parameters for memory areas in the project.
There are 3 types of regions that can be configured:
-
Memory regions
-
Access check regions
-
Peripheral regions
To view the various types of regions, expand the Memory Protection folder.
A memory region defines one region of protection in memory.
To add a new memory region:
-
Right-click on Memory Regions and then press Add
-
Clicking on the new region to change parameters
-
Specify where the region is located and how big it is
-
Specify to which core or system the memory region applies.
-
You can specify a region of memory which verifies that whoever accesses it has the rights to do so.
To add a new access check region:
-
Right-click on Access Check Regions and press Add
-
Clicking on the new region to change parameters
-
Configure access rights
-
Configure which tasks have access to it
-
In a peripheral region, there may be registers reserved for control registers of a certain external device, such as a timer.
To add a new peripheral region:
-
Right-click on Peripheral Regions and then press Add
-
Clicking on the new region to change parameters
-
Configure the region’s end and start addresses
-
Configure which applications may access the peripheral region
-