You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now the G-Code data block just lists the encoding header format and lists the possible values for the header field:
0 = No encoding
1 = MeatPack algorithm
2 = MeatPack algorithm modified to keep comment lines
without defining what MeatPack or the modified MeatPack algorithms are. It would be good if the definition of those encoding types were documented (also assuming no encoding just means the text gcode). While you can look at the source code, documenting the actual specifics of the encoding formats will make the specification more useful for people trying to interoperate with the format.
The text was updated successfully, but these errors were encountered:
I agree that the actual compression algorithm should be documented. This is an error shared by its creator, but considering the core code is only a couple hundred lines long it really shouldn't be difficult to explain.
For proof of concept / preliminary suggestion, here's my attempt based on reading the original Meatpack code:
"libbgcode implements the Meatpack gcode binary compression algorithm created by Scott Mudge (https://github.com/scottmudge/". It takes advantage of the small set of approximately 15 characters needed by gcode by assigning each character a 4 bit representation. Each pair of characters in the ASCII gcode can be compressed into a single byte by bitshifting the first character's binary representation left and combining them with a bitwise or operation. Combined with a few other structural details, this results in a nearly 2:1 reduction of space usage."
This is just a crude start, but I hope this illustrates how the effect can be achieved with relatively little text.
Right now the G-Code data block just lists the encoding header format and lists the possible values for the header field:
without defining what
MeatPack
or the modifiedMeatPack
algorithms are. It would be good if the definition of those encoding types were documented (also assuming no encoding just means the text gcode). While you can look at the source code, documenting the actual specifics of the encoding formats will make the specification more useful for people trying to interoperate with the format.The text was updated successfully, but these errors were encountered: