A Svelte-based web app for validating Hapax instrument definition files.
Try it now at hapax-validator.maxhodges.com.
- Upload
.txt
files or paste text directly for validation. - Provides detailed validation results for:
- Version
- Track Name
- Port Configurations (Outport/Inport)
- Channels
- Drum Lanes
- CCs and NRPNs
- Copy validation results to the clipboard.
- Dark mode enabled by default.
The Hapax Instrument Definition File Validator helps ensure your instrument definition files are correctly formatted. This guide outlines common mistakes and how to avoid them.
- Issue:
VERSION
is commented out or missing. - Fix: Ensure the
VERSION
line is present and not commented. The line must look like this:
Bad:
# VERSION 1
Good:
VERSION 1
- Issue: Drum lanes are incomplete or not properly formatted.
- Fix: Each drum lane must be a single line with all fields:
ROW:TRIG:CHAN:NOTENUMBER NAME
.
Bad:
[DRUMLANES]
1:NULL:7 Kick
2:NULL:7:38 Snare
[/DRUMLANES]
Good:
[DRUMLANES]
1:NULL:7:36 Kick
2:NULL:7:38 Snare
[/DRUMLANES]
- Issue: Names contain unsupported characters.
- Fix: Use only alphanumeric characters, spaces,
_
,-
,+
,.
,/
,(
,)
,[
,]
.
Bad:
PORTA ON/OFF
Good:
PORTA_ON_OFF
- Issue: Empty sections like
[CC]
or[NRPN]
are left in the file. - Fix: Remove sections if not used.
Bad:
[CC]
[/CC]
Good: If unused, omit the entire section.
- Issue: Important lines are accidentally commented out with
#
. - Fix: Only use
#
for comments, and ensure required lines (e.g.,VERSION
,TRACKNAME
) are not preceded by#
.
Bad:
# TRACKNAME TR-909
Good:
TRACKNAME TR-909
- Issue:
NOTENUMBER
is missing or not within the valid range (0–127). - Fix: Ensure all drum lanes include a valid
NOTENUMBER
.
Bad:
1:NULL:7:NULL Kick
Good:
1:NULL:7:36 Kick
Before saving your file, verify:
VERSION
is present and not commented out.[DRUMLANES]
are formatted asROW:TRIG:CHAN:NOTENUMBER NAME
.- Names use valid characters.
- Remove unused sections like
[CC]
,[NRPN]
, etc. - No required lines are commented out.
VERSION 1
TRACKNAME TR-909
TYPE DRUM
OUTPORT A
OUTCHAN 7
INPORT NULL
INCHAN NULL
MAXRATE NULL
[DRUMLANES]
1:NULL:7:36 Kick
2:NULL:7:38 Snare
3:NULL:7:39 Clap
4:NULL:7:40 Rim
5:NULL:7:41 Chat
6:NULL:7:42 Ohat
7:NULL:7:43 Ride
8:NULL:7:44 Crash
[/DRUMLANES]
[COMMENT]
TR-909 instrument definition file
[/COMMENT]
This guide will help you avoid common mistakes and ensure your instrument definition files are correctly validated. Let us know if you have any questions or feedback!
This tool is provided as-is, with no guarantees about the correctness or completeness of its validation results. Use it at your own discretion, and always double-check critical configurations manually.
Have questions, suggestions, or feedback? Visit the GitHub repository to open an issue or contribute.
-
Fork the repo.
-
Create a feature branch:
git checkout -b feature-name