I'm trying to configure the interface of a Venus GX and also a CCGX, the idea is for the user to be able to set the values de Charge Voltage Limit (CVL), Charge Current Limit (CCL)and Discharge Current Limit (DCL), as in the image below:
I started by copying an example:
In your QML file, it looks like this:
MbSpinBox { id: minSocLimit description: qsTr("Minimum SOC (unless grid fails)") enabled: userHasWriteAccess show: hub4Mode.value !== hub4Disabled && stateItem.value !== batteryKeepCharged bind: Utils.path(batteryLifePath, "/MinimumSocLimit") numOfDecimals: 0 unit: "%" min: 0 max: 100 stepSize: 5 }
I'm at the very beginning of my studies, as you can see, and I tried as follows:
MbSpinBox { id: maxChargeVoltage description: qsTr("Charge Voltage Limit (CVL)") enabled: userHasWriteAccess show: valid && showSetting(0) bind: service.path("/Info/MaxChargeVoltage") numOfDecimals: 0 unit: "%" min: 0 max: 100 stepSize: 0.5 }
Could someone please direct me to where I should go, I believe I'm missing the path of bind, show, and property that is at the beginning of the file:
property string bindPrefix property string bindPage: "/Settings/Battery/" property string cgwacsPath: "com.victronenergy.settings/Settings/CGwacs" property string settingsPrefix: "com.victronenergy.settings" property string batteryLifePath: cgwacsPath + "/BatteryLife" // Hub4Mode property int hub4PhaseCompensation: 1 property int hub4PhaseSplit: 2 property int hub4Disabled: 3 // BatteryLifeState property int batteryLifeStateDisabled: 0 property int batteryLifeStateRestart: 1 property int batteryLifeStateDefault: 2 property int batteryLifeStateAbsorption: 3 property int batteryLifeStateFloat: 4 property int batteryLifeStateDischarged: 5 property int batteryLifeStateForceCharge: 6 property int batteryLifeStateSustain: 7 property int batteryLifeStateLowSocCharge: 8 property int batteryKeepCharged: 9 property int batterySocGuardDefault: 10 property int batterySocGuardDischarged: 11 property int batterySocGuardLowSocCharge: 12 property VBusItemCheckValid maxVoltageCellId: VBusItemCheckValid { bind: Utils.path(bindPrefix, "/System/MaxVoltageCellId") } property VBusItem systemType: VBusItem { bind: "com.victronenergy.system/SystemType" } property VBusItem gridSetpoint: VBusItem { bind: "com.victronenergy.settings/Settings/CGwacs/AcPowerSetPoint" } property VBusItem maxChargePowerItem: VBusItem { bind: Utils.path(cgwacsPath, "/MaxChargePower") } property VBusItem maxDischargePowerItem: VBusItem { bind: Utils.path(cgwacsPath, "/MaxDischargePower") } property VBusItem socLimitItem: VBusItem { bind: Utils.path(batteryLifePath, "/SocLimit") } property VBusItem minSocLimitItem: VBusItem { bind: Utils.path(batteryLifePath, "/MinimumSocLimit") } property VBusItem stateItem: VBusItem { bind: Utils.path(batteryLifePath, "/State") } property VBusItem hub4Mode: VBusItem { bind: Utils.path(cgwacsPath, "/Hub4Mode") } property VBusItem maxChargeCurrentControl: VBusItem { bind: "com.victronenergy.system/Control/MaxChargeCurrent" } property string bindPrefix property string bindPage: "/Settings/Battery/" property bool locked: lock.valid && lock.value property string cgwacsPath: "com.victronenergy.settings/Settings/CGwacs" property string settingsPrefix: "com.victronenergy.settings" property string batteryLifePath: cgwacsPath + "/BatteryLife" // Hub4Mode property int hub4PhaseCompensation: 1 property int hub4PhaseSplit: 2 property int hub4Disabled: 3 // BatteryLifeState property int batteryLifeStateDisabled: 0 property int batteryLifeStateRestart: 1 property int batteryLifeStateDefault: 2 property int batteryLifeStateAbsorption: 3 property int batteryLifeStateFloat: 4 property int batteryLifeStateDischarged: 5 property int batteryLifeStateForceCharge: 6 property int batteryLifeStateSustain: 7 property int batteryLifeStateLowSocCharge: 8 property int batteryKeepCharged: 9 property int batterySocGuardDefault: 10 property int batterySocGuardDischarged: 11 property int batterySocGuardLowSocCharge: 12 property VBusItem systemType: VBusItem { bind: "com.victronenergy.system/SystemType" } property VBusItem gridSetpoint: VBusItem { bind: "com.victronenergy.settings/Settings/CGwacs/AcPowerSetPoint" } property VBusItem maxChargePowerItem: VBusItem { bind: Utils.path(cgwacsPath, "/MaxChargePower") } property VBusItem maxDischargePowerItem: VBusItem { bind: Utils.path(cgwacsPath, "/MaxDischargePower") } property VBusItem socLimitItem: VBusItem { bind: Utils.path(batteryLifePath, "/SocLimit") } property VBusItem minSocLimitItem: VBusItem { bind: Utils.path(batteryLifePath, "/MinimumSocLimit") } property VBusItem stateItem: VBusItem { bind: Utils.path(batteryLifePath, "/State") } property VBusItem hub4Mode: VBusItem { bind: Utils.path(cgwacsPath, "/Hub4Mode") } property VBusItem maxChargeCurrentControl: VBusItem { bind: "com.victronenergy.system/Control/MaxChargeCurrent"
Does anyone have any idea how I should proceed, or where do I find information about it?
Thank you!