class Broadlink::Device

Included Modules

Direct Known Subclasses

Defined in:

broadlink.cr

Constant Summary

ID_PACKET = Bytes[0, 0, 0, 0]
IV_PACKET = Bytes[86, 46, 23, 153, 109, 9, 61, 40, 221, 179, 186, 105, 90, 46, 111, 88]
KEY_PACKET = Bytes[9, 118, 40, 52, 63, 233, 158, 35, 118, 92, 21, 19, 172, 207, 139, 2]

Constructors

Instance Method Summary

Instance methods inherited from module Broadlink

discover(timeout = 10, local_ip_address = "") discover, gendevice(devtype : UInt16, host : String, mac : Bytes) gendevice, setup(ssid : String, password : String, security_mode : UInt8) setup

Constructor Detail

def self.new(host : String, mac : Bytes, devtype : UInt16, timeout : Int32 = 1) #

[View source]

Instance Method Detail

def auth? #

[View source]
def decrypt(payload : Bytes) #

[View source]
def devtype : UInt16 #

[View source]
def encrypt(payload : Bytes) #

[View source]
def host : String #

[View source]
def mac : Slice(UInt8) #

[View source]
def send_packet(command : UInt8, payload : Bytes) #

[View source]
def type : String #

[View source]