# `MAVLink2.Transport`
[🔗](https://github.com/isaiahdw/mavlink2/blob/v0.1.0/lib/mavlink2/transport.ex#L1)

The byte transport under a `MAVLink2.Link`: `MAVLink2.Transport.UART` for
a serial port, `MAVLink2.Transport.Loopback` for tests.

`open/1` gets the link's options with `:owner`, the link process. Bytes
arrive at the owner as `{:mavlink_data, binary}`.

# `t`

```elixir
@type t() :: term()
```

# `close`

```elixir
@callback close(t()) :: :ok
```

# `open`

```elixir
@callback open(keyword()) :: {:ok, t()} | {:error, term()}
```

# `options`
*optional* 

```elixir
@callback options() :: keyword()
```

The options `open/1` takes, as `[{name, type}]` for `MAVLink2.Link` to
check before opening, so a misspelled option is an error rather than
ignored. Optional: without it, the link passes any option through.

# `write`

```elixir
@callback write(t(), iodata()) :: :ok | {:error, term()}
```

---

*Consult [api-reference.md](api-reference.md) for complete listing*
