| 1 | # libbgcode |
| 2 | |
| 3 | Prusa Block & Binary G-code reader / writer / converter |
| 4 | |
| 5 | # Description |
| 6 | |
| 7 | A new G-code file format featuring the following improvements over the legacy G-code: |
| 8 | 1) Block structure with distinct blocks for metadata vs. G-code |
| 9 | 2) Faster navigation |
| 10 | 3) Coding & compression for smaller file size |
| 11 | 4) Checksum for data validity |
| 12 | 5) Extensivity through new (custom) blocks. For example, a file signature block may be welcome by corporate customers. |
| 13 | |
| 14 | **libbgcode** library is split into three API: |
| 15 | * [core](#core-api) |
| 16 | * [binarize](#binarize-api) |
| 17 | * [convert](#convert-api) |
| 18 | |
| 19 | ### core API |
| 20 | |
| 21 | **core api** contains the basic definitions and functionality which allow to read a G-code file in binary format as defined into [SPECIFICATIONS](doc/specifications.md). |
| 22 | |
| 23 | See [src/LibBGCode/core/core.hpp](src/LibBGCode/core/core.hpp) |
| 24 | |
| 25 | ### binarize API |
| 26 | |
| 27 | **binarize api** contains the definitions and functionality which allow to write a G-code file in binary format as defined into [SPECIFICATIONS](doc/specifications.md). |
| 28 | |
| 29 | See [src/LibBGCode/binarize/binarize.hpp](src/LibBGCode/binarize/binarize.hpp) |
| 30 | |
| 31 | ### convert API |
| 32 | |
| 33 | **convert api** contains the functionality which allow to convert G-code files to/from binary format as defined into [SPECIFICATIONS](doc/specifications.md). |
| 34 | |
| 35 | See [src/LibBGCode/convert/convert.hpp](src/LibBGCode/convert/convert.hpp) |
| 36 | |
| 37 | # Specifications |
| 38 | |
| 39 | See [SPECIFICATIONS](doc/specifications.md) for file format specifications. |
| 40 | |
| 41 | # Building |
| 42 | |
| 43 | See [BUILDING](doc/building.md) for building instructions. |
| 44 | |
| 45 | # Command line application |
| 46 | |
| 47 | See [BGCODE](doc/bgcode.md) for instructions. |
| 48 | |
| 49 | # References |
| 50 | |
| 51 | We would like to thank Scott Vokes (@atomicobject) for his work on heatshrink and |
| 52 | Scott Mudge (@scottmudge) for developing and maintaining MeatPack. |