module Zklib::ConnectionManagement

Public Instance Methods

connect() click to toggle source

Connect to attendance machine

# File lib/zklib/connection_management.rb, line 4
def connect
  execute_cmd(
    command:        CMD_CONNECT,
    command_string: ''
  ) do |opts|
    check_valid(data: opts[:data])
  end
end
disconnect() click to toggle source

Disconnect from attendance machine

# File lib/zklib/connection_management.rb, line 14
def disconnect
  execute_cmd(
    command:        CMD_EXIT,
    command_string: ''
  ) do |opts|
    check_valid(data: opts[:data])
  end
end