# ReticulumEx
Elixir wrapper for the Rust `reticulum` crate via Rustler.
## Installation
Add to `mix.exs`:
```elixir
def deps do
[
{:reticulum_ex, "~> 0.1.0"}
]
end
```
## Usage
Create an identity and compute a destination name hash:
```elixir
{:ok, id} = ReticulumEx.Identity.new_from_name("alice")
{:ok, priv_hex} = ReticulumEx.Identity.to_hex(id)
{:ok, pub_hex} = ReticulumEx.Identity.public_hex(id)
{:ok, name_hash_hex} = ReticulumEx.Destination.name_hash("example", "chat")
```
Build an announce packet and HDLC-encode for wire transport:
```elixir
{:ok, packet_bin} = ReticulumEx.Packet.announce(id)
{:ok, frame} = ReticulumEx.HDLC.encode(packet_bin)
```
See `ReticulumEx` module docs for more.
## Installation
If [available in Hex](https://hex.pm/docs/publish), the package can be installed
by adding `reticulum_ex` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[
{:reticulum_ex, "~> 0.1.0"}
]
end
```
Documentation can be generated with [ExDoc](https://github.com/elixir-lang/ex_doc)
and published on [HexDocs](https://hexdocs.pm). Once published, the docs can
be found at <https://hexdocs.pm/reticulum_ex>.