Recently Written · git

sad

sad (2f30.org simple audio daemon) with a Cygwin/OSS port on branch cygwin

git clone https://github.com/equwal/sad

Log | Files | Refs


sad.1 (1859 bytes)

1 .Dd October 4, 2026
2 .Dt SAD 1
3 .Os
4 .Sh NAME
5 .Nm sad
6 .Nd simple audio daemon
7 .Sh SYNOPSIS
8 .Nm
9 .Op Fl f Ar sock
10 .Sh DESCRIPTION
11 .Nm
12 plays MP3, Ogg Vorbis and WAV files from a playlist.
13 Clients control it with line-based text commands over a
14 .Ux
15 domain socket.
16 Each reply ends with
17 .Ql OK
18 on success, or
19 .Ql ERR
20 and a message on failure.
21 .Sh OPTIONS
22 .Bl -tag -width Ds
23 .It Fl f Ar sock
24 Listen on
25 .Ar sock
26 instead of
27 .Pa /tmp/sad-sock .
28 .El
29 .Sh COMMANDS
30 .Bl -tag -width Ds
31 .It Cm add Ar path
32 Add
33 .Ar path
34 to the playlist.
35 .It Cm clear
36 Clear the playlist and stop playback.
37 .It Cm close
38 Close the client connection.
39 .It Cm disable Ar output
40 Disable the named output.
41 .It Cm enable Ar output
42 Enable the named output.
43 .It Cm kill
44 Stop the daemon.
45 .It Cm next
46 Play the next song.
47 .It Cm pause Op Cm 0 | 1
48 Pause or resume.
49 Toggle when no argument is given.
50 .It Cm ping
51 Reply with
52 .Ql pong .
53 .It Cm play Op Ar id
54 Play song
55 .Ar id ,
56 or the current song.
57 .It Cm playlist
58 Print the playlist as
59 .Ql id: path
60 lines.
61 .It Cm prev
62 Play the previous song.
63 .It Cm random
64 Set random playback mode.
65 .It Cm remove Op Ar id
66 Remove song
67 .Ar id ,
68 or the current song, from the playlist.
69 .It Cm repeat
70 Set repeat mode, the default: cycle through the playlist.
71 .It Cm status Op Ar state
72 Print
73 .Ql state: value
74 lines for
75 .Cm random , repeat , single , songid , playback
76 and
77 .Cm volume ,
78 or only for
79 .Ar state .
80 .It Cm stop
81 Stop playback.
82 .It Cm version
83 Print the protocol version.
84 .It Cm volume Ar 0-100
85 Set the volume of all outputs.
86 .It Cm wait Ar event
87 Reply with
88 .Ql event: name
89 when
90 .Ar event
91 fires.
92 .El
93 .Sh FILES
94 .Bl -tag -width Ds
95 .It Pa /tmp/sad-sock
96 Default socket.
97 .El
98 .Sh EXAMPLES
99 Start the daemon and queue a song:
100 .Bd -literal -offset indent
101 $ sad &
102 $ echo 'add /music/song.mp3' | nc -U /tmp/sad-sock
103 $ echo 'play' | nc -U /tmp/sad-sock
104 .Ed
105 .Sh SEE ALSO
106 .Xr nc 1 ,
107 .Xr sacc 1