UNPKG

iobroker.e3oncan

Version:

Collect data on CAN bus for Viessmann E3 devices, e.g. Vitocal, Vitocharge, Energy Meters E380CA and E3100CB

724 lines (723 loc) 30.2 kB
{ "i18n": true, "type": "tabs", "tabsStyle": { "width": "calc(100% - 100px)" }, "items": { "tabCanAdapter": { "type": "panel", "xs": 12, "sm": 12, "md": 6, "lg": 4, "xl": 4, "label": "CAN Adapter", "items": { "introTabCanInstanceNotActiveTxt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Please start this adapter instance to enable further configuration options.", "newLine": true, "hidden": "_alive", "style": { "color": "red" } }, "introTabCanPressSaveTxt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Please press button 'Save', when you're done on this tab.", "newLine": true, "hidden": "!_changed", "style": { "color": "red" } }, "canExtHeader": { "type": "header", "text": "UDS CAN Adapter", "size": 2, "newLine": true }, "canExtName": { "xs": 12, "sm": 2, "md": 2, "lg": 2, "xl": 2, "type": "text", "tooltip": "Device mame of CAN adapter connected to UDS-capable bus, e.g. can0", "default": "can0", "newLine": false }, "canExtActivated": { "xs": 12, "sm": 4, "md": 4, "lg": 4, "xl": 4, "type": "checkbox", "label": "Connect to Adapter", "tooltip": "Check, if this adapter shall be used.", "default": false, "newLine": false }, "canIntHeader": { "type": "header", "text": "Second CAN Adapter", "size": 2, "newLine": true }, "canIntName": { "xs": 12, "sm": 2, "md": 2, "lg": 2, "xl": 2, "type": "text", "tooltip": "Device mame of CAN adapter connected to second bus, e.g. can1", "default": "can1", "newLine": false }, "canIntActivated": { "xs": 12, "sm": 4, "md": 4, "lg": 4, "xl": 4, "type": "checkbox", "label": "Connect to Adapter", "tooltip": "Check, if this adapter shall be used.", "default": false, "newLine": false } } }, "tabUdsDevices": { "type": "panel", "xs": 12, "sm": 12, "md": 6, "lg": 4, "xl": 4, "label": "List of UDS devices", "hidden": "if (!data.canExtActivated) { return true; } else {return false; }", "items": { "tableUdsDevicesHdr": { "type": "header", "text": "List of available devices", "size": 2 }, "tableUdsDevicesWarning": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Configuration requires a running adapter instance!", "hidden": "_alive", "newLine": true, "style": { "color": "red" } }, "introTabUdsDevicesSaveTxt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Please press button 'Save', when you're done on this tab.", "newLine": true, "hidden": "!_changed", "style": { "color": "red" } }, "introtableUdsDevicesTxt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "You may edit 2nd column to set name of state for the device (visible in object tree).", "hidden": "if ((data.tableUdsDevices) && (data.tableUdsDevices.length > 0)) { return true; } else {return false; }", "newLine": true }, "introTableNoEmptyDevNameTxt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "'Device state name' must not be blank!", "newLine": true, "hidden": "if ( (data.tableUdsDevices) && (data.tableUdsDevices.length > 0) ) {for (const c of data.tableUdsDevices) {if (c.devStateName === '') return false;}; return true;} else return true;", "style": { "color": "red" } }, "introTableNoDotInDevNameTxt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Symbol '.' not allowed in 'Device state name'!", "newLine": true, "hidden": "if ( (data.tableUdsDevices) && (data.tableUdsDevices.length > 0) ) {for (const c of data.tableUdsDevices) {if (c.devStateName.includes('.')) return false;}; return true;} else return true;", "style": { "color": "red" } }, "tableUdsDevicesButton": { "type": "sendTo", "label": "Start scan to update list of devices", "variant": "outlined", "showProcess": true, "command": "getUdsDevices", "jsonData": "{}", "useNative": true, "hidden": "!_alive", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12 }, "tableUdsDevices": { "type": "table", "uniqueColumns": [ "devStateName" ], "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "label": "List of available devices", "hidden": "!_alive", "noDelete": true, "import": true, "export": true, "items": [ { "type": "text", "attr": "devName", "width": "10% ", "title": "Device name (Viessmann)", "tooltip": "Device ECU name (fixed)", "filter": false, "sort": false, "readOnly": true }, { "type": "text", "attr": "devStateName", "width": "15% ", "title": "Device state name", "tooltip": "Device name in object tree. Must not contain dots.", "filter": false, "sort": false, "validator": "if ( (data.devStateName === '') || (data.devStateName.includes('.')) ) { return false; } else { return true; }", "validatorNoSaveOnError": true }, { "type": "text", "attr": "devUnits", "width": "15% ", "title": "Data formats used by the device", "tooltip": "Device is using these formats for numbers, date and time", "default": "", "filter": false, "sort": false, "readOnly": true }, { "type": "text", "attr": "devAddr", "width": "10% ", "title": "Device Address", "tooltip": "Device ECU address (fixed)", "filter": false, "sort": false, "readOnly": true }, { "type": "text", "attr": "collectCanId", "width": "10% ", "title": "CAN id for collecting data", "tooltip": "CAN id - still experimental. Leave blank for deactivation.", "filter": false, "sort": false, "readOnly": false } ] }, "energyMeterHdr": { "type": "header", "text": "Energy meters on CAN bus", "size": 3, "newLine": true }, "energyMeterHint": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Detected during last device scan. Run scan to update.", "newLine": true }, "energyMeterDetectionResult": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "text", "label": "Detected energy meters", "readOnly": true, "newLine": true } } }, "tabUdsDids": { "type": "panel", "label": "List of datapoints", "hidden": "if ((data.tableUdsDevices) && (data.tableUdsDevices.length == 0)) { return true; } else {return false; }", "xs": 12, "sm": 12, "md": 6, "lg": 4, "xl": 4, "items": { "tableUdsDidsWarning": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Configuration requires a running adapter instance!", "hidden": "_alive", "newLine": true, "style": { "color": "red" } }, "saveDidsOnScan": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "checkbox", "label": "Save all data point values to object tree during scan", "tooltip": "When unchecked, values and metadata are updated for already existing data point objects only. New data point objects are not created during the scan — they are created automatically on first data receipt after the scan.", "default": true, "newLine": true }, "tableUdsDidsStartScan": { "type": "sendTo", "label": "Start scan for datapoints of all devices", "variant": "outlined", "showProcess": true, "jsonData": "{\"saveDidsOnScan\": ${data.saveDidsOnScan}}", "command": "startDidScan", "confirm": { "condition": "true", "title": "Confirm scan for datapoints", "text": "Scan will take up to 5 minutes. Please make sure, no other UDSonCAN client (e.g. Open3Eclient.py) is running. Please do not close the tab during scan. You may follow up the progress by watching the Log in an additional tab.", "ok": "OK", "cancel": "Cancel" }, "hidden": "!_alive", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12 }, "tableUdsDidsDivider": { "type": "divider", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12 }, "tableUdsDidsHint1": { "type": "staticText", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "text": "Run the scan above to discover all data points on your devices and add metadata (description, unit, access). This is required before writing to any data point and recommended after every adapter or device firmware update.", "style": { "fontSize": "150%" } }, "tableUdsDidsHint2": { "type": "staticText", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "text": "► After the scan, browse and manage the discovered data points using the 'datapoints page', which is accessible via the link button in the adapter's instance row.", "style": { "fontSize": "150%" } }, "tableUdsDidsHint3": { "type": "staticText", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "text": "► Alternatively, you can use the tab 'Assignments to UDS CAN Adapter' within this configuration dialog.", "style": { "fontSize": "150%" } } } }, "tabCanAdapterExt": { "type": "panel", "xs": 12, "sm": 12, "md": 6, "lg": 4, "xl": 4, "label": "Assignments to UDS CAN Adapter", "hidden": "if ((data.tableUdsDevices) && (data.tableUdsDevices.length == 0)) { return true; } else {return false; }", "items": { "tableCanAdapterExtWarning": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Configuration requires a running adapter instance!", "hidden": "_alive", "newLine": true, "style": { "color": "red" } }, "tableHdrCol": { "type": "header", "text": "Collecting Data on UDS CAN Adapter", "size": 2 }, "introTableColExt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Devices for collecting data. No writing to CAN bus. Press '+' to add device.", "hidden": "if (data.tableUdsDevices) {for(let i=0; i<data.tableUdsDevices.length; i++){if (data.tableUdsDevices[i].collectCanId != '') return false;}; return true;} else {return true;}", "newLine": true }, "introTableColExtNoDevs": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "No device for collecting available (missing CAN ID).", "hidden": "if (data.tableUdsDevices) {for(let i=0; i<data.tableUdsDevices.length; i++){if (data.tableUdsDevices[i].collectCanId != '') return true;}; return false;} else {return false;}", "newLine": true }, "tableColExtErrDevName": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "ERROR: column 'Device state name' must contain unique text.", "newLine": true, "hidden": "const x={}; for(let ii=0; data.tableCollectCanExt && ii<data.tableCollectCanExt.length; ii++){const t=data.tableCollectCanExt[ii].collectCanId; if (x[t]==='x') return false; x[t]='x';}; return true;", "style": { "color": "red" } }, "tableCollectCanExt": { "type": "table", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "label": "", "hidden": "if (data.tableUdsDevices) {for(let i=0; i<data.tableUdsDevices.length; i++){if (data.tableUdsDevices[i].collectCanId != '') return false;}; return true;} else {return true;}", "showSecondAddAt": 5, "items": [ { "type": "checkbox", "attr": "collectActive", "width": "5% ", "title": "active", "tooltip": "Activate communication", "filter": false, "sort": false, "default": true }, { "type": "selectSendTo", "title": "Select device", "command": "getExtColDeviceSelect", "attr": "collectCanId", "jsonData": "${JSON.stringify(globalData.tableUdsDevices)}", "width": "15%", "default": "Select device", "alsoDependsOn": [ "collectActive", "tableUdsDevices" ], "newLine": false, "validator": "if (data.collectCanId === 'Select device') { return false; } else { return true; }", "validatorNoSaveOnError": true }, { "type": "number", "attr": "collectDelayTime", "width": "15% ", "title": "Min. update time (s)", "tooltip": "Minumum update time for states. 0 for immediate update.", "filter": false, "sort": false, "min": 0, "step": 1, "default": 5 } ] }, "tableHdrUds": { "type": "header", "text": "Requesting data on UDS CAN Adapter via UDSonCAN", "size": 2 }, "introTableUds": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Specify schedules for devices, press '+' to begin.", "newLine": true }, "tableUdsSchedules": { "type": "table", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "label": "", "showSecondAddAt": 5, "items": [ { "type": "checkbox", "attr": "udsScheduleActive", "width": "5% ", "title": "active", "tooltip": "Activate communication", "filter": false, "sort": false, "default": true }, { "type": "number", "attr": "udsSchedule", "width": "10% ", "title": "Schedule (s)", "tooltip": "Schedule for requesting given datapoints. 0 for one time request on start of adapter instance.", "filter": false, "sort": false, "min": 0, "step": 1, "default": 0 }, { "type": "selectSendTo", "title": "Select device", "command": "getUdsDeviceSelect", "attr": "udsSelectDevAddr", "jsonData": "${JSON.stringify(globalData.tableUdsDevices)}", "width": "15%", "default": "Select device", "alsoDependsOn": [ "udsSchedule", "tableUdsDevices" ], "newLine": false, "validator": "if (data.udsSelectDevAddr === 'Select device') { return false; } else { return true; }", "validatorNoSaveOnError": true }, { "type": "text", "attr": "udsScheduleDids", "width": "30% ", "title": "List of datapoints", "tooltip": "Separate by comma! All given datapoints will be requested with specified schedule and ECU address.", "filter": false, "sort": false, "default": "256" }, { "type": "text", "attr": "udsScheduleUserComment", "width": "30% ", "title": "Description", "tooltip": "Optional description of this schedule.", "filter": false, "sort": false, "default": "" } ] } } }, "tabCanAdapterInt": { "type": "panel", "xs": 12, "sm": 12, "md": 6, "lg": 4, "xl": 4, "label": "Assignments to second CAN Adapter", "hidden": "return !data.canIntActivated;", "items": { "tableHdr": { "type": "header", "text": "Collecting Data on second CAN Adapter", "size": 2 }, "introTableColInt": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Devices for collecting data. No writing to CAN bus. Press '+' to add device.", "newLine": true }, "tableCanAdapterIntWarning": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "Configuration requires a running adapter instance!", "hidden": "_alive", "newLine": true, "style": { "color": "red" } }, "tableColIntErrDevName": { "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "type": "staticText", "text": "ERROR: column 'Device state name' must contain unique text.", "newLine": true, "hidden": "const x={}; for(let ii=0; data.tableCollectCanInt && ii<data.tableCollectCanInt.length; ii++){const t=data.tableCollectCanInt[ii].collectCanId; if (x[t]==='x') return false; x[t]='x';}; return true;", "style": { "color": "red" } }, "tableCollectCanInt": { "type": "table", "newLine": true, "xs": 12, "sm": 12, "md": 12, "lg": 12, "xl": 12, "label": "", "showSecondAddAt": 5, "items": [ { "type": "checkbox", "attr": "collectActive", "width": "5% ", "title": "active", "tooltip": "Activate communication", "filter": false, "sort": false, "default": true }, { "type": "selectSendTo", "title": "Select device", "command": "getIntColDeviceSelect", "attr": "collectCanId", "jsonData": "${JSON.stringify(globalData.tableUdsDevices)}", "width": "15%", "default": "Select device", "alsoDependsOn": [ "collectActive", "tableUdsDevices" ], "newLine": false, "validator": "if (data.collectCanId === 'Select device') { return false; } else { return true; }", "validatorNoSaveOnError": true }, { "type": "number", "attr": "collectDelayTime", "width": "15% ", "title": "Min. update time (s)", "tooltip": "Minumum update time for states. 0 for immediate update.", "filter": false, "sort": false, "min": 0, "step": 1, "default": 5 } ] } } } } }