Skip to content
This repository was archived by the owner on Aug 5, 2022. It is now read-only.

Commit e30d492

Browse files
tvyaskeerockl
authored andcommitted
doc: Documentation for AVB Streamhandler Systemd watchdog
Add the documentation to public/docs. Signed-off-by: Tarun Vyas <[email protected]>
1 parent bd3ac4e commit e30d492

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

public/doc/01_icd.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1275,6 +1275,47 @@ When starting the Stream Handler via *systemd* these variables are set by the se
12751275
![Figure: Sequence to create a transmit stream](./images/MSC_Avb_Control_Establish_Streams.png "Creating a network stream associated with a local source")
12761276
![Figure: Sequence to remove a transmit stream](./images/MSC_Avb_Control_Remove_Stream.png "Removing a network stream")
12771277

1278+
#################################################################################
1279+
@section watchdog Systemd Watchdog
1280+
#################################################################################
1281+
1282+
AVB streamhandler watchdog is built as a static library. Currently, 3
1283+
AVB streamhandler threads - Transmit sequencer, Alsa Worker and Receive
1284+
engine, register themselves with the watchdog manager. These can be
1285+
enabled by passing "-k watchdog.enable=1" to avb_streamhandler_demo.
1286+
1287+
Since we're relying on Systemd watchdog to reset AVB streamhandler
1288+
if any of the three threads stop resetting the watchdog timer, Systemd
1289+
will reset the AVB Stream handler service, so AVB streamhandler needs
1290+
to be run as a Systemd service. A sample Systemd service file is
1291+
described below.
1292+
1293+
* Systemd service file. Place this at /etc/systemd/system/avb.service
1294+
```
1295+
[Unit]
1296+
Description=AVBSH for watchdog testing
1297+
1298+
[Service]
1299+
Type=simple
1300+
Environment="LD_LIBRARY_PATH=$AVB_DEPS/lib/"
1301+
ExecStart=<path to your AVB SH build dir>/avb_streamhandler_demo -c -v -s
1302+
pluginias-media_transport-avb_configuration_reference.so setup --target
1303+
GrMrb -p MRB_Slave_Audio -n enp4s0 -k watchdog.enable=1
1304+
WatchdogSec=<timeout in seconds, so 30 for 30 seconds>
1305+
Restart=always
1306+
```
1307+
1308+
* Start/stop or check the status of the AVB streamhandler service with:
1309+
```
1310+
- sudo systemctl start avb.service
1311+
- sudo systemctl status avb.service
1312+
- sudo systemctl stop avb.service
1313+
```
1314+
1315+
* To view watchdog specific logs:
1316+
```
1317+
- sudo journalctl -fu avb.service | grep watchdog
1318+
```
12781319

12791320
#################################################################################
12801321
@section faq FAQ

0 commit comments

Comments
 (0)