Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
connorslade committed Nov 26, 2023
1 parent 50daa6c commit 6a8eee0
Showing 1 changed file with 40 additions and 3 deletions.
43 changes: 40 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,52 @@
# makey-midi [![Build](https://github.com/Basicprogrammer10/makey-midi/actions/workflows/rust.yml/badge.svg)](https://github.com/Basicprogrammer10/makey-midi/actions/workflows/rust.yml)

Lets you use a [Makey Makey](https://makeymakey.com) to send midi commands!
When run, this program will load the config file and create a virtual midi out port named 'makey-midi'.
Pressing the keys defined in the config file will then send their respective note values.
When run, this program will load the config file and either create a virtual midi output port or connect to another midi device.
Pressing the keyboard keys defined in the config file will then send their respective note values.

> [!NOTE]
> You may want to consider [remapping](https://makeymakey.com/pages/remap) your Makey Makey so you can make use of the click button and so any arrow key inputs don't mess with any synth you have open.
## Usage

After installing, there are two main ways to run the application.
To connect to an existing midi device or create a new virtual output port.
When creating an output port, no further configuration is needed and the device name will be 'makey-midi' (`makey-midi create`).
When connecting to an existing port, you can specify the name of the port or leave it blank to automatically pick one (`makey-midi connect [name]`).

The config parameter allows you to specify a path of the [config file](#config) that contains the key map.
Omitting this will default to `config.toml` in the current directory.
The debug flag will log what keys are pressed to the console (Ex: `Key pressed: UpArrow`).
Below is the output of running `makey-midi --help`.

```plain
Usage: makey-midi [OPTIONS] <COMMAND>
Commands:
connect Connects to a MIDI device to send events to
create Creates a new virtual MIDI output device. Only works on Linux.
list Lists all available MIDI devices. For use with the `connect` subcommand
help Print this message or the help of the given subcommand(s)
Options:
-c, --config <CONFIG> The location of the config file. Defaults to `config.toml` in the current directory
-d, --debug Logs each key event to stdout
-h, --help Print help
```

Here is an example command.
This will load the default config file, enable debug output, and connect to the (pretty bad) built-in midi synth in windows.

```shell
makey-midi --debug connect "Microsoft GS Wavetable Synth"
```

## Config

Below is an example `config.toml` file.
The `channel` defined what channel the midi events are sent on.
The `keymap` is the main part where you map keyboard keys to midi notes.
A list of all possible key values is in the dropdown below and a table of midi notes can be found [here](https://www.inspiredacoustics.com/en/MIDI_note_numbers_and_center_frequencies).
A list of all possible key values is in the dropdown below, and a table of midi notes can be found [here](https://www.inspiredacoustics.com/en/MIDI_note_numbers_and_center_frequencies).

```toml
channel = 0
Expand Down

0 comments on commit 6a8eee0

Please sign in to comment.