Ask AI
Skip to content

Event Module

Notice: Pre-Release Documentation
This document is part of a prerelease and is currently a work in progress. Some content may be incomplete, subject to change, or marked as TBD. We are actively updating this documentation and will continue to provide the most accurate and up-to-date information as development progresses. Thank you for your understanding!

The Event module is a standard Audio Weaver feature which was introduced in AWECore version D-8.D.2.6. The Event module is part of the signal flow and in AWE-Q generates events which are sent to the high-level OS (HLOS). Applications running on the HLOS can register for events and act upon them. Possible uses for the Event module include notifying when:

  • A wake word was triggered
  • CPU exceeds a specified percentage
  • A smooth gain change in the system has been completed
  • etc.

An example showing how to use the Event module to signal trigger word detection is shown below. The Event module has a Trigger pin and a Payload pin. The Payload pin can hold up to 64 samples of data.

Event Module Used With Trigger Word Figure 1. Event module used inconjunction with a trigger word module.

Please see the Audio Weaver Event module documentation to understand how the module is used in your signalflow. This section describes AWE-Q specific implementation details.

The Event module uses BSP callbacks to transfer events from the audio processor up to the HLOS. In AWE-Q, each processing core has its own event queue, and all Event modules on the same core write into the same queue. If you system uses 3 DSPs and the Arm processor then there are a total of 4 separate event queues.

The event queues live in shared memory and are configured to hold a total of 64 events. An application running on the HLOS registers for an event using a TBD command syntax. When an event is received, an application supplied callback will be called.

Dedicated BSP Events

In addition to the Event Module events, there is certain information to be transmitted to HLOS outside of signal flow processing. This includes indications about certain operating states of AWE core, so that HLOS (i.e. AWE Controller) can correctly work.

The transportation of the AWE system events uses the same mechanism as the Event module propagation. These BSP Events are entered into the 64 element queue which is located in shared memory.

The HLOS / AWE Controller does not need to subscribe to these kind of events. They are intrinsically enabled, as the system will not work without. The following events are automatically sent:

  • CPU Overload (eventType = 10000)

  • AweCorePumping(PAC). Event sent when the early audio system has booted and starts pumping audio. We anticipate that this event will be ignored since the HLOS is not yet ready

  • AweCoreInitialized(Arm). Event sent when the Arm has initialized its AWECore instance and before it has loaded its AWB.

  • AweCorePumping(Arm). Event sent by Arm after it has loaded its AWB file and is pumping.