Harman Logo
AUDIOWORX
  • Home
  • Documentation
  • Videos
  • Release Notes
  • Login
Harman Logo
AUDIOWORX
  • Home
  • Documentation
  • Videos
  • Release Notes
  • Login
Harman Logo
AUDIOWORX
  • Home
  • Documentation
  • Videos
  • Release Notes
  • Login
  • Getting Started
  • User Guides
  • Developer Guides

Table of Content

  • 20

Audio Object Developer Guide

  1. Purpose of this Document
  2. Overview
    1. Audio Object Workflow
    2. Audio Object Class
  3. Audio Object Configuration
    1. Design Time Configuration
      1. Metadata
    2. Advanced Design Time Configuration
      1. Audio Object Memory
  4. Basic Features and APIs
  5. Advanced Features and APIs
    1. Switch Processing State
    2. Debug and Monitoring
    3. Background Method
  6. Audio object Examples
    1. Example 1 - AwxAudioObjExt.cpp
    2. Example 2 - AwxAudioObjExtToolbox.cpp
    3. Example 3 - AwxAudioObjExtMemRecs.cpp
    4. Example 4 - AwxAudioObjExt.h
    5. Example 5 - AwxAudioObjExtToolbox.h
    6. Example 6 - AwxAudioObjExtMemRecs.h
  7. General Guidelines
  8. Adding External AO into AudioworX Package
  9. Building External Audio Object

Starter Kit Developer Guide

  1. Overview
  2. Setting Up the Developer Environment
  3. SKUtility Developer Options
  4. Build AWX External Object
  5. Running Debug Session

xAF Integration User Guide

  1. Support on xAF Integration

Troubleshooting

  1. GTT GUI Issues
  2. AmpSRV2
  3. Installation
  • Audio Object Developer Guide
  • Debug and Monitoring

5.2.Debug and Monitoring

A number of features are planned for debugging and monitoring but currently, live streaming is implemented and described below.

Live streaming of state variable or state memory

To enable live streaming for a particular state variable, below steps needs to be performed by the audio object.

1. The XML section of the state variable has to be updated to convey that state variable is streamable to GTT. The optional variable after the bit converter has to be set to true to enable the state variable streaming.
The code snippet from CTemplate::getXmlObjectTemplate function conveys to GTT that the state variable “State1Value” is enabled for streaming by setting the optional variable after bit converter to true.

2. For uploading data from framework to GTT, the following public functions have to overridden or implemented:

  • CAudioObject::getStateMemForLiveStreamingPtr
  • CAudioObject::getDataFormatForLiveStreamingPtr
CAudioObject::getStateMemForLiveStreamingPtr () take in 4 arguments representing streamIndext, subBlockId, pointer to hold memory address of the state variable (stateMem) and the number of the bytes to be streamed (len).

The streamIndext and subBlockId are passed into the audio object to enable the calculation of which channel of the state variable to be streamed. Based on the calculation done, the audio object has to update the variables stateMem and len.

The code snippet from CTemplate::getStateMemForLiveStreamingPtr shows the example implementation. In this example code, subblock is not used for state variable and hence subBlockId has to be always zero. The first state variable (with streamIndex 0) is mute which is not enabled for streaming in XML file. The state variables (streamIndext 1 to 6) is enabled for streaming in XML file and stateMem and len is updated.

The len argument of the function getStateMemForLiveStreamingPtr conveys that how many bytes are going to be streamed. If only one float value is going to be streamed then value for len is 4. If n number of float values need to be streamed, then variable len has to be 4 times n. Also, audio object has to make sure that len number of bytes are allocated for the state variable and the starting address is assigned to stateMem variable.

CAudioObject::getDataFormatForLiveStreamingPtr() take in 2 arguments representing streamIndext and subBlockId.

The streamIndext and subBlockId are passed into the audio object to return the data format of the state variable to be streamed.

The code snippet from CTemplate::getDataFormatForLiveStreamingPtr shows the example implementation. In this example code, subblock is not used for state variable and hence subBlockId has to be always zero. The first state variable (with streamIndex 0) is mute which is not enabled for streaming in XML file. The state variables (streamIndext 1 to 6) is enabled for streaming in XML file and the corresponding data format is returned from this function.

3. Data from framework to GTT is sent based on the value commands per second of the state variable which is sent from GTT.

The framework does the below calculation to decide on which call it needs to send data to GTT.

  • Number of blocks per second = SampleRate / BlockLength
  • Blocks per message = Number of blocks per second / commands per second

The amount of data to be send is based on the below calculation.

  • Bytes per message = Header size + len
    where

    • Header size is 5.
    • len is in bytes.

The framework sends Bytes per message amount of data to GTT for every Blocks per message.

Example #1:
SampleRate = 48000, BlockLength = 64, len = 4 and commands per second = 10

Number of blocks per second = 48000 / 64 = 750
Blocks per message = 750 / 10 = 75
Bytes per message = 5 + 4 = 9
The framework sends 9 bytes of data to GTT for every 75th block.
Bytes per second = (9 * 10) bytes per sec = 90 bytes per sec

Example #2:
SampleRate = 48000, BlockLength = 64, len = 128 and commands per second = 6

Number of blocks per second = 48000 / 64 = 750
Blocks per message = 750 / 6 = 125
Bytes per message = 5 + 128 = 133
The framework sends 133 bytes of data to GTT for every 125th block.
Bytes per second = (133 * 6) bytes per sec = 798 bytes per sec

« Switch Processing StateBackground Method »
Suggest Edit
  • Careers
  • Contact
  • Sitemap
  • News

© 2025 HARMAN International. All Rights Reserved. Privacy Policy | Cookies | Terms of Use

If you are using a screen reader and are having problems using this website, please call (800) 645-7484 for assistance.