https://github.com/platform-system-interface/haeftobf
convert a hex-encoded file to binary
https://github.com/platform-system-interface/haeftobf
Last synced: 7 months ago
JSON representation
convert a hex-encoded file to binary
- Host: GitHub
- URL: https://github.com/platform-system-interface/haeftobf
- Owner: platform-system-interface
- License: mit
- Created: 2024-05-11T14:54:29.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-11T15:13:05.000Z (almost 2 years ago)
- Last Synced: 2025-01-12T21:07:29.081Z (over 1 year ago)
- Language: Rust
- Size: 2.93 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# haeftobf
TL;DR: Decode a *h*ex-*A*SCII-*e*ncoded *f*ile *to* a raw *b*inary *f*ile:
```sh
haeftobf foo.asc
```
The output file will have the same name, just with the extension `.bin`.
Your file may contain any number of separate lines.
No spaces or other characters are allowed within a line.
Every line is required to contain an even number of characters, of which two
each represent one byte, hex-encoded. E.g., `42` is the character `B`.
In other words, the resulting file will be half the input file or less in size.
This is useful in scenarios where you may easily transfer ASCII characters, but
you really want binary data. You can use `haeftobf` to dump memory over a UART,
while you also have code running that logs other information, for example.