uboot_env v0.1.0 UBootEnv.Tools

This module uses U-boot tools' fw_printenv to read environment blocks. It is only useful if OTP 21 is not available. This module has a known issue with parsing key-value pairs with embedded newlines.

Link to this section Summary

Functions

Decode the output of fw_printenv

Decode a U-Boot environment block using fw_printenv

Set a U-Boot variable using fw_setenv

Link to this section Functions

Link to this function

decode(env)
decode(String.t()) :: map()

Decode the output of fw_printenv

Link to this function

fw_printenv()
fw_printenv() :: {:ok, map()} | {:error, reason :: String.t()}

Decode a U-Boot environment block using fw_printenv

Link to this function

fw_setenv(key, value)
fw_setenv(String.t(), String.t()) :: :ok | {:error, reason :: String.t()}

Set a U-Boot variable using fw_setenv.