Grizzly.ZWave.Notifications (grizzly v8.8.0)

View Source

Encoding and decoding functions for notification events and types from the Notification command class.

Summary

Functions

Lists all events associated with the given notification type.

Lists all notification types.

Decode a notification event.

Encode a notification event.

Decode a notification type.

Encode a notification type.

Types

event()

@type event() :: atom()

status()

@type status() :: :enabled | :disabled

type()

@type type() :: atom()

zwave_alarm_status()

@type zwave_alarm_status() :: :deactivate | :activate

Functions

all_events_by_type(type)

Lists all events associated with the given notification type.

all_notification_types()

@spec all_notification_types() :: [atom()]

Lists all notification types.

decode_event_params(zwave_type, zwave_event, params_binary)

encode_event_params(zwave_type, zwave_event, event_params_list)

event_from_byte(type, byte)

@spec event_from_byte(type(), byte()) ::
  {:ok, event()} | {:error, :invalid_event_byte}

Decode a notification event.

event_to_byte(type, event)

@spec event_to_byte(type(), event()) :: byte()

Encode a notification event.

status_from_byte(arg1)

@spec status_from_byte(byte()) :: {:ok, status()} | {:error, :invalid_status_byte}

status_to_byte(atom)

@spec status_to_byte(status()) :: 0 | 255

type_from_byte(byte)

@spec type_from_byte(byte()) :: {:ok, type()} | {:error, :invalid_type_byte}

Decode a notification type.

type_to_byte(type)

@spec type_to_byte(type()) :: byte()

Encode a notification type.