package intel_hex

  1. Overview
  2. Docs
Intel HEX manipulation library

Install

dune-project
 Dependency

Authors

Maintainers

Sources

0.2.tar.gz
md5=03e8cc98c7aea6ba2706530ac839d490
sha512=fd8552a4e85f32070d39502fdff774df2609d0355b9de58336c1f6ec400904d7925f9b74641a0b53c60d354608c0fec2cbc15d95dcf0bdba9c86bb0d59a9b5c7

doc/README.html

intel_hex

The Intel HEX manipulation library for OCaml provides functions to read, write, and create Intel HEX format data, which is commonly used in embedded systems programming.

Usage

If you are using Dune, add the intel_hex library to your libraries stanza.

Here is an example that creates an IHEX object file with test data and then prints it:

let ihex =
  Intel_hex.Record.
    [
      Data { offset = 0; payload = "hello " };
      Data { offset = 7; payload = "world" };
      End_of_file
    ]

let () = ihex |> Intel_hex.to_string |> print_endline

Also, you can of course read the IHEX object file from other sources:

In_channel.with_open_text "firmware.hex" Intel_hex.of_channel

For more documentation you should read the mli files.

References