module ti.sysbios.knl.Idle

Idle Thread Manager

The Idle module is used to specify a list of functions to be called when no other tasks are running in the system. [ more ... ]
C synopsis target-domain sourced in ti/sysbios/knl/Idle.xdc
DETAILS
The Idle module is used to specify a list of functions to be called when no other tasks are running in the system.
If tasking is enabled (ie BIOS.taskEnabled = true), then the Task module will create an "Idle task" with the lowest possible priority. When no other tasks are running, this idle task runs in an infinite loop, calling the list of functions specified by the Idle module.
If tasking is disabled (ie BIOS.taskEnabled = false), then the idle functions are called in an infinite loop within the BIOS_start function called within main().
The list of idle functions is only statically configurable; it cannot be modified at runtime.
 
typedef Idle_FuncPtr

Idle function type definition

C synopsis target-domain
typedef Void (*Idle_FuncPtr)();
 
 
Idle_run()  // module-wide

Make one pass through idle functions

C synopsis target-domain
Void Idle_run();
 
DETAILS
This function is called repeatedly by the Idle task when the Idle task has been enabled in the Task module (see Task.enableIdleTask).
This function makes one pass through an internal static array of functions made up of functions added using the Idle.addFunc() API as well as any functions defined in the GUI tool's Idle.idleFxns[] array.
This function returns after all functions have been executed one time.
SEE
Module-Wide Built-Ins

C synopsis target-domain
Types_ModuleId Idle_Module_id();
// Get this module's unique id
 
Bool Idle_Module_startupDone();
// Test if this module has completed startup
 
IHeap_Handle Idle_Module_heap();
// The heap from which this module allocates memory
 
Bool Idle_Module_hasMask();
// Test whether this module has a diagnostics mask
 
Bits16 Idle_Module_getMask();
// Returns the diagnostics mask for this module
 
Void Idle_Module_setMask(Bits16 mask);
// Set the diagnostics mask for this module
 
Configuration settings sourced in ti/sysbios/knl/Idle.xdc
var Idle = xdc.useModule('ti.sysbios.knl.Idle');
module-wide constants & types
    var obj = new Idle.ModuleView// ;
        obj.index = UInt  ...
        obj.coreId = UInt  ...
        obj.fxn = String  ...
module-wide config parameters
        null,
        null,
        null,
        null,
        null,
        null,
        null,
        null
    ];
module-wide functions
 
 
metaonly struct Idle.ModuleView
Configuration settings
var obj = new Idle.ModuleView;
 
    obj.index = UInt  ...
    obj.coreId = UInt  ...
    obj.fxn = String  ...
 
 
metaonly config Idle.common$  // module-wide

Common module configuration parameters

Configuration settings
Idle.common$ = Types.Common$ undefined;
 
DETAILS
All modules have this configuration parameter. Its name contains the '$' character to ensure it does not conflict with configuration parameters declared by the module. This allows new configuration parameters to be added in the future without any chance of breaking existing modules.
 
metaonly config Idle.idleFxns  // module-wide

Functions to be called when no other Tasks are running

Configuration settings
Idle.idleFxns = Idle.FuncPtr[length] [
    null,
    null,
    null,
    null,
    null,
    null,
    null,
    null
];
 
DETAILS
Functions added to the Idle.idleFxns[] array, as well as those added via the Idle.addFunc() API will be run by the Idle loop.
NOTE
This array is intended for use by the GUI config tool.
Config script authors are encourged to use the Idle.addFunc() API to add idle functions to their applications.
 
metaonly Idle.addCoreFunc()  // module-wide

Statically add a core-unique function to the Idle function list

Configuration settings
Idle.addCoreFunc(Void(*)() func, UInt coreId) returns Void
 
 
metaonly Idle.addFunc()  // module-wide

Statically add a function to the Idle function list

Configuration settings
Idle.addFunc(Void(*)() func) returns Void
 
DETAILS
Functions added to the Idle function list are called repeatedly by the Idle task function.
Usage example:
  var Idle = xdc.useModule('ti.sysbios.knl.Idle');
  Idle.addFunc('&myIdleFunc'); // add myIdleFunc() 
SEE
NOTE
Idle functions have the following signature:
  Void func(Void);
generated on Thu, 23 May 2019 00:22:13 GMT