# mml2smf

> MML to Standard MIDI File converter

Latest version **0.3.1** (published 2020-02-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install mml2smf
pnpm add mml2smf
yarn add mml2smf
bun add mml2smf
```

Provides the command `mml2smf`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.3.1 |
| Published | 2020-02-19 |
| First published | 2015-08-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 81.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 24 |
| Author | Katsuomi Kobayashi |
| Maintainers | katsuomik |

## Links

- npm: https://www.npmjs.com/package/mml2smf
- Repository: https://github.com/korinVR/mml2smf
- Homepage: https://framesynthesis.com/
- Issues: https://github.com/korinVR/mml2smf/issues
- npm.io page: https://npm.io/package/mml2smf

## Dependencies (1)

- [minimist](https://npm.io/package/minimist.md) *

## Recent versions

- 0.3.1 (latest) — 2020-02-19
- 0.3.0 — 2020-02-18
- 0.2.1 — 2020-02-18
- 0.2.0 — 2020-02-18
- 0.0.11 — 2015-08-27
- 0.0.10 — 2015-08-19
- 0.0.9 — 2015-08-18
- 0.0.8 — 2015-08-14
- 0.0.7 — 2015-08-12
- 0.0.6 — 2015-08-12
- 0.0.5 — 2015-08-09
- 0.0.4 — 2015-08-07
- 0.0.3 — 2015-08-07
- 0.0.1 — 2015-08-07
- 0.0.0 — 2015-08-07

## README

# MML to Standard MIDI File converter

This utility is created for in-development MIDI synthesizer [synthesis.js](https://github.com/korinVR/synthesis.js), but it can be used for general use cases.

The features are very limited for now.

## Usage

### From command line

```bash
$ npm install -g mml2smf

$ mml2smf test.mml
$ mml2smf test.mml -o output.mid
$ mml2smf -m cdefg -o test.mid
$ mml2smf -m "t140 o5l8q7 ccggaag4 ffeeddc4; o4l8 cgegcgeg >b<gfg>b<gc4" -o test.mid
```

### From JavaScript

```js
var mml2smf = require("mml2smf");

var smf = mml2smf("cdefg"); // returns Uint8Array
```

## MML ([Music Macro Language](https://en.wikipedia.org/wiki/Music_Macro_Language))

command|MML
-------|---
Notes|c, d, e, f, g, a, b, +, -
Octave|o\[octave\], &lt;, &gt; (4)
Note Length|l\[note length\] (4)
Tempo|t\[tempo\]
Gate Time|q\[1-8\] (6)
Velocity|u\[0-127\] (100)
Channel Volume|v\[0-127\]
Pan|p\[-64-63\]
Expression Controller|E\[0-127\]
Program Change|@\[0-127\]
Control Change|B\[0-119\],\[0-127\]
Channel Aftertouch|D\[0-127\]
Key Shift|k\[-127-127\] (0)
Set MIDI Channel|C\[1-16\] (1)
Next Track and MIDI Channel|;
Tie|^
Comment|//..., /\*...\*/

## Development

To launch:

```bash
$ npm start
```

To test:

```bash
$ npm run test
```

# License

MIT

# Author

Katsuomi Kobayashi ([@korinVR](https://twitter.com/korinVR) / [@korinVR_en](https://twitter.com/korinVR_en))

https://framesynthesis.com/

---
_Source: https://npm.io/package/mml2smf · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
