Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ematech/midi_const
Python MIDI constants.
https://github.com/ematech/midi_const
constants midi python
Last synced: 3 days ago
JSON representation
Python MIDI constants.
- Host: GitHub
- URL: https://github.com/ematech/midi_const
- Owner: EMATech
- License: other
- Created: 2023-07-22T19:59:11.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-11-08T06:26:45.000Z (about 1 year ago)
- Last Synced: 2024-12-08T02:19:52.175Z (26 days ago)
- Topics: constants, midi, python
- Language: Python
- Homepage: https://pypi.org/project/midi_const
- Size: 34.2 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
midi_const
==========Python MIDI constants
---------------------This very simple package provides useful constants derived from official
MIDI specifications available at:
- MIDI Association, ex MIDI Manufacturers Association (MMA) [US]:
https://midi.org
- Association of Musical Electronics Industry (AMEI) [JP]:
https://www.amei.or.jp/
- MIDI Standard Committee (MSC) [JP]:
http://amei.or.jp/midistandardcommittee### Status
Already covers most of the MIDI 1.0 Detailed Specification v4.2.1 from
February 1996.Other specifications will be added along the way.
Contributions welcome!
### License
To allow maximal re-usability, these constants are offered,
at your option, under any of the following licenses:
- CC0-1.0
- MIT (OSI and FSF compatible)
- Unlicense### Installation
```shell
pip install midi_const
```### Usage
Interactively:
```pycon
>>> import midi_const as midi>>> midi.STATUS_BYTES.get(0x80)
'Note Off'>>> midi.CONTROLLER_NUMBERS.get(7)
'Channel Volume'>>> midi.SMF_DEFAULT_TEMPO
500000.0>>> help(midi)
```
Within a program:```python
from midi_const import GENERAL_MIDI_SOUND_SET, GENERAL_MIDI_SOUND_SET_GROUPINGSindex = GENERAL_MIDI_SOUND_SET.index('Banjo')
# index = 105
group = GENERAL_MIDI_SOUND_SET_GROUPINGS.get(index)
# group = 'Ethnic'
```