module ti.uia.sysbios.Adaptor |
 |
 |
Single core IServiceMgrSupport implementation
This module implements the IServiceMgrSupport interface
and is used by the ServiceMgr on single cores. This module
routes UIA data between the instrumentation host and the services
via the
Transport implementations. It maintains lists of
free events and contrl message buffers via BIOS Semaphores and Queues.
[
more ... ]
#include <ti/uia/sysbios/Adaptor.h>
Functions common to all IServiceMgrSupport modules |
Void | |
| |
Void | |
Bool | |
Void | |
Functions common to all target modules |
|
|
DETAILS
This module implements the IServiceMgrSupport interface
and is used by the ServiceMgr on single cores. This module
routes UIA data between the instrumentation host and the services
via the
Transport implementations. It maintains lists of
free events and contrl message buffers via BIOS Semaphores and Queues.
There is a Transfer Agent task (transferAgentTaskFxn). This task
sends data to the instrumentation host. This task uses the
ServiceMgr.transportFxns functions communicate to the host. These functions
are setup by default based on the device.
If
ti.uia.runtime.ServiceMgr.supportControl is true, this module
also creates the Receive Task (rxTaskFxn). The Receive Task receives
control messages from the instrumentation host via the
ServiceMgr.transportFxns functions. This task is not needed if no control
messages are coming from the host.
The majority of the configuration parameters are defined in the ServiceMgr.
For example, the
ti.uia.runtime.ServiceMgr.transferAgentPriority
dictates priority of the Adaptor's Transfer Agent task. Here is the list of
the ServiceMgr parameter used by the Adaptor module:
- numEventPacketBufs
- maxEventPacketSize
- transferAgentStackSection
- transferAgentStackSize
- transferAgentPriority
- supportControl
- maxCtrlPacketSize
- numIncomingCtrlPacketBufs
- numOutgoingCtrlPacketBufs
- rxTaskStackSize
- rxTaskStackSection
- rxTaskPriority
Adaptor_freePacket() // module-wide |
 |
Function called within ServiceMgr_freePacket
ARGUMENTS
packet
Pointer to a UIAPacket
DETAILS
This function can be used to return an unused packet back to the
module. It must only return packets that were obtained via
the
getFreePacket function.
Adaptor_getFreePacket() // module-wide |
 |
Function called within ServiceMgr_getFreePacket
ARGUMENTS
type
Requested type of packet
timeout
return after this many system time units
RETURNS
Point to the free UIA packet. NULL if not successful.
DETAILS
The service can specify what type of packet it wants with the
first parameter.
The function fills in the HdrType field of the packet automatically
for the service. All other fields are un-initialized.
Adaptor_requestEnergy() // module-wide |
 |
Function called within ServiceMgr_requestEnergy
Void Adaptor_requestEnergy(Int id);
ARGUMENTS
id
Id of the service
DETAILS
Generally services do not maintain an active thread. Services may
request the ServiceMgr module to call the
ProcessCallback
in the context of the transfer agent. This can be accomplished via
this function.
Adaptor_sendPacket() // module-wide |
 |
Function called within ServiceMgr_sendPacket
ARGUMENTS
packet
UIAPacket to be sent
RETURNS
TRUE denotes success and the packet is
no longer owned by the caller. FALSE denotes
failure and the packet is still owned by the caller.
DETAILS
All UIAPacket fields except for SenderAdrs must be filled in.
The caller loses ownership of the packet once it is successfully sent.
If this function fails, the caller still owns the packet.
Adaptor_setPeriod() // module-wide |
 |
Function called within ServiceMgr_setPeriod
Void Adaptor_setPeriod(Int id, UInt32 periodInMs);
ARGUMENTS
id
Service id of the service
periodInMs
Requested period in milliseconds
DETAILS
Services period should be a multiple of the ServiceMgr's period
(
periodInMs). If it is not, they will called at the rounded
up period. For example, if ServiceMgr.periodInMs = 100 and a service sets
its period to 250. That service will be called every 300 milliseconds.
Module-Wide Built-Ins |
 |
// Get this module's unique id
Bool Adaptor_Module_startupDone();
// Test if this module has completed startup
// The heap from which this module allocates memory
Bool Adaptor_Module_hasMask();
// Test whether this module has a diagnostics mask
Bits16 Adaptor_Module_getMask();
// Returns the diagnostics mask for this module
Void Adaptor_Module_setMask(Bits16 mask);
// Set the diagnostics mask for this module
var Adaptor = xdc.useModule('ti.uia.sysbios.Adaptor');
module-wide config parameters
module-wide functions
generated on Mon, 28 Jan 2013 17:45:49 GMT