aboutsummaryrefslogtreecommitdiff
path: root/README.md
blob: 5fbec658aa0b17a3f1af8ad1076509e76df3ceb2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# MIDI Multicast

Broadcast and synthesise MIDI over UDP.  The advantage of a connectionless
protocol is that multiple servers and clients are easily supported, and the
clients can be started while the servers are off.

## Development

Run `nix develop` for a development environment.

Inside it, run `make`.  `src` must point to the source code, and `out` must
point to where the build artefacts should be placed.  For example:

```sh
make src=. out=bin
```

## Compilation

Run `nix build`.

## Options

Options are passed through environment variables.

### Common

- `MCAST_GROUP`: The UDP multicast address.
- `MCAST_PORT`: The UDP multicast port.
- `DEBUG`: Increase verbosity.

### Client

- `RELAY_DELAY`: The intended delay in milliseconds between the time a message
  is sent and played.  Increasing it reduces stuttering but increases latency.
  Both the client and server should have synchronised clocks.

- `SOUNDFONT`: The path to the sound font for synthesis.

### Server

- `MIDI_IN`: The name of the MIDI input in ALSA.