Skip to content

Commit

Permalink
hero1 systemd service for external speaker
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthijsBurgh committed Jul 6, 2024
1 parent ffeaaca commit b816a70
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
15 changes: 15 additions & 0 deletions scripts/services/hero1-demo/hero1-demo-external-speaker.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[Unit]
Description=Set the external speaker as the default
After=pulseaudio.service
Requires=pulseaudio.service
StartLimitIntervalSec=35
StartLimitBurst=30

[Install]
WantedBy=multi-user.target

[Service]
User=administrator
Restart=on-failure
RestartSec=1
ExecStart=/bin/bash -c '/usr/bin/pactl set-default-sink alsa_output.usb-C-Media_Electronics_Inc._USB_PnP_Sound_Device-00.analog-stereo'
15 changes: 15 additions & 0 deletions scripts/services/hero1/hero1-external-speaker.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[Unit]
Description=Set the external speaker as the default
After=pulseaudio.service
Requires=pulseaudio.service
StartLimitIntervalSec=35
StartLimitBurst=30

[Install]
WantedBy=multi-user.target

[Service]
User=administrator
Restart=on-failure
RestartSec=1
ExecStart=/bin/bash -c '/usr/bin/pactl set-default-sink alsa_output.usb-C-Media_Electronics_Inc._USB_PnP_Sound_Device-00.analog-stereo'

0 comments on commit b816a70

Please sign in to comment.