<< to CrossControl homepage

Support & Service Center

Playing audio files on an CCpilot

Printer-friendly versionPrinter-friendly versionPDF versionPDF version

A number of CCpilot units have a stero audio output which can be used for playing audio files, like for example notification sounds or spoken text messages.

To play such an audio file, the system command "aplay" can be used like this:

aplay filename.wav

Aplay does not decode mp3-files, so you must use wav files. See the online documentation for aplay for more information and command line switches.


In order to change the volume, you should use the amixer command like this:

amixer sset Playback 140

Resonable volume settings are between 100 and 200 on the CCpilot units. See the online documentation for amixer for more information and command line switches.


Attached you even find an example application for CoDeSys with a very simple GUI for playing an audio file and changing the volume using system command calls. Attached is even a simple audio .wav-file which should be placed in the /opt folder on the unit in order to use the example program.