{"id":17771286,"url":"https://github.com/lue-bird/elm-midi","last_synced_at":"2025-06-22T05:06:38.966Z","repository":{"id":165909117,"uuid":"640991689","full_name":"lue-bird/elm-midi","owner":"lue-bird","description":"midi bytes parser","archived":false,"fork":false,"pushed_at":"2023-05-21T10:20:33.000Z","size":68,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-17T01:49:28.510Z","etag":null,"topics":["bytes","bytes-parser","elm","file","midi","music"],"latest_commit_sha":null,"homepage":"https://dark.elm.dmy.fr/packages/lue-bird/elm-midi/latest/","language":"Elm","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lue-bird.png","metadata":{"files":{"readme":"README.md","changelog":"changes.md","contributing":"contributing.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-15T14:46:40.000Z","updated_at":"2023-07-16T16:32:08.000Z","dependencies_parsed_at":"2024-10-26T21:56:08.619Z","dependency_job_id":"6c5820d8-d211-480f-9bc8-bcaf66528eae","html_url":"https://github.com/lue-bird/elm-midi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/lue-bird/elm-midi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-midi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-midi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-midi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-midi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lue-bird","download_url":"https://codeload.github.com/lue-bird/elm-midi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lue-bird%2Felm-midi/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261238910,"owners_count":23128882,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bytes","bytes-parser","elm","file","midi","music"],"created_at":"2024-10-26T21:31:18.062Z","updated_at":"2025-06-22T05:06:33.955Z","avatar_url":"https://github.com/lue-bird.png","language":"Elm","funding_links":[],"categories":[],"sub_categories":[],"readme":"## still TODO\n\n  - implement running status (ugh)\n\n## [elm midi](https://dark.elm.dmy.fr/packages/lue-bird/elm-midi/latest/)\n\na bytes parser for MIDI (`.mid`) files.\n\nSome ideas on what you can use this for:\n  - creating an animations for a song\n  - creating a rhythm game\n  - analyzing a song\n  - visualizing a song, e.g. in guitar tabs\n  - transforming a song to instructions that produce certain sounds. Watch this: https://www.youtube.com/watch/4rcnu8j1Xqk\n  - playing a song 🧠\n  - ...\n\nA basic example for parsing a selected file using\n  - [`File.Select.file`](https://dark.elm.dmy.fr/packages/elm/file/latest/File-Select#file)\n  - [`File.toBytes`](https://dark.elm.dmy.fr/packages/elm/file/latest/File#toBytes)\n  - [`Bytes.Parser.run`](https://dark.elm.dmy.fr/packages/zwilias/elm-bytes-parser/latest/Bytes-Parser#run)\n\n```elm\nupdate event =\n    case event of\n        MidiFileSelectClicked -\u003e\n            \\state -\u003e\n                ( state\n                , File.Select.file [ \"audio/midi\" ] MidiFileSelected\n                )\n\n        MidiFileSelected midiFile -\u003e\n            \\state -\u003e\n                ( state\n                , midiFile |\u003e File.toBytes |\u003e Task.perform SelectedMidiFileBytesReceived\n                )\n\n        SelectedMidiFileBytesReceived midiFileBytes -\u003e\n            \\state -\u003e\n                ( { state\n                    | midi =\n                        midiFileBytes\n                            |\u003e Bytes.Parser.run Midi.file\n                  }\n                , Cmd.none\n                )\n```\n→ [complete example](https://github.com/lue-bird/elm-midi/tree/master/example)\n\n## not supported\n\n- encoding\n\n## created with the help of\n\n  - [this summary sheet](https://www.music.mcgill.ca/~ich/classes/mumt306/StandardMIDIfileformat.html)\n  - [this wonderful wiki](https://www.recordingblogs.com/wiki/musical-instrument-digital-interface-midi)\n  - [this spec for all messages](http://midi.teragonaudio.com/tech/midispec.htm) and [this spec for general info about the format and some details](http://midi.teragonaudio.com/tech/midifile.htm)\n  - [these (old) midi.org reference tables](https://www.midi.org/specifications-old/category/reference-tables)\n  - [this blog for a few message explanations](https://web.archive.org/web/20090117232701/http://eamusic.dartmouth.edu/~wowem/hardware/midi.html)\n  - [the german wikipedia page for context and all events](https://de.wikipedia.org/wiki/MIDI) (for some reason the English version omits the specific events)\n\nsample midi files for testing\n  - [colxi/midi-parser-js](https://github.com/colxi/midi-parser-js)\n  - [davidluzgouveia/midi-parser](https://github.com/davidluzgouveia/midi-parser)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flue-bird%2Felm-midi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flue-bird%2Felm-midi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flue-bird%2Felm-midi/lists"}