2 Commits

2 changed files with 14 additions and 10 deletions

View File

@@ -3,7 +3,7 @@
"driverFileName":"ipp.py",
"deviceName":"ipp",
"driverId":"0090",
"releaseVersion":"4",
"releaseVersion":"6",
"files": {
"file1":"ipp.py",
"file2":"micro800.py"

View File

@@ -175,6 +175,10 @@ class start(threading.Thread, deviceBase):
global channels
channels = {
'automode': Channel('automode', 'Auto_Mode', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'alarmdhpressure': Channel('alarmdhpressure', 'alarm_DHPressure', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'alarmdhtemperature': Channel('alarmdhtemperature', 'alarm_DHTemperature', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'alarme300': Channel('alarme300', 'alarm_E300', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'alarmtubingpressure': Channel('alarmtubingpressure', 'alarm_TubingPressure', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'cfgcflasetting': Channel('cfgcflasetting', 'cfg_C_FLASetting', 86400, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=True),
'cfgcleartripcountafter': Channel('cfgcleartripcountafter', 'cfg_ClearTripCountAfter', 86400, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=False),
'cfggfgroundfaultinhibittime': Channel('cfggfgroundfaultinhibittime', 'cfg_GF_GroundFaultInhibitTime', 86400, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=True),
@@ -247,7 +251,7 @@ class start(threading.Thread, deviceBase):
'cfgvvoltagemode': Channel('cfgvvoltagemode', 'cfg_V_VoltageMode', 86400, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=True),
'cfgwrite': Channel('cfgwrite', 'cfg_WRITE', 86400, self.sendtodbJSON, writeable=True, e300_param=False),
'contactorstatus': Channel('contactorstatus', 'Contactor_Status', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'devicestatus': Channel('devicestatus', 'Device_Status_INT', 3600, self.sendtodbJSON, writeable=False, e300_param=False, map_obj=device_status),
'devicestatus': Channel('devicestatus', 'Device_Status_INT', 3600, self.sendtodb, writeable=False, e300_param=False, map_obj=device_status),
'dhdownholestatusint': Channel('dhdownholestatusint', 'DH_DownholeStatus_INT', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False),
'dhfluidlevel': Channel('dhfluidlevel', 'DH_Fluid_Level', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False),
'dhintakepressure': Channel('dhintakepressure', 'DH_IntakePressure', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False),
@@ -353,10 +357,10 @@ class start(threading.Thread, deviceBase):
'tripenablevvoltageunbalance': Channel('tripenablevvoltageunbalance', 'TripEnable_V_VoltageUnbalance', 3600, self.sendtodbJSON, writeable=True, e300_param=False),
'tripresetcmd': Channel('tripresetcmd', 'TripResetCmd', 3600, self.sendtodbJSON, writeable=True, e300_param=False),
'tripstatus': Channel('tripstatus', 'TripStatus', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
'tripstatuscontrolint': Channel('tripstatuscontrolint', 'TripStatusControl_INT', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_control),
'tripstatuscurrentint': Channel('tripstatuscurrentint', 'TripStatusCurrent_INT', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_current),
'tripstatuspowerint': Channel('tripstatuspowerint', 'TripStatusPower_INT', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_power),
'tripstatusvoltageint': Channel('tripstatusvoltageint', 'TripStatusVoltage_INT', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_voltage),
'tripstatuscontrolint': Channel('tripstatuscontrolint', 'TripStatusControl_INT', 3600, self.sendtodb, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_control),
'tripstatuscurrentint': Channel('tripstatuscurrentint', 'TripStatusCurrent_INT', 3600, self.sendtodb, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_current),
'tripstatuspowerint': Channel('tripstatuspowerint', 'TripStatusPower_INT', 3600, self.sendtodb, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_power),
'tripstatusvoltageint': Channel('tripstatusvoltageint', 'TripStatusVoltage_INT', 3600, self.sendtodb, writeable=False, change_threshold=1.0, e300_param=False, map_obj=e300_voltage),
'valoverloadtripcount': Channel('valoverloadtripcount', 'val_OverloadTripCount', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False),
'valtripcount': Channel('valtripcount', 'val_TripCount', 3600, self.sendtodbJSON, writeable=False, change_threshold=1.0, e300_param=False),
'voltageok': Channel('voltageok', 'VoltageOK', 3600, self.sendtodbJSON, writeable=False, e300_param=False),
@@ -377,10 +381,10 @@ class start(threading.Thread, deviceBase):
'warningenablevundervoltage': Channel('warningenablevundervoltage', 'WarningEnable_V_Undervoltage', 3600, self.sendtodbJSON, writeable=True, e300_param=False),
'warningenablevvoltageunbalance': Channel('warningenablevvoltageunbalance', 'WarningEnable_V_VoltageUnbalance', 3600, self.sendtodbJSON, writeable=True, e300_param=False),
'warningstatus': Channel('warningstatus', 'WarningStatus', 3600, self.sendtodbJSON, writeable=True, e300_param=False),
'warningstatuscontrolint': Channel('warningstatuscontrolint', 'WarningStatusControl_INT', 3600, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_control),
'warningstatuscurrentint': Channel('warningstatuscurrentint', 'WarningStatusCurrent_INT', 3600, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_current),
'warningstatuspowerint': Channel('warningstatuspowerint', 'WarningStatusPower_INT', 3600, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_power),
'warningstatusvoltageint': Channel('warningstatusvoltageint', 'WarningStatusVoltage_INT', 3600, self.sendtodbJSON, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_voltage),
'warningstatuscontrolint': Channel('warningstatuscontrolint', 'WarningStatusControl_INT', 3600, self.sendtodb, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_control),
'warningstatuscurrentint': Channel('warningstatuscurrentint', 'WarningStatusCurrent_INT', 3600, self.sendtodb, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_current),
'warningstatuspowerint': Channel('warningstatuspowerint', 'WarningStatusPower_INT', 3600, self.sendtodb, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_power),
'warningstatusvoltageint': Channel('warningstatusvoltageint', 'WarningStatusVoltage_INT', 3600, self.sendtodb, writeable=True, change_threshold=1.0, e300_param=False, map_obj=e300_voltage),
}
def __init__(self, name=None, number=None, mac=None, Q=None, mcu=None, companyId=None, offset=None, mqtt=None, Nodes=None):