# Path: basil/HL/RegisterHardwareLayer.py
# class RegisterHardwareLayer(HardwareLayer):
#     def __init__(self, intf, conf):
#     def init(self):
#     def set_value(self, value, addr, size, offset, **kwargs):
#     def get_value(self, addr, size, offset, **kwargs):
#     def set_bytes(self, data, addr, **kwargs):
#     def get_bytes(self, addr, size, **kwargs):
#     def set_configuration(self, conf):
#     def get_configuration(self):
#     def add_property(self, attribute):
#         def getter(self):
#         def setter(self, value):
#     def set_default(self):
#     def _get(self, reg):
#     def _set(self, reg, value):
#     def __getitem__(self, name):
#     def __setitem__(self, name, value):
#     def __getattr__(self, name):
#         def method(*args, **kwargs):
#     def __setattr__(self, name, value):


import struct
from basil.HL.RegisterHardwareLayer import HardwareLayer
# SiLab, Institute of Physics, University of Bonn
# ------------------------------------------------------------
#



# MODBus function codes
FUNCTION_READN = 0x03  # read n words
FUNCTION_READN_ALT = 0x04  # read n words, does not occur
FUNCTION_WRITE = 0x06  # write word
FUNCTION_WRITEN = 0x10  # write n words

# Operation addresses
ADDR_CURTEMP = 0x11a9
ADDR_DOOROPEN = 0x1007  # does not work, wrong address?
ADDR_SETPOINT = 0x1077
ADDR_MANSETPT = 0x1581
ADDR_BASICSETPT = 0x156f
ADDR_MODE = 0x1a22

# Error codes
ERROR_CODES = {
    1: "Invalid function",
    2: "Invalid parameter address",
    3: "Pparameter value outside range of values",
    4: "Slave not ready",
    5: "Write access to parameter denied"
}



# Path: basil/HL/RegisterHardwareLayer.py
# class RegisterHardwareLayer(HardwareLayer):
#     def __init__(self, intf, conf):
#     def init(self):
#     def set_value(self, value, addr, size, offset, **kwargs):
#     def get_value(self, addr, size, offset, **kwargs):
#     def set_bytes(self, data, addr, **kwargs):
#     def get_bytes(self, addr, size, **kwargs):
#     def set_configuration(self, conf):
#     def get_configuration(self):
#     def add_property(self, attribute):
#         def getter(self):
#         def setter(self, value):
#     def set_default(self):
#     def _get(self, reg):
#     def _set(self, reg, value):
#     def __getitem__(self, name):
#     def __setitem__(self, name, value):
#     def __getattr__(self, name):
#         def method(*args, **kwargs):
#     def __setattr__(self, name, value):


# Path: basil/HL/binder_mk53.py
import struct
from basil.HL.RegisterHardwareLayer import HardwareLayer

# SiLab, Institute of Physics, University of Bonn
# ------------------------------------------------------------
#



# MODBus function codes
FUNCTION_READN = 0x03  # read n words
FUNCTION_READN_ALT = 0x04  # read n words, does not occur
FUNCTION_WRITE = 0x06  # write word
FUNCTION_WRITEN = 0x10  # write n words

# Operation addresses
ADDR_CURTEMP = 0x11a9
ADDR_DOOROPEN = 0x1007  # does not work, wrong address?
ADDR_SETPOINT = 0x1077
ADDR_MANSETPT = 0x1581
ADDR_BASICSETPT = 0x156f
ADDR_MODE = 0x1a22

# Error codes
ERROR_CODES = {
    1: "Invalid function",
    2: "Invalid parameter address",
    3: "Pparameter value outside range of values",
    4: "Slave not ready",
    5: "Write access to parameter denied"
}



class binderMK53(HardwareLayer):