module ti.uia.events.UIAMessage |
 |
 |
 |
UIA Message Events
The UIAMessage module defines events that allow
tooling to monitor messages between tasks and CPUs.
[
more ... ]
#include <ti/uia/events/UIAMessage.h>
Functions common to all target modules |
|
|
Constants |
| |
| |
| |
| |
DETAILS
The UIAMessage module defines events that allow
tooling to monitor messages between tasks and CPUs.
The generation of UIAMessage events is controlled by a module's diagnostics
mask, which is described in details in
xdc.runtime.Diags.
UIAMessage info events are generated only when the Diags.INFO bit is set
in the module's diagnostics mask.
The following configuration script demonstrates how to enable use of
UIAMessage events within an application. The Diags.INFO bitmust be explicitly set
in order to enable these events.
This is part of the XDC configuration file for the application:
var UIAMessage = xdc.useModule('ti.uia.events.UIAMessage');
var Diags = xdc.useModule('xdc.runtime.Diags');
var LoggerSys = xdc.useModule('xdc.runtime.LoggerSys');
var Defaults = xdc.useModule('xdc.runtime.Defaults');
var logger = LoggerSys.create();
Defaults.common$.logger = logger;
Defaults.common$.diags_INFO = Diags.ALWAYS_ON;
Example 2: The following example configures a module to support logging
of STATUS events and INFO events, but defers the actual activation and deactivation of the
logging until runtime. See the
Diags_setMask()
function for details on specifying the control string.
This is a part of the XDC configuration file for the application:
var UIAMessage = xdc.useModule('ti.uia.events.UIAMessage');
var Diags = xdc.useModule('xdc.runtime.Diags');
var Mod = xdc.useModule('my.pkg.Mod');
Mod.common$.diags_STATUS = Diags.RUNTIME_OFF;
Mod.common$.diags_INFO = Diags.RUNTIME_OFF;
This is a part of the C code for the application:
// turn on logging of STATUS events (S) and INFO events (F)
// in the module
Diags_setMask("my.pkg.Mod+SF");
// turn off logging of STATUS events and INFO events in the module
Diags_setMask("my.pkg.Mod-SF");
config UIAMessage_msgReceived // module-wide |
 |
Message Received event
extern const Log_Event UIAMessage_msgReceived;
VALUES
NumBytes
length of the message in bytes
Flags
any flags associated with the message
MsgId
the message ID for the message
Destination ProcID
the procID for the message destination
Reply ProcID
the procID that the reply will be sent to
Source ProcID
the procID of the message sender
HeapId
the HeapID associated with the message
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write7(UIAMessage_msgReceived, numBytes,flags,msgId,destProcId,replyProcId,srcProcId,heapId);
...
"Msg Received [NumBytes]0x32 [Flags]0xF [MsgId]0x8357 [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgReceived event
config UIAMessage_msgSent // module-wide |
 |
Message Sent event
VALUES
NumBytes
length of the message in bytes
Flags
any flags associated with the message
MsgId
the message ID for the message
Destination ProcID
the procID for the message destination
Reply ProcID
the procID that the reply will be sent to
Source ProcID
the procID of the message sender
HeapId
the HeapID associated with the message
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write7(UIAMessage_msgSent, numBytes,flags,msgId,destProcId,replyProcId,srcProcId,heapId);
...
"Msg Sent [NumBytes]0x32 [Flags]0xF [MsgId]0x8357 [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgSent event
config UIAMessage_replyReceived // module-wide |
 |
Reply Received event
extern const Log_Event UIAMessage_replyReceived;
VALUES
MsgId
the message ID for the message
ReplyId
the reply's message ID
NumBytes
length of the message in bytes
Sender ProcID
the procID that the reply will be sent to
Destination ProcID
the procID for the message destination
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write5(UIAMessage_replyReceived,msgId,replyId,numBytes,senderProcId,destProcId);
...
"Msg Sent [MsgId]0x8357 [NumBytes]0x32 [Flags]0xF [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgSent event
config UIAMessage_replySent // module-wide |
 |
Reply Sent event
VALUES
NumBytes
length of the message in bytes
Flags
any flags associated with the message
MsgId
the message ID for the message
Destination ProcID
the procID for the message destination
Reply ProcID
the procID that the reply will be sent to
Source ProcID
the procID of the message sender
HeapId
the HeapID associated with the message
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write7(UIAMessage_replySent, numBytes,flags,msgId,destProcId,replyProcId,srcProcId,heapId);
...
"Reply Sent [NumBytes]0x32 [Flags]0xF [MsgId]0x8357 [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgSent event
Module-Wide Built-Ins |
 |
// Get this module's unique id
Bool UIAMessage_Module_startupDone();
// Test if this module has completed startup
// The heap from which this module allocates memory
Bool UIAMessage_Module_hasMask();
// Test whether this module has a diagnostics mask
Bits16 UIAMessage_Module_getMask();
// Returns the diagnostics mask for this module
Void UIAMessage_Module_setMask(Bits16 mask);
// Set the diagnostics mask for this module
var UIAMessage = xdc.useModule('ti.uia.events.UIAMessage');
module-wide config parameters
msg: "Msg Received [NumBytes]0x%x [Flags]0x%x [MsgId]0x%x [Dest(ProcID)]0x%x [Reply(ProcID)]0x%x [Src(ProcID)]0x%x [HeapId]0x%x"
};
msg: "Msg Sent [NumBytes]0x%x [Flags]0x%x [MsgId]0x%x [Dest(ProcID)]0x%x [Reply(ProcID)]0x%x [Src(ProcID)]0x%x [HeapId]0x%x"
};
msg: "Reply Recieved [MsgId]0x%x [ReplyId]0x%x [NumBytes]0x%x [Sender]0x%x [Dest]0x%x "
};
msg: "Reply Sent [NumBytes]0x%x [Flags]0x%x [MsgId]0x%x [Dest(ProcID)]0x%x [Reply(ProcID)]0x%x [Src(ProcID)]0x%x [HeapId]0x%x"
};
config UIAMessage.msgReceived // module-wide |
 |
Message Received event
msg: "Msg Received [NumBytes]0x%x [Flags]0x%x [MsgId]0x%x [Dest(ProcID)]0x%x [Reply(ProcID)]0x%x [Src(ProcID)]0x%x [HeapId]0x%x"
};
VALUES
NumBytes
length of the message in bytes
Flags
any flags associated with the message
MsgId
the message ID for the message
Destination ProcID
the procID for the message destination
Reply ProcID
the procID that the reply will be sent to
Source ProcID
the procID of the message sender
HeapId
the HeapID associated with the message
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write7(UIAMessage_msgReceived, numBytes,flags,msgId,destProcId,replyProcId,srcProcId,heapId);
...
"Msg Received [NumBytes]0x32 [Flags]0xF [MsgId]0x8357 [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgReceived event
C SYNOPSIS
config UIAMessage.msgSent // module-wide |
 |
Message Sent event
msg: "Msg Sent [NumBytes]0x%x [Flags]0x%x [MsgId]0x%x [Dest(ProcID)]0x%x [Reply(ProcID)]0x%x [Src(ProcID)]0x%x [HeapId]0x%x"
};
VALUES
NumBytes
length of the message in bytes
Flags
any flags associated with the message
MsgId
the message ID for the message
Destination ProcID
the procID for the message destination
Reply ProcID
the procID that the reply will be sent to
Source ProcID
the procID of the message sender
HeapId
the HeapID associated with the message
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write7(UIAMessage_msgSent, numBytes,flags,msgId,destProcId,replyProcId,srcProcId,heapId);
...
"Msg Sent [NumBytes]0x32 [Flags]0xF [MsgId]0x8357 [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgSent event
C SYNOPSIS
config UIAMessage.replyReceived // module-wide |
 |
Reply Received event
msg: "Reply Recieved [MsgId]0x%x [ReplyId]0x%x [NumBytes]0x%x [Sender]0x%x [Dest]0x%x "
};
VALUES
MsgId
the message ID for the message
ReplyId
the reply's message ID
NumBytes
length of the message in bytes
Sender ProcID
the procID that the reply will be sent to
Destination ProcID
the procID for the message destination
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write5(UIAMessage_replyReceived,msgId,replyId,numBytes,senderProcId,destProcId);
...
"Msg Sent [MsgId]0x8357 [NumBytes]0x32 [Flags]0xF [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgSent event
C SYNOPSIS
config UIAMessage.replySent // module-wide |
 |
Reply Sent event
msg: "Reply Sent [NumBytes]0x%x [Flags]0x%x [MsgId]0x%x [Dest(ProcID)]0x%x [Reply(ProcID)]0x%x [Src(ProcID)]0x%x [HeapId]0x%x"
};
VALUES
NumBytes
length of the message in bytes
Flags
any flags associated with the message
MsgId
the message ID for the message
Destination ProcID
the procID for the message destination
Reply ProcID
the procID that the reply will be sent to
Source ProcID
the procID of the message sender
HeapId
the HeapID associated with the message
DETAILS
#include <xdc/runtime/Log.h>
#include <ti/uia/events/UIAMessage.h>
...
Log_write7(UIAMessage_replySent, numBytes,flags,msgId,destProcId,replyProcId,srcProcId,heapId);
...
"Reply Sent [NumBytes]0x32 [Flags]0xF [MsgId]0x8357 [Dest(ProcID)]0x2 [Reply(ProcID)]0x3 [Src(ProcID)]0x1 [HeapId]0x56"
EXAMPLE
The following C code shows how to log a msgSent event
C SYNOPSIS
metaonly config UIAMessage.common$ // module-wide |
 |
Common module configuration parameters
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.
generated on Tue, 14 Feb 2017 00:15:09 GMT