在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):bondagit/aes67-linux-daemon开源软件地址(OpenSource Url):https://github.com/bondagit/aes67-linux-daemon开源编程语言(OpenSource Language):C++ 76.5%开源软件介绍(OpenSource Introduction):AES67 Linux DaemonAES67 Linux Daemon is a Linux implementation of AES67 interoperability standard used to distribute and synchronize real time audio over Ethernet. See https://en.wikipedia.org/wiki/AES67 for additional info. IntroductionThe daemon is a Linux process that uses the Merging Technologies ALSA RAVENNA/AES67 Driver to handle PTP synchronization and RTP streams and exposes a REST interface for configuration and status monitoring. The ALSA AES67 Driver implements a virtual ALSA audio device that can be configured using Sources and Sinks and it's clocked using the PTP clock. A Source reads audio samples from the ALSA playback device and sends RTP packets to a configured multicast or unicast address. A Sink receives RTP packets from a specific multicast or unicast address and writes them to the ALSA capture device. A user can use the ALSA capture device to receive synchronized incoming audio samples from an RTP stream and the ALSA playback device to send synchronized audio samples to an RTP stream. The binding between a Source and the ALSA playback device is determined by the channels used during the playback and the configured Source channels map. The binding between a Sink and the ALSA capture device is determined by the channels used while recoding and the configured Sink channels map. The driver handles the PTP and RTP packets processing and acts as a PTP clock slave to synchronize with a master clock on the specified PTP domain. All the configured Sources and Sinks are synchronized using the same PTP clock. The daemon communicates with the driver for control, configuration and status monitoring only by using netlink sockets. The daemon implements a REST interface to configure and monitor the Sources, the Sinks and PTP slave. See README for additional info. It also implements SAP sources discovery and advertisement compatible with AES67 standard and mDNS sources discovery and advertisement compatible with Ravenna standard. A WebUI is provided to allow daemon and driver configuration and monitoring. The WebUI uses the daemon REST API and exposes all the supported configuration paramaters for the daemon, the PTP slave clock, the Sources and the Sinks. The WebUI can also be used to monitor the PTP slave status and the Sinks status and to browse the remote SAP and mDNS sources. LicenseAES67 daemon and the WebUI are licensed under GNU GPL. The daemon uses the following open source:
Devices and interoperability testsSee Devices and interoperability tests with the AES67 daemon AES67 USB Receiver and TransmitterSee Use your board as AES67 USB Receiver and Transmitter Repository contentdaemon directoryThis directory contains the AES67 daemon source code. The daemon can be cross-compiled for multiple platforms and implements the following functionalities:
The directory also contains the daemon regression tests in the tests subdirectory. See the README file in this directory for additional information about the AES67 daemon configuration and the HTTP REST API. webui directoryThis directory contains the AES67 daemon WebUI configuration implemented using React. With the WebUI a user can do the following operations:
3rdparty directoryThis directory is used to download the 3rdparty open source. The aes67-daemon branch of ravenna-alsa-lkm repository contains the ALSA RAVENNA/AES67 module code plus all the patches applied to it. The ALSA RAVENNA/AES67 kernel module is responsible for:
The following patches have been applied to the original module:
See ALSA RAVENNA/AES67 Driver README for additional information about the Merging Technologies module and for proper Linux Kernel configuration and tuning. test directoryThis directory contains the files used to run the daemon platform compatibility test on the network loopback interface. The test is described below. PrerequisiteThe daemon and the test have been tested with Ubuntu 18.04 distro on ARMv7 and with Ubuntu 18.04, 19.10 and 20.04 distros on x86 using:
The following ARM platform have been used for testing: The BeagleBone® Black board with ARM Cortex-A8 32-Bit processor. See Ubuntu 18.04 on BeagleBone® Black for additional information about how to setup Ubuntu on this board. The NanoPi NEO2 with Allwinner H5, Quad-core 64-bit high-performance Cortex A53 processor. See Armbian NanoPi NEO2 for additional information about how to setup Ubuntu on this board. The ubuntu-packages.sh script can be used to install all the packages required to compile and run the AES67 daemon, and the platform compatibility test. Important PulseAudio must be disabled or uninstalled for the daemon to work properly, see PulseAudio and scripts notes. How to buildMake sure you have all the required packages installed, see prerequisite. To compile the AES67 daemon and the WebUI you can use the build.sh script, see script notes. The script performs the following operations:
Run the platform compatibility testBefore attempting to use the AES67 daemon on a specific host or board it's highly recommended to run the platform test. The platform test runs a playback and recording of an RTP session on the loopback network device using the ALSA RAVENNA/AES67 modules and checks that no audio samples get corrupted or lost. This test can be executed using the run_test.sh script. See script notes. The script allows a user to test a specific configuration and it can be used to ensure that the daemon will be able to operate smoothly with such config on the current platform.
For example to test the typical AES67 configuration run:
The test performs the following operations:
If the test result is OK it means that the selected configuration can run smoothly on your platform. If the test reports a failure you may try to stop all the possible additional loads running on the host and repeat it. If after this the test fails systematically it means you cannot achieve a good reliability with the specified configuration. In this case you may try to configure a different driver timer basic tick period in the daemon configuration file (parameter tic_frame_size_at_1fs in test/daemon.conf). By default this parameter is set to 48 (1ms latency) and the valid range is from 48 to 480 with steps of 48. Note that higher values of this parameter (values above 48) lead to higher packets processing latency and this breaks the compatibility with certain devices. Run the platform latency testThe platform latency test can be used to measure the minimum end-to-end latency that can be achieved on a specific platform. The test is based on the same setup used for the platform compatibility test where a Sink is configured to receive audio samples from a Source both running on the same device using the network loopback interface. A test application plays audio samples on the RAVENNA playback device and measures the time till the samples are received on the RAVENNA capture device. The test setup and the end-to-end latency measured are shown in the picture below: The test can be executed using the run_latency_test.sh script. See script notes. The script allows a user to test the latency on a specific configuration and it can be used to ensure that a specific ALSA buffer size can be used:
The specified buffer size in frames starts from tic_frame_size_at_1fs * 2 (128 by default) in steps of tic_frame_size_at_1fs. For example, to test the typical AES67 configuration for 1 minute and a buffer size of 128 frames run:
If no underrun errors occurred during the test the requested buffer size can be used and the end-to-end latency measured is printed at the end:
The previous test was run on a NanoPi NEO2 board with Ubuntu distro. In case underrun happened the status reported is:
and the specified buffer size cannot be used. Run the daemon regression testsTo run daemon regression tests install the ALSA RAVENNA/AES67 kernel module with:
setup the kernel parameters with:
make sure that no instances of the aes67-daemon are running, enter the tests subdirectory and run:
NOTE: when running regression tests make sure that no other Ravenna mDNS sources are advertised on the network because this will affect the results. Regression tests run on loopback interface but Avahi ignores the interface parameter set and will forward to the daemon the sources found on all network interfaces. Notes
|
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论