# This file was automatically generated by SWIG (http://www.swig.org).
# Version 3.0.12
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.

from sys import version_info as _swig_python_version_info
if _swig_python_version_info >= (2, 7, 0):
    def swig_import_helper():
        import importlib
        pkg = __name__.rpartition('.')[0]
        mname = '.'.join((pkg, '_pyupm_2jciebu01_usb')).lstrip('.')
        try:
            return importlib.import_module(mname)
        except ImportError:
            return importlib.import_module('_pyupm_2jciebu01_usb')
    _pyupm_2jciebu01_usb = swig_import_helper()
    del swig_import_helper
elif _swig_python_version_info >= (2, 6, 0):
    def swig_import_helper():
        from os.path import dirname
        import imp
        fp = None
        try:
            fp, pathname, description = imp.find_module('_pyupm_2jciebu01_usb', [dirname(__file__)])
        except ImportError:
            import _pyupm_2jciebu01_usb
            return _pyupm_2jciebu01_usb
        try:
            _mod = imp.load_module('_pyupm_2jciebu01_usb', fp, pathname, description)
        finally:
            if fp is not None:
                fp.close()
        return _mod
    _pyupm_2jciebu01_usb = swig_import_helper()
    del swig_import_helper
else:
    import _pyupm_2jciebu01_usb
del _swig_python_version_info

try:
    _swig_property = property
except NameError:
    pass  # Python < 2.2 doesn't have 'property'.

try:
    import builtins as __builtin__
except ImportError:
    import __builtin__

def _swig_setattr_nondynamic(self, class_type, name, value, static=1):
    if (name == "thisown"):
        return self.this.own(value)
    if (name == "this"):
        if type(value).__name__ == 'SwigPyObject':
            self.__dict__[name] = value
            return
    method = class_type.__swig_setmethods__.get(name, None)
    if method:
        return method(self, value)
    if (not static):
        if _newclass:
            object.__setattr__(self, name, value)
        else:
            self.__dict__[name] = value
    else:
        raise AttributeError("You cannot add attributes to %s" % self)


def _swig_setattr(self, class_type, name, value):
    return _swig_setattr_nondynamic(self, class_type, name, value, 0)


def _swig_getattr(self, class_type, name):
    if (name == "thisown"):
        return self.this.own()
    method = class_type.__swig_getmethods__.get(name, None)
    if method:
        return method(self)
    raise AttributeError("'%s' object has no attribute '%s'" % (class_type.__name__, name))


def _swig_repr(self):
    try:
        strthis = "proxy of " + self.this.__repr__()
    except __builtin__.Exception:
        strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)

try:
    _object = object
    _newclass = 1
except __builtin__.Exception:
    class _object:
        pass
    _newclass = 0


def getVersion():
    return _pyupm_2jciebu01_usb.getVersion()
getVersion = _pyupm_2jciebu01_usb.getVersion
OM2JCIEBU_FLASH_LONG_DATA_READ_ADD_UART = _pyupm_2jciebu01_usb.OM2JCIEBU_FLASH_LONG_DATA_READ_ADD_UART
OM2JCIEBU_LIVE_LONG_DATA_READ_ADD_UART = _pyupm_2jciebu01_usb.OM2JCIEBU_LIVE_LONG_DATA_READ_ADD_UART
OM2JCIEBU_LED_CONFIGUARTION_ADD_UART = _pyupm_2jciebu01_usb.OM2JCIEBU_LED_CONFIGUARTION_ADD_UART
OM2JCIEBU_ADV_CONFIGUARTION_ADD_UART = _pyupm_2jciebu01_usb.OM2JCIEBU_ADV_CONFIGUARTION_ADD_UART
OM2JCIEBU_LED_CONFIGUARTION_UUID_BLE = _pyupm_2jciebu01_usb.OM2JCIEBU_LED_CONFIGUARTION_UUID_BLE
OM2JCIEBU_ADV_CONFIGUARTION_UUID_BLE = _pyupm_2jciebu01_usb.OM2JCIEBU_ADV_CONFIGUARTION_UUID_BLE
OM2JCIEBU_LIVE_LONG_DATA_READ_UUID_BLE = _pyupm_2jciebu01_usb.OM2JCIEBU_LIVE_LONG_DATA_READ_UUID_BLE
OM2JCIEBU_CRC_LENGTH = _pyupm_2jciebu01_usb.OM2JCIEBU_CRC_LENGTH
OM2JCIEBU_CRC16 = _pyupm_2jciebu01_usb.OM2JCIEBU_CRC16
OM2JCIEBU_INTERVAL_UNIT = _pyupm_2jciebu01_usb.OM2JCIEBU_INTERVAL_UNIT
class OM2JCIEBU(_object):
    __swig_setmethods__ = {}
    __setattr__ = lambda self, name, value: _swig_setattr(self, OM2JCIEBU, name, value)
    __swig_getmethods__ = {}
    __getattr__ = lambda self, name: _swig_getattr(self, OM2JCIEBU, name)

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined - class is abstract")
    __repr__ = _swig_repr
    ALL_PARAM = _pyupm_2jciebu01_usb.OM2JCIEBU_ALL_PARAM
    TEMP = _pyupm_2jciebu01_usb.OM2JCIEBU_TEMP
    HUMIDITY = _pyupm_2jciebu01_usb.OM2JCIEBU_HUMIDITY
    AMBIENT_LIGHT = _pyupm_2jciebu01_usb.OM2JCIEBU_AMBIENT_LIGHT
    PRESSURE = _pyupm_2jciebu01_usb.OM2JCIEBU_PRESSURE
    NOISE = _pyupm_2jciebu01_usb.OM2JCIEBU_NOISE
    ETVOC = _pyupm_2jciebu01_usb.OM2JCIEBU_ETVOC
    ECO2 = _pyupm_2jciebu01_usb.OM2JCIEBU_ECO2
    DISCOMFORT_INDEX = _pyupm_2jciebu01_usb.OM2JCIEBU_DISCOMFORT_INDEX
    HEAT_STROKE = _pyupm_2jciebu01_usb.OM2JCIEBU_HEAT_STROKE
    LED_CONFIGURE = _pyupm_2jciebu01_usb.OM2JCIEBU_LED_CONFIGURE
    ADV_CONFIGURE = _pyupm_2jciebu01_usb.OM2JCIEBU_ADV_CONFIGURE
    BLE = _pyupm_2jciebu01_usb.OM2JCIEBU_BLE
    USB_TO_UART = _pyupm_2jciebu01_usb.OM2JCIEBU_USB_TO_UART
    SENSOR_DATA = _pyupm_2jciebu01_usb.OM2JCIEBU_SENSOR_DATA
    ACCELERATION_DATA = _pyupm_2jciebu01_usb.OM2JCIEBU_ACCELERATION_DATA
    ACCELERATION_SENSOR_DATA = _pyupm_2jciebu01_usb.OM2JCIEBU_ACCELERATION_SENSOR_DATA
    ACCELERATION_SENSOR_FLAG = _pyupm_2jciebu01_usb.OM2JCIEBU_ACCELERATION_SENSOR_FLAG
    SERIAL_NUMBER = _pyupm_2jciebu01_usb.OM2JCIEBU_SERIAL_NUMBER
    ERROR_CRC_WRONG = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_CRC_WRONG
    ERROR_WRONG_COMMAND = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_WRONG_COMMAND
    ERROR_WRONG_ADDRESS = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_WRONG_ADDRESS
    ERROR_WRONG_LENGTH = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_WRONG_LENGTH
    ERROR_DATA_RANGE = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_DATA_RANGE
    ERROR_BUSY = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_BUSY
    ERROR_UNKNOWN = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_UNKNOWN
    ERROR_CRC_MISMATCH = _pyupm_2jciebu01_usb.OM2JCIEBU_ERROR_CRC_MISMATCH
    FAILURE = _pyupm_2jciebu01_usb.OM2JCIEBU_FAILURE
    SUCCESS = _pyupm_2jciebu01_usb.OM2JCIEBU_SUCCESS
    NORMALLY_OFF = _pyupm_2jciebu01_usb.OM2JCIEBU_NORMALLY_OFF
    NORMALLY_ON = _pyupm_2jciebu01_usb.OM2JCIEBU_NORMALLY_ON
    TEMP_SACLE = _pyupm_2jciebu01_usb.OM2JCIEBU_TEMP_SACLE
    HUMIDITY_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_HUMIDITY_SCALE
    AMBIENT_LIGHT_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_AMBIENT_LIGHT_SCALE
    PRESSURE_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_PRESSURE_SCALE
    NOISE_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_NOISE_SCALE
    ETVOC_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_ETVOC_SCALE
    SI_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_SI_SCALE
    PGA_SCALE = _pyupm_2jciebu01_usb.OM2JCIEBU_PGA_SCALE
    __swig_destroy__ = _pyupm_2jciebu01_usb.delete_OM2JCIEBU
    __del__ = lambda self: None

    def getAddress(self, attribute_name, interface, attribute_value):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_getAddress(self, attribute_name, interface, attribute_value)

    def delay(self, second):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_delay(self, second)

    def crc_16(self, data, length):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_crc_16(self, data, length)

    def configureSensorLedState(self, state, red, green, blue):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_configureSensorLedState(self, state, red, green, blue)

    def configureSensorAdvSetting(self, milliseconds, adv_mode):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_configureSensorAdvSetting(self, milliseconds, adv_mode)

    def parseSensorData(self, data):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_parseSensorData(self, data)

    def getSensorData(self, attribute_name, attribute_data):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_getSensorData(self, attribute_name, attribute_data)

    def verifyPacket(self, pkt, len):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_verifyPacket(self, pkt, len)
OM2JCIEBU_swigregister = _pyupm_2jciebu01_usb.OM2JCIEBU_swigregister
OM2JCIEBU_swigregister(OM2JCIEBU)

OM2JCIEBU_UART_HEADER_START = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_HEADER_START
OM2JCIEBU_UART_HEADER_END = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_HEADER_END
OM2JCIEBU_UART_MAX_PKT_LEN = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_MAX_PKT_LEN
OM2JCIEBU_UART_MAX_READ_PKT_LEN = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_MAX_READ_PKT_LEN
OM2JCIEBU_UART_COMMAND_LENGHT = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_COMMAND_LENGHT
OM2JCIEBU_UART_ADDRESS_LENGTH = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ADDRESS_LENGTH
OM2JCIEBU_UART_HEADER_LENGTH = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_HEADER_LENGTH
OM2JCIEBU_UART_COMMAND_INDEX = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_COMMAND_INDEX
OM2JCIEBU_UART_COMMAND_ERROR_CODE_INDEX = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_COMMAND_ERROR_CODE_INDEX
class OM2JCIEBU_UART(OM2JCIEBU):
    __swig_setmethods__ = {}
    for _s in [OM2JCIEBU]:
        __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))
    __setattr__ = lambda self, name, value: _swig_setattr(self, OM2JCIEBU_UART, name, value)
    __swig_getmethods__ = {}
    for _s in [OM2JCIEBU]:
        __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))
    __getattr__ = lambda self, name: _swig_getattr(self, OM2JCIEBU_UART, name)
    __repr__ = _swig_repr
    UART_CMD_READ = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_UART_CMD_READ
    UART_CMD_WRITE = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_UART_CMD_WRITE
    ERROR_UART_CRC_WRONG = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_CRC_WRONG
    ERROR_UART_WRONG_COMMAND = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_WRONG_COMMAND
    ERROR_UART_WRONG_ADDRESS = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_WRONG_ADDRESS
    ERROR_UART_WRONG_LENGTH = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_WRONG_LENGTH
    ERROR_UART_DATA_RANGE = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_DATA_RANGE
    ERROR_UART_BUSY = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_BUSY
    ERROR_UART_UNKNOWN = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_ERROR_UART_UNKNOWN
    PARITY_UART_NONE = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_PARITY_UART_NONE
    PARITY_UART_EVEN = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_PARITY_UART_EVEN
    PARITY_UART_ODD = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_PARITY_UART_ODD
    PARITY_UART_MARK = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_PARITY_UART_MARK
    PARITY_UART_SPACE = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_PARITY_UART_SPACE

    def __init__(self, path, baud=115200):
        this = _pyupm_2jciebu01_usb.new_OM2JCIEBU_UART(path, baud)
        try:
            self.this.append(this)
        except __builtin__.Exception:
            self.this = this

    def setupTty(self, baud=115200):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_UART_setupTty(self, baud)

    def setMode(self, bytesize, parity, stopbits):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_UART_setMode(self, bytesize, parity, stopbits)

    def setFlowControl(self, xonxoff, rtscts):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_UART_setFlowControl(self, xonxoff, rtscts)

    def getSensorData(self, attribute_name, attribute_data):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_UART_getSensorData(self, attribute_name, attribute_data)

    def configureSensorLedState(self, state, red, green, blue):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_UART_configureSensorLedState(self, state, red, green, blue)

    def configureSensorAdvSetting(self, milliseconds, adv_mode):
        return _pyupm_2jciebu01_usb.OM2JCIEBU_UART_configureSensorAdvSetting(self, milliseconds, adv_mode)
    __swig_destroy__ = _pyupm_2jciebu01_usb.delete_OM2JCIEBU_UART
    __del__ = lambda self: None
OM2JCIEBU_UART_swigregister = _pyupm_2jciebu01_usb.OM2JCIEBU_UART_swigregister
OM2JCIEBU_UART_swigregister(OM2JCIEBU_UART)

# This file is compatible with both classic and new-style classes.


