Logging Your Own CeLog Events (Windows CE 5.0)
The Windows CE kernel and coredll use CeLog to log a set of predefined operating system events as they occur. By viewing these events, you can analyze a variety of details about the operation of your system.
However, you might find that you wish to increase the amount of information you receive by creating and logging custom events. Viewing these custom events and observing their relationship to the operating system events that CeLog already records, can help you expand your understanding of how your OAL, drivers or applications operate and interact with other parts of the system.
Each event in the log consists of an event type identifier and a buffer of data whose contents are defined by the event type. For example, a thread switch event has the identifier CELID_THREAD_SWITCH and a data buffer that contains the CEL_THREAD_SWITCH structure. This structure further describes the thread switch event by identifying the specific thread to which the system switched.
You can easily log events in your code using basic event IDs and data structures that are pre-defined by the system for your use. Alternatively, you can define your own event IDs and use your own data structures to describe events.
The following sections provide the information you need to log custom events and view them with the CeLog viewing tools.
In this section
- Logging Events Using Pre-Defined Data Types
Describes how to log your own events using basic data types that are defined by the OS for your use. - Capturing Events with Custom Data Structures
Describes how to log your own events using custom data types that you define. - Logging Call Stacks with CeLog
Provides information on recording the call stack of the current thread with your own event. - Using Flags with Your Events
Describes how to use flags to add additional information that further identifies the events that you log.
Related sections
- CeLog Event Tracking Reference
Provides detailed reference information about the functions, macros, and data types needed to customize the CeLog tools. - CeLog Tool Customization
Provides guidelines for customizing CeLog tools, and for implementing your own event-tracking library.
Send Feedback on this topic to the authors