Header
Hex Loc'n | Length (bytes) | Description | Data |
---|---|---|---|
00 | 4 | Identifier in ASCII 'FORM' | 46 4F 52 4D |
04 | 4 | (Total Filesize - 8 bytes) (Little Endian) | nn nn nn nn |
08 | 8 | String in ASCII - 'E5B0TOC2' | 45 35 42 30 54 4F 43 32 |
10 | 4 | 98 or ASCII char 'N' - a constant across ROM's | 00 00 00 4E |
14 | 4 | ASCII text of 'E5S1' | 45 35 53 31 |
18 | 4 | (Total Filesize - 18 bytes) (Little Endian) | nn nn nn nn |
1C | 4 | The value of 98 - This is uniform across ROM's | 00 00 00 62 |
20 | 2 | 2 values of 00 | 00 00 |
22 | 38 | Patch name in ASCII repeated - Pitch value in ASCII if applicable | |
48 | 26 | 26 instances of 00 bytes | |
62 | 4 | ASCII text value of 'E5S1' | 45 35 53 31 |
...??? | |||
70 | 38 | Copy of entry found at 22H (Patch name in ASCII) | |
...??? | |||
B4 | 4 | Value 1 (mono or stereo indicator)[1] | nn nn nn nn |
B8 | 4 | Value 2 (mono or stereo indicator)[2] | nn nn nn nn |
[1] [2]
If the 4 byte values in B4 and B8 are identical, the audio contained within is in mono
If the 4 byte values in B4 and B8 are different, the audio contained within is in stereo
Sample Rate
Hex Loc'n | Length (bytes) | Description | Data |
---|---|---|---|
D4 | 2 | Sample rate in kHz [3] (written in Big Endian order) | nn nn |
Sample rates will vary, especially amongst sounds from older synthesizers.
These
will not just be the usual standards of 44,100kHz, 22,500kHz etc, but will be non-standard in
many cases.
For example, in the Planet Phatt synth, these sample rates are used (26,980kHz, 22,221kHz, 31,919kHz, 17,000kHz etc...).
The newer synth models will have audio recorded at higher bit rates.
Audio Data
Raw audio data follows after the initial header, starting at byte 296 (128 in Hex)
Audio data continues until the end of the file unless the file has loop points.
The actual raw sound data used in the EBL file is exactly the same format as WAV pure audio data, although the channels for stereo are not interlaced. The audio data is 16 bit PCM, saved as little endian.
Each audio sample is made up of two bytes and can represent values between -32,768 to 32,767 (silence is represented as 0).
There will be an additional 42 bytes at the end of file if the audio file has loop points (Check for ASCII 'MARK' at (file end - 16 bytes)).
Loop Values if Present
If a file has loop settings, the last 42 bytes will be as follows:
Hex Loc'n | Length (bytes) | Description | Data |
---|---|---|---|
2 | 2 empty bytes | 00 00 | |
8 | ASCII value for text 'EXLZ' | 45 58 4C 5A 20 00 00 00 | |
4 | ASCII value for 'INFO' | 49 4E 46 4F | |
4 | 8 | 08 00 00 00 | |
4 | 1 | 01 00 00 00 | |
4 | 1 | 01 00 00 00 | |
4 | ASCII value for 'MARK' | 4D 41 52 4B | |
4 | 8 | 08 00 00 00 | |
4 | Loop start point in bytes (Big Endian) | nn nn nn nn | |
4 | Loop end point in bytes (Big Endian) | nn nn nn nn |
Format
The audio for stereo files in EBL format is not interlaced. It is one channel of raw audio
data followed by the second channel of raw audio data.
To grab just one audio channel(mono), divide the audio section length by two.
The actual raw sound data used in the EBL file is exactly the same format as WAV pure
audio data.
To hear a preview of the audio file, find the sample rate value at hex location D4.
You can then import the audio as raw data into an audio package, such as Audacity.
To import the raw data into Audacity, use the following settings:
Encoding: Signed 16bit PCM
Byte Order: Little Endian
Start Offset: 296 bytes
Channels: 1 Channel Mono
Amount to Import: 100%
Sample rate: (Use the value from file location D4)
You will notice some spikes at the end of the audio data if there are loop values included
in the EBL data.
To remove this, cut off the last 21 samples (42 bytes) in the audio editor.
Note that if the audio file is stereo, you will see the audio wave form is duplicated in the file.
You won't be able to fix this by importing the raw data into Audacity as stereo.
Considerations Converting to WAV format
In the EBL files, the patch name is found within the file from hex location 22. In many of
the files, the pitch value follows the patch name.
You'll need to remove the instances of '00' within the string.
It is advisable to save both the patch name and pitch value as the WAV file name.
Consider converting the pitch value to its MIDI equivalent into the WAV file, within a
sampler chunk('smpl').
The easiest way to do this would be by using a lookup table to convert the pitch name to
the corresponding MIDI value.
If you intend to use the files as samples to use in a DAW, it will save a lot of time if
you write the start and end loop values into the WAV file.
In many cases, this will allow the software to automatically bring in
the loop values when the file is imported into a software sampler, to save you from having
to find the loop points manually using trial and error.
Note that the converted WAV files that are meant to loop may click at the end if you play
the audio file back as one shot. This is because the audio file is meant to loop at the loop
points and not end abruptly.
If the EBL file you are converting is in stereo, you will need to write some code to interlace the audio data to retain the stereo data in a WAV format.
For more information on the WAV format, check out this link
Other Findings
There could be as little as one or two EBL files for a synth sound.
Some files may be extremely short if they are designed to loop.
You may find the odd typo in the patch description.
You may be surprised at how low the sample rates are for some sounds, though keep in mind that some of the samples used would have been recorded when memory was at a premium.
Polyphone is a piece of software, licensed under the GNU General Public Licence, which is useful for testing and setting audio loop points. This is handy for checking any conversion files you may have created. The software will also allow you to save a pitch setting into an audio file.
Although the software's main purpose is for creating soundfonts, it does have features for some editing and for exporting WAV files. The link for the software is here.