AutoApi.DoorsState.from_bin

You're seeing just the function from_bin, go back to AutoApi.DoorsState module for more information.

Specs

from_bin(binary()) :: t()

Build state based on binary value

iex> AutoApi.DoorsState.from_bin(<<0x03, 5::integer-16, 0x01, 2::integer-16, 0x00, 0x01>>) %AutoApi.DoorsState{locks: [%AutoApi.Property{data: %{location: :front_left, lock_state: :locked}}]}

iex> AutoApi.DoorsState.from_bin(<<0x04, 5::integer-16, 0x01, 2::integer-16, 0x05, 0x00>>) %AutoApi.DoorsState{positions: [%AutoApi.Property{data: %{location: :all, position: :closed}}]}