Jump to content
mdmayfield

BIG THANKS to Line 6 for using text for the .hlx format

Recommended Posts

That makes me really happy. I just saved a TON of time, effort, and frustration, by manually editing .hlx files in a text editor.

 

Text files are ideal, since they enable advanced editing by people who want to dive that deep, but they don't get in the way of anybody who doesn't care about the technical details.

 

(Please please please don't change it to an opaque proprietary binary format in the future....)

  • Upvote 6

Share this post


Link to post
Share on other sites

Oh yes!!  

I didn't even think about looking into those files.

It's JSON format, it will be easy to parse and edit outside Helix.

 

Thanks for the heads up mdmayfield!

Share this post


Link to post
Share on other sites

Yes thank for the heads-up on this.
 
A Sample for those interested:

.......
"block3" : {
 "@bypassvolume" : 1.0,
 "@enabled" : true,
 "@model" : "HD2_AmpSoloLeadCrunch",
 "@path" : 1,
 "@position" : 7,
 "@type" : 1,
 "Bass" : 0.660,
 "Bias" : 0.650,
 "BiasX" : 0.50,
 "ChVol" : 0.510,
 "Drive" : 0.640,
 "Hum" : 0.50,
 "Master" : 0.720,
 "Mid" : 0.450,
 "Presence" : 0.670,
 "Ripple" : 0.50,
 "Sag" : 0.390,
 "Treble" : 0.660
},
.........
  • Upvote 2

Share this post


Link to post
Share on other sites

I was eagerly looking for something letting in on something undocumented, in the files, but unfortunately they seem to contain all but just what you'd expect.... :)

Share this post


Link to post
Share on other sites

Looks like JSON to me, which does make a lot of sense as:

 

"JSON (JavaScript Object Notation) is a lightweight data-interchange format. It is easy for humans to read and write. It is easy for machines to parse and generate."

Share this post


Link to post
Share on other sites

Confirmed it's JSON.

 

Also, Setlist file (*.hls) and Bundle file (*.hlb) are 'base 64' encoded compressed (zlib) of JSON data as well.

I've made this little Python app to dump the content of a Bundle file called "Bundle_VERSION_1_03.hlb":

I'll come up with another Python to dump in a more formatted fashion way.

#!/usr/bin/env python

import json
from pprint import pprint
import base64
import zlib

data = None
compress_data = None
data_bundle = None

with open('Bundle_VERSION_1_03.hlb') as file_bundle:
        data = json.load(file_bundle)

if 'encoded_data' in data:
        compress_data = base64.b64decode(data['encoded_data'])
        bundle = zlib.decompress(compress_data)

        data_bundle = json.loads(bundle)
        pprint(data_bundle)

I'm not able to attached the full dump that the above app created, it's about 58000 lines.
But here is the first few lines of the Python structure:

 

{u'setlists': [{u'meta': {u'name': u'FACTORY 1'},
                u'presets': [{u'device': 2162689,
                              u'device_version': 16973856,
                              u'meta': {u'build_sha': u'3600857',
                                        u'name': u'US Double Nrm'},
                              u'tone': {u'controllers': {u'@expPedal2': [{u'@dsp': 0,
                                                                          u'@group': u'block1',
                                                                          u'@max': 1.0,
                                                                          u'@min': 0.0,
                                                                          u'@param': u'Pedal'}]},
                                        u'dsp0': {u'block0': {u'@enabled': False,
                                                              u'@model': u'HD2_Looper',
                                                              u'@path': 0,
                                                              u'@position': 7,
                                                              u'@stereo': False,
                                                              u'@type': 6,
                                                              u'Overdub': 0.0,
                                                              u'Playback': 0.0,
                                                              u'highCut': 20000.0,
                                                              u'lowCut': 20.0},
                                                  u'block1': {u'@enabled': True,
                                                              u'@model': u'HD2_VolPanVol',
                                                              u'@path': 0,
                                                              u'@position': 0,
                                                              u'@stereo': False,
                                                              u'@type': 0,
                                                              u'Pedal': 1.0,
                                                              u'VolumeTaper': False},
                                                  u'block2': {u'@enabled': False,
                                                              u'@model': u'HD2_CompressorRedSqueeze',

Share this post


Link to post
Share on other sites

Color switch value table
 

See table below for color value of the "@ledcolor" parameter:

 "@fs3" : [
     {
      "@dsp" : 0,
      "@enabled" : false,
      "@group" : "block4",
      "@label" : "Scream 808",
      "@ledcolor" : 525824,
      "@momentary" : false,
      "@type" : 1
     }
 1037		Blue (dimmed)
 3334		Turquoise (dimmed)
 13055		Blue
 65408		Only for Volume Pedal, not sure if this being used
 67840		Green (dimmed)
 196619		Violet (dimmed)
 458496		Green
 462860		White (dimmed)
 525824		Light Orange (dimmed)
 527360		Yellow (dimmed)
 786434		Red (dimmed)
 1049600	Dark Orange (dimmed)
 3277055	Violet
 7077838	White (another dimmed) for multi FS assignment...
 8716032	Yellow
 13676288	Light Orange
 16723200	Dark Orange
 16711683	Red
  • Upvote 2

Share this post


Link to post
Share on other sites

Those colour numbers are basically standard 24-bit computer colour values. So, if you know how to generate hex RGB codes for web design, you can generate such a code, convert it to decimal, and probably use it in here.

Share this post


Link to post
Share on other sites

I'm not able to attached the full dump that the above app created, it's about 58000 lines.

 

But here is the first few lines of the Python structure:
 

 

Perhaps you could post it up on GitHub and post a link here?   I'd love to help!

Share this post


Link to post
Share on other sites

Yep - try these number in HEX instead - much easier.  i.e., Their RED( 16711683) is 0xFF0003 - which is 255 for the red componend, 0 for the blue and 3 for the blue component.    WHen you get the hang of it it's really easy... 0x008800 is a mid blue, 0x880088 is purple, etc...

 

 

 

 

Color switch value table
 

See table below for color value of the "@ledcolor" parameter:

 "@fs3" : [
     {
      "@dsp" : 0,
      "@enabled" : false,
      "@group" : "block4",
      "@label" : "Scream 808",
      "@ledcolor" : 525824,
      "@momentary" : false,
      "@type" : 1
     }
 1037		Blue (dimmed)
 3334		Turquoise (dimmed)
 13055		Blue
 65408		Only for Volume Pedal, not sure if this being used
 67840		Green (dimmed)
 196619		Violet (dimmed)
 458496		Green
 462860		White (dimmed)
 525824		Light Orange (dimmed)
 527360		Yellow (dimmed)
 786434		Red (dimmed)
 1049600	Dark Orange (dimmed)
 3277055	Violet
 7077838	White (another dimmed) for multi FS assignment...
 8716032	Yellow
 13676288	Light Orange
 16723200	Dark Orange
 16711683	Red

Share this post


Link to post
Share on other sites

That makes me really happy. I just saved a TON of time, effort, and frustration, by manually editing .hlx files in a text editor.

 

Text files are ideal, since they enable advanced editing by people who want to dive that deep, but they don't get in the way of anybody who doesn't care about the technical details.

 

(Please please please don't change it to an opaque proprietary binary format in the future....)

 

 

 

Confirmed it's JSON.

 

Also, Setlist file (*.hls) and Bundle file (*.hlb) are 'base 64' encoded compressed (zlib) of JSON data as well.

 

I've made this little Python app to dump the content of a Bundle file called "Bundle_VERSION_1_03.hlb":

I'll come up with another Python to dump in a more formatted fashion way.

#!/usr/bin/env python

import json
from pprint import pprint
import base64
import zlib

data = None
compress_data = None
data_bundle = None

with open('Bundle_VERSION_1_03.hlb') as file_bundle:
        data = json.load(file_bundle)

if 'encoded_data' in data:
        compress_data = base64.b64decode(data['encoded_data'])
        bundle = zlib.decompress(compress_data)

        data_bundle = json.loads(bundle)
        pprint(data_bundle)

I'm not able to attached the full dump that the above app created, it's about 58000 lines.

But here is the first few lines of the Python structure:

 

 

{u'setlists': [{u'meta': {u'name': u'FACTORY 1'},
                u'presets': [{u'device': 2162689,
                              u'device_version': 16973856,
                              u'meta': {u'build_sha': u'3600857',
                                        u'name': u'US Double Nrm'},
                              u'tone': {u'controllers': {u'@expPedal2': [{u'@dsp': 0,
                                                                          u'@group': u'block1',
                                                                          u'@max': 1.0,
                                                                          u'@min': 0.0,
                                                                          u'@param': u'Pedal'}]},
                                        u'dsp0': {u'block0': {u'@enabled': False,
                                                              u'@model': u'HD2_Looper',
                                                              u'@path': 0,
                                                              u'@position': 7,
                                                              u'@stereo': False,
                                                              u'@type': 6,
                                                              u'Overdub': 0.0,
                                                              u'Playback': 0.0,
                                                              u'highCut': 20000.0,
                                                              u'lowCut': 20.0},
                                                  u'block1': {u'@enabled': True,
                                                              u'@model': u'HD2_VolPanVol',
                                                              u'@path': 0,
                                                              u'@position': 0,
                                                              u'@stereo': False,
                                                              u'@type': 0,
                                                              u'Pedal': 1.0,
                                                              u'VolumeTaper': False},
                                                  u'block2': {u'@enabled': False,
                                                              u'@model': u'HD2_CompressorRedSqueeze',

 

This is an astounding contribution to the Helix forum! Big thanks to mdmayfield for being the first to post on this and thestratmanblues for writing a script to help leverage it. Thank you!

  • Upvote 1

Share this post


Link to post
Share on other sites

Yep - try these number in HEX instead - much easier.  i.e., Their RED( 16711683) is 0xFF0003 - which is 255 for the red componend, 0 for the blue and 3 for the blue component.    WHen you get the hang of it it's really easy... 0x008800 is a mid blue, 0x880088 is purple, etc...

Thanks I'll check that out.

Share this post


Link to post
Share on other sites

 

I'm not able to attached the full dump that the above app created, it's about 58000 lines.

 

But here is the first few lines of the Python structure:

 

 

Perhaps you could post it up on GitHub and post a link here?   I'd love to help!

 

 

There you go: https://github.com/thestratmanblues/l6-helix/blob/master/helix_dump.out

Share this post


Link to post
Share on other sites

The patches for the Digitech GSP 1101 are XML. I wonder how hard it would be to whip up a GSP to Helix converter.

 

Well, the fact that both use open-standards based formats helps, but the real issue in converting sounds is hardly only with the format of the patch!

Share this post


Link to post
Share on other sites

Well, the fact that both use open-standards based formats helps, but the real issue in converting sounds is hardly only with the format of the patch!

 

Yes, there would need to be a certain amount of conversion in values involved but it should be doable. I'm not saying, nor implying, that a Digitech Mesa Boogie model and the Helix Mesa Boogie models are going to sound the same or that a patch conversion should even try to accommodate something like that, but if you have an entire library of patches for the Digitech then a conversion program could at least get you in the ballpark ... at least closer to starting from scratch.

Share this post


Link to post
Share on other sites

Yes, there would need to be a certain amount of conversion in values involved but it should be doable. I'm not saying, nor implying, that a Digitech Mesa Boogie model and the Helix Mesa Boogie models are going to sound the same or that a patch conversion should even try to accommodate something like that, but if you have an entire library of patches for the Digitech then a conversion program could at least get you in the ballpark ... at least closer to starting from scratch.

 

Well, yes, up to a certain "best guess" degree that is certainly doable. But (and I've seen this professionally in a different market many times) to what effect? Scenario:

 

* L6 launches Helix, and says "you can convert your HD500 patches!"

* fact: the underlying technology is very different, and sounds cannot be reproduced identically

* users are excited that their carfully crafted HD patches will be ported to HX

* hyp 1: the patch sounds the same, in fact. Now the user has a 3x more expensive new thing that sounds like the old one

* hyp 2: the patch sounds different. Discarding magic, it'll probably sound WORSE, since the original was tweaked carefully by hand. Now the user perceives a worsening of his tone.

 

That is, claiming to be able to convert patches would only serve to create hype, and achieving resulting "meh" from users.

 

That's not to say the feature would be useless! I would LOVE for my old HD500 patches to be "ported" in a state that would put me in the ballpark so I don't have to start from scratch. But I fear most reactions would be "I tried it, it sucks".

Share this post


Link to post
Share on other sites

Well, yes, up to a certain "best guess" degree that is certainly doable. But (and I've seen this professionally in a different market many times) to what effect? Scenario:

 

* L6 launches Helix, and says "you can convert your HD500 patches!"

* fact: the underlying technology is very different, and sounds cannot be reproduced identically

* users are excited that their carfully crafted HD patches will be ported to HX

* hyp 1: the patch sounds the same, in fact. Now the user has a 3x more expensive new thing that sounds like the old one

* hyp 2: the patch sounds different. Discarding magic, it'll probably sound WORSE, since the original was tweaked carefully by hand. Now the user perceives a worsening of his tone.

 

That is, claiming to be able to convert patches would only serve to create hype, and achieving resulting "meh" from users.

 

That's not to say the feature would be useless! I would LOVE for my old HD500 patches to be "ported" in a state that would put me in the ballpark so I don't have to start from scratch. But I fear most reactions would be "I tried it, it sucks".

Ahhhh! I see where we are getting our differences from. I agree with you completely that if Line 6 put out some sort patch conversion utility for other Line 6 products to the Helix then there would be a certain amount of expectations that those patches sound fairly similar. I was specifically talking about the Digitech GSP since their patches are stored in XML format. I was also NOT suggesting that Line 6 put out something like this ... I was thinking more along the lines of writing and releasing something myself.

Share this post


Link to post
Share on other sites

Well, in that case, you certainly have a point, and you'd have many thankful users!

Share this post


Link to post
Share on other sites

Notepad++ can read JSON files and format them in "human-readable" form :)

 

I just right-clicked on the file, selected "Edit with Notepad++" and then clicked on the left of the "1" (line number) to highlight the whole string. Click on "Plugins>JSON Viewer>Format JSON" and it reformatted.

 

It goes without saying that you have to have Notepad++ installed for this to work.

Share this post


Link to post
Share on other sites

Notepad++ can read JSON files and format them in "human-readable" form :)

 

I just right-clicked on the file, selected "Edit with Notepad++" and then clicked on the left of the "1" (line number) to highlight the whole string. Click on "Plugins>JSON Viewer>Format JSON" and it reformatted.

 

It goes without saying that you have to have Notepad++ installed for this to work.

Is this tool can open Setlist (*.hls) and Bundle (*.hlb) which are compressed base64 encoded files, or just the Preset file (*.hlx) which is already in text format and readable?

Share this post


Link to post
Share on other sites

Is this tool can open Setlist (*.hls) and Bundle (*.hlb) which are compressed base64 encoded files, or just the Preset file (*.hlx) which is already in text format and readable?

Well... yes and no.

 

Notepad++ can still open setlist and bundle files, as they seem to also be in JSON format, but it is unable to uncompress the data in them, so they are not really usable. I tried 7-zip, but it is also unable to open them, so far, I have only been able to open/format preset files.

Share this post


Link to post
Share on other sites

Well... yes and no.

 

Notepad++ can still open setlist and bundle files, as they seem to also be in JSON format, but it is unable to uncompress the data in them, so they are not really usable. I tried 7-zip, but it is also unable to open them, so far, I have only been able to open/format preset files.

Ok that's what I thought, I'm using the text editor call Sublime Text which does pretty much the same.

 

There is also this web site that I used sometime to format JSON file https://jsonformatter.curiousconcept.com/

 

You can also check the output made by the Python apps that I did, available on GitHub: https://raw.githubusercontent.com/thestratmanblues/l6-helix/master/helix_dump.out

 

The Python app is also there: https://raw.githubusercontent.com/thestratmanblues/l6-helix/master/helix_dump.py

I'm also working on another Python app that will allow to make change Globally on a Setlist, entire Bundle.  Like change the Variax Volume/Tone knobs to Don't force, or enable/disable the default Noise Gate from the Input preset block and so one, etc.

 

 

 

 

Share this post


Link to post
Share on other sites

Hey guys just in case there is anyone interested.  I had recently upgraded to Helix Editor 2.11 from 2.02.  The problem was that a bundle i had created in 2.02 would not load in the 2.11 editor for me to restore my patches.   I did not need all my patches just particular ones, so...

 

I used the python script above as a starting point to decrypt the Helix Bundle file.   I loop through each setlist in the bundle and create new .HLX files for each tone within the setlist.  

 

I was then able to load through the 2.11 editor the individual .HLX files and they worked!

 

You can find the script here - 

https://github.com/jyanes83/Line6-Helix-Bundle-Parser

Share this post


Link to post
Share on other sites

This is the kind of thing that I love dabbling with but I've noticed with Notepad++ than some presets open as described but otheres just show as one long line. Has the format been updated somewhere along the line?

 

Craig

Share this post


Link to post
Share on other sites

A small victory,

 

I'm coming to the conclusion that my setup sounds better with just an amp model in the Helix and a cab sim in my DT25 rather than an Amp+Cab+Mic in the Helix, the trouble is most patches are built with Amp+Cabs or separate cabs.

 

Now I've been able to export a preset, load it into Notepad++ and change the Amp+Cab to just an Amp (of the same model) but retain all it's settings then re-import it into the Helix :-)

 

Craig

  • Upvote 1

Share this post


Link to post
Share on other sites

I've also used a text editor to change my patches to MONO without loosing all individual parameter's values.

Share this post


Link to post
Share on other sites

I'm just curious, what are the advantages of manipulating patches this way?

 

 

There's all kinds of things you could script that aren't currently features in either the Helix or the Helix editor..  if you feel like writing a little code to do it.  Some ideas that I've been meaning to script:

 

* "copy favorite pedal" - i.e., a script that replaces all instances of a given pedal with the settings of that pedal as used in one specific patch.

* Global Model Color remapper - I noticed that one giant patch set that I bought uses entirely different colors for pedal models than Line 6 models.  I'm not the biggest fan of either color mapping, but having two different sets of colors for each pedal is just confusing. 

* Bulk pedal assignment re-mapper - so that I quickly change my settings from "Stomp/Snapshot" to "Snapshot/Stomp" - i.e.,  script that swaps all Stomp mode pedal-assignments between the upper and lower foot-switches.

* Copy Snapshot Instant settings - so that I can add my favorite midi mappings to control outboard gear to existing patches

 

 

The sky's the limit, and it's pretty easy to code up this stuff if you're comfy on the CLI.  Thing is I'd just rather play guitar and not think about code after my long days at work...

 

Cheers!

  • Upvote 1

Share this post


Link to post
Share on other sites

There's all kinds of things you could script that aren't currently features in either the Helix or the Helix editor..  if you feel like writing a little code to do it.  Some ideas that I've been meaning to script:

 

* "copy favorite pedal" - i.e., a script that replaces all instances of a given pedal with the settings of that pedal as used in one specific patch.

* Global Model Color remapper - I noticed that one giant patch set that I bought uses entirely different colors for pedal models than Line 6 models.  I'm not the biggest fan of either color mapping, but having two different sets of colors for each pedal is just confusing. 

* Bulk pedal assignment re-mapper - so that I quickly change my settings from "Stomp/Snapshot" to "Snapshot/Stomp" - i.e.,  script that swaps all Stomp mode pedal-assignments between the upper and lower foot-switches.

* Copy Snapshot Instant settings - so that I can add my favorite midi mappings to control outboard gear to existing patches

 

 

The sky's the limit, and it's pretty easy to code up this stuff if you're comfy on the CLI.  Thing is I'd just rather play guitar and not think about code after my long days at work...

 

Cheers!

 

Oooooooo. I like those options. Not sure I have the courage to do this since I am, at best, very limited in my  code writing. But good luck to you guys.

Share this post


Link to post
Share on other sites

yes very happy that these files are json.   The benefits are with batch editing, e.g. doing a search and replace on your whole set.    Or I might have a vocal tone that is the same for every song but all my guitar fx differ, I can copy the vocal tone config and paste it to the other patches.  I don't believe you can do that in the software editor.

Share this post


Link to post
Share on other sites

...

* Bulk pedal assignment re-mapper - so that I quickly change my settings from "Stomp/Snapshot" to "Snapshot/Stomp" - i.e.,  script that swaps all Stomp mode pedal-assignments between the upper and lower foot-switches.

...

 

Cheers!

 

Posted a similar request for "Stomp/Preset" in Ideascale two years ago and still hoping Line6 will add this feature to the Helix some time. The core idea remains the same though - the ability to globally swap all your stomp assignments from the top to the bottom row and vice-versa. Vote it up here: https://line6.ideascale.com/a/idea-v2/790520

 

 A script is the only alternative right now. 

Share this post


Link to post
Share on other sites

I would think there's very little risk of incompatibility with Helix or the Helix app if all you're doing is simple text replacements. But suppose you're making more structural changes, where the best option is to deserialize the JSON data, mess with it as data (not text), and serialize it again. Has anyone tried that?

 

The JSON format generated by the Helix app isn't what I would describe as standard, particularly its whitespace handling. The tools I'm using for my analysis app can generate JSON from a complex data structure like a preset with a simple function call, but it won't be exactly like what Helix itself does.

 

So far, I've been concentrating on other aspects of my app that don't involve modifying presets, so I haven't tried seeing if Helix accepts that or not. Of course it's possible to write a custom serializer, but all other things being equal, I'd rather spend the time on more interesting functionality.

 

Has anyone been down a similar road far enough to know how tolerant Helix is of whitespace differences?

Share this post


Link to post
Share on other sites

I would think there's very little risk of incompatibility with Helix or the Helix app if all you're doing is simple text replacements. But suppose you're making more structural changes, where the best option is to deserialize the JSON data, mess with it as data (not text), and serialize it again. Has anyone tried that?

 

The JSON format generated by the Helix app isn't what I would describe as standard, particularly its whitespace handling. The tools I'm using for my analysis app can generate JSON from a complex data structure like a preset with a simple function call, but it won't be exactly like what Helix itself does.

 

So far, I've been concentrating on other aspects of my app that don't involve modifying presets, so I haven't tried seeing if Helix accepts that or not. Of course it's possible to write a custom serializer, but all other things being equal, I'd rather spend the time on more interesting functionality.

 

Has anyone been down a similar road far enough to know how tolerant Helix is of whitespace differences?

 

It handles it fine - I've been down that path and automatically update presets to match when my IR slot numbers change. I responded in your other thread with a little more detail. I happen to be using Python and simply use the json module, specifically json.dumps(data, indent=4). Helix loads them fine so you should be good.

Share this post


Link to post
Share on other sites

Cool, thanks for the info. Saw your other reply too, answered there.

Share this post


Link to post
Share on other sites

Does anyone know what the file size limit is of a preset?  Also, for those of you struggling with dealing with json I highly recommend a json utility like "Power JSON Editor".  Simple and purpose built for viewing and manipulating this format.

Share this post


Link to post
Share on other sites

Someone needs to write a GUI viewer for hlx files.  It could be a website or a standalone app but it would be cool to be able to graphically view presets in a similar way to how HX Edit or the Helix would display them without actually having the Helix present or running the Native software.  I would help in the effort but my programming chops are limited.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...