Share via


Full-duplex Audio Playback Verification (Compact 7)

3/12/2014

The Full-duplex Audio Playback Verification test exercises waveform audio functionality for audio drivers. The test verifies that the driver can playback supported formats in full-duplex through the Waveform Audio application programming interface.

Test Prerequisites

Your device must meet the following requirements before you run this test.

The following tables show the hardware requirements for this test.

Requirement Description

Audio card

An audio card that supports full-duplex audio and is compatible with Windows Embedded Compact.

Keyboard

Needed for a device without a graphical user interface (GUI).

The following tables show the software requirements for this test.

Requirement Description

Tux.exe

Test harness, required for executing the test.

Kato.dll

Logging engine, required for logging test data.

Wavetest.dll

Test library.

At least 0.3 megabytes (MB) of free storage memory

If there is not sufficient space in the root directory of the target device, the test cannot run properly.

At least 1.0 MB of free program memory on the target device

If there is not sufficient program memory on the target device, the test cannot run properly.

SYSGEN_MININPUT and any dependencies

Images that are designed to work on a device without a graphical UI require SYSGEN_MININPUT and any dependencies therein to be present on the system. (This is the minimum requirement for Keyboard support which is needed to get the interactive user input from a device without a graphical GUI.)

In order for the Waveform Audio Driver Test to function correctly you must have included the waveform audio component, SYSGEN_AUDIO, as well as an audio driver in your OS build using BSP_WAVEDEV_<driver_name> or BSP_AUDIO_<driver_name>. Some board support packages (BSPs) include an audio driver by default.

Subtests

The table below lists the subtests included in this test.

SubTest ID Description

100

Build Verification Test.

Ensures that the functionality necessary for the test is present. Refer to the test result to determine the likely cause of failure. Warnings that affect the behavior of the test will also appear in this test case if appropriate. This test case can cause other test cases to be skipped if required functionality is not present. The available WaveOut and WaveIn device identifier and device names are displayed.

4000

Test Volume control.

Tests Boundary Cases for setting and getting the volume

4001

Test waveOutSetVolume & waveOutGetVolume.

Test exercises the waveOutSetVolume and waveOutGetVolumefunctions to verify that they produce the correct results when passed valid parameters, and respond appropriately otherwise.

2000

Playback Capabilities.

Displays the capabilities reported by the driver; lists the extended functions supported by the driver.

2001

Playback.

Plays a tone for all of the supported formats.

2002

Playback Notifications.

Plays audio using null, event, thread, function, and window callbacks that should be supported by the driver.

2003

Playback Using Extended Functions.

Plays changing extended functions such as pitch, rate and volume.

2004

Playback Buffer Freed During Playback.

Allocates buffer in the virtual address space of the calling process for playback and frees and releases this buffer while in playback.

2005

Playback Sample Rate Reporting.

Queries the waveOutOpen method to verify that it succeeds for all supported formats reported by the device driver and fails for all non-supported formats reported by the device driver.

2006

Playback Initial Latency.

Verifies that average initial latency of a single buffer playback of standard sine wave is within acceptable range.

2007

Playback Initial Latencies Series.

Verifies that average initial latency of a single buffer playback of standard sine wave is within acceptable range for varying play times. If wave format is not specified at command prompt then this test case will repeat for every wave format specified in the latency test table.

2008

Playback Interoperability.

Verifies that playSound and sndPlaySound properly parse/play valid wave files with optional embedded chunks.

6000

Playback Mixing.

Verifies playback of a series of overlapping tones for all common formats by launching a series of sound threads. It also supports an interactive command line option, which allows the user to monitor the test and fail it, if the sound quality is unacceptable.

1000

Easy Playback.

Exercises the PlaySound and sndPlaySound APIs on wave files in the Windows directory.

Setting Up the Test

The sound card or audio driver must be installed and active.

Running the Test

This test library can have one or more optional command line entries to change the behavior of the test. To specify the optional command-line entries to the test library, you must use the -c command line option. This option forces Tux to pass the specified string into the test library.

Note:Make sure you are reading the debug output, since that is where you will be prompted by text for an interactive user response.

The following table shows the optional command line parameters.

Command line parameter Description

"-i"

Forces the test to stop and prompt you for confirmation. You can run the test with this parameter to manually confirm that audio plays and records correctly.

"-h"

Run the tests on a device without a graphical UI. Prompts will be textual in the debug output. Interactive input will be entered through a keyboard attached to the device without a graphical user interface UI. This parameter is designed to be used with the -i parameter, thus allowing you to run the tests in interactive mode on the device. (The system must have at least SYSGEN_MININPUT level of input support present.)

"-d duration"

Sets the duration of the tone being played or captured for all test cases. Duration is given in units of seconds. The default value is 1 second.

"-e"

Enables half-duplex testing and disables sound output when capturing. You must supply your own sound into the microphone when the test attempts to record sound.

"-wo device_identifier"

Specifies which Wave Output device to test. If your device is not the first output device, use this parameter to specify which device must be tested. The default value is zero.

"-wi device_identifier"

Specifies which Wave Input device to test. If your device is not the first input device, use this parameter to specify which device must be tested. The default value is zero.

"-c path\filename"

Specifies the path and filename of the CSV file in which to output latency test results. The default is to not save the results. If you specify -c but do not specify path\filename then the result is stored in \release\audio_latency_test_results.csv. The default file extension is .CSV.

"-f d_f_c_b"

Specifies the latency test duration and wave characteristics. *d = playback/capture duration in milliseconds; default value is 1000. *f = the sample frequency; default value is 11025. *c = number of channels; default value is 1. *b = number of bits per sample, either 8 or 16; default value is 8.

"-v path\filename"

Saves the audio file created by the playback interoperability test. Default is to not save the file. If you specify -v but do not specify path\filename then the file will be saved as \release\WaveInterOp.wav. Default file extension is .WAV.

"-ao duration"

Sets the expected playtime allowance for playback test cases. Duration is given in units of milliseconds. If the test case takes more time than ‘expected playtime + allowance’ or less time than ‘expected playtime - allowance’ for playback, then the test case will fail. The default value is 200 milliseconds.

"-ai duration"

Sets the expected capture time allowance for capture test cases. Duration is given in units of milliseconds. If the test case takes more time than ‘expected capture time + allowance’ or less time than ‘expected capture time - allowance’ for capture, then the test case will fail. The default value is 200 milliseconds.

"-p"

Enables Power Management tests. By default, power management tests are skipped as not all systems support power management.

"-s duration"

Sets the sleep interval for CALLBACK_NULL for all of the test cases. Duration is given in units of milliseconds. The default value is 50 milliseconds.

"-t threads"

Sets the number of threads for audio stability tests. This parameter is used by playback and capture mixing test cases to stress the system by launching the number of threads. The default value is 9 threads. The maximum value you can specify is 40 threads.

"-?"

Shows a help message containing all the parameters and their descriptions.

Verifying the Test

When the test completes running, verify that "PASS" appears in the test log for all sub-tests

Troubleshooting the Test

The following table shows troubleshooting tips.

Item Solution

The Power Management Tests are skipping.

These tests will skip if the power manager is not present on the system.

The Capture Multiple Stream Tests are skipping.

These tests will skip if the device driver does not support multiple capture streams.

If the build verification test (test case 100) determines that required functionality is not present, it may skip other test cases.

For additional platform specific issues, consult the CTK articles on the TechNet wiki.

See Also

Other Resources

Audio Tests