Is there a node which can be used to adjust the input/output current of the Orion XS?
I’m using the Orion XS between the AGM starter battery and the LiFePO4 housebank and it is setup in the VRM as “Charging another battery from the main battery” which is not fully correct but the other option (Alternator charging the main battery) is not correct either.
[{"id":"594858902d0de146","type":"tab","label":"Flow 2","disabled":false,"info":"","env":[]},{"id":"f040ee92a8e4e647","type":"group","z":"594858902d0de146","name":"Alternator controls","style":{"stroke":"#0070c0","label":true},"nodes":["46a03417e049f617","c966bff42f3e2de8","3b573574f26f4377","7fe4fabe61b39ff4","32746a0ad8fa5595","af7c7135ec3fdab8","06398e0e1a8b65b5","0c8d155f18a5c4db","7cec6c55edb57b60","e8c2d1e2ee8ee825","f17c60e7a6f02d7a","2c3786ee0f0beff5","69daf2505017bcf0"],"x":14,"y":19,"w":852,"h":282},{"id":"46a03417e049f617","type":"victron-output-custom","z":"594858902d0de146","g":"f040ee92a8e4e647","service":"com.victronenergy.alternator/278","path":"/Settings/ChargeCurrentLimit","serviceObj":{"service":"com.victronenergy.alternator/278","name":"Orion XS HQ2515PCFQX (278)"},"pathObj":{"path":"/Settings/ChargeCurrentLimit","name":"/Settings/ChargeCurrentLimit","type":"number","value":50},"name":"Set current limit","onlyChanges":false,"outputs":0,"conditionalMode":false,"outputTrue":"","outputFalse":"","debounce":"","x":760,"y":60,"wires":[]},{"id":"c966bff42f3e2de8","type":"victron-virtual-switch","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"Alternator Max Amps","outputs":3,"switch_1_type":"8","switch_1_min":"20","switch_1_max":"50","switch_1_initial":30,"switch_1_label":"","switch_1_unit":"Amps","switch_1_step":5,"switch_1_customname":"Max Charging Amps","switch_1_group":"5 Alternator Controls","switch_1_include_measurement":false,"switch_1_rgb_color_wheel":false,"switch_1_cct_wheel":false,"switch_1_rgb_white_dimmer":false,"x":140,"y":140,"wires":[[],[],["e8c2d1e2ee8ee825"]]},{"id":"3b573574f26f4377","type":"victron-virtual-switch","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"Alternator ON/OFF","outputs":2,"switch_1_type":1,"switch_1_initial":0,"switch_1_label":"","switch_1_customname":"Alternator ON/OFF","switch_1_group":"5 Alternator Controls","switch_1_include_measurement":false,"switch_1_rgb_color_wheel":false,"switch_1_cct_wheel":false,"switch_1_rgb_white_dimmer":false,"x":130,"y":80,"wires":[[],["7cec6c55edb57b60"]]},{"id":"7fe4fabe61b39ff4","type":"victron-input-custom","z":"594858902d0de146","g":"f040ee92a8e4e647","service":"com.victronenergy.alternator/278","path":"/Settings/ChargeCurrentLimit","serviceObj":{"service":"com.victronenergy.alternator/278","name":"Orion XS HQ2515PCFQX (278)"},"pathObj":{"path":"/Settings/ChargeCurrentLimit","name":"/Settings/ChargeCurrentLimit","type":"number","value":50},"name":"Read Current limit","onlyChanges":true,"roundValues":"no","rateLimit":0,"outputs":1,"conditionalMode":false,"outputTrue":"true","outputFalse":"false","debounce":"2000","x":130,"y":200,"wires":[["f17c60e7a6f02d7a"]]},{"id":"32746a0ad8fa5595","type":"inject","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"30","payloadType":"num","x":550,"y":60,"wires":[["46a03417e049f617"]]},{"id":"af7c7135ec3fdab8","type":"inject","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"50","payloadType":"num","x":550,"y":100,"wires":[["46a03417e049f617"]]},{"id":"06398e0e1a8b65b5","type":"victron-output-custom","z":"594858902d0de146","g":"f040ee92a8e4e647","service":"com.victronenergy.alternator/278","path":"/Mode","serviceObj":{"service":"com.victronenergy.alternator/278","name":"Orion XS HQ2515PCFQX (278)"},"pathObj":{"path":"/Mode","name":"/Mode","type":"number","value":1},"name":"Set mode on/off","onlyChanges":false,"outputs":0,"conditionalMode":false,"outputTrue":"","outputFalse":"","debounce":"","x":760,"y":120,"wires":[]},{"id":"0c8d155f18a5c4db","type":"victron-input-alternator","z":"594858902d0de146","g":"f040ee92a8e4e647","service":"com.victronenergy.alternator/278","path":"/Mode","serviceObj":{"service":"com.victronenergy.alternator/278","name":"Orion XS HQ2515PCFQX","communityTag":"alternator"},"pathObj":{"path":"/Mode","type":"enum","name":"Mode","enum":{"1":"On","4":"Off"}},"name":"DC charger on/off","onlyChanges":true,"roundValues":"no","rateLimit":0,"outputs":1,"conditionalMode":false,"outputTrue":"true","outputFalse":"false","debounce":"2000","x":120,"y":260,"wires":[["2c3786ee0f0beff5"]]},{"id":"7cec6c55edb57b60","type":"function","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"tag: mode button","func":"msg.alt_source = \"mode_button\";\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":370,"y":60,"wires":[["69daf2505017bcf0"]]},{"id":"e8c2d1e2ee8ee825","type":"function","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"tag: amps button","func":"msg.alt_source = \"amps_button\";\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":370,"y":120,"wires":[["69daf2505017bcf0"]]},{"id":"f17c60e7a6f02d7a","type":"function","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"tag: limit read","func":"msg.alt_source = \"limit_read\";\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":340,"y":200,"wires":[["69daf2505017bcf0"]]},{"id":"2c3786ee0f0beff5","type":"function","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"tag: mode read","func":"msg.alt_source = \"mode_read\";\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":320,"y":260,"wires":[["69daf2505017bcf0"]]},{"id":"69daf2505017bcf0","type":"function","z":"594858902d0de146","g":"f040ee92a8e4e647","name":"Alternator controls sync","func":"const MIN_AMPS = 20;\nconst MAX_AMPS = 50;\nconst STEP = 5;\n\nfunction getNum(v) {\n if (typeof v === \"number\") return v;\n if (typeof v === \"boolean\") return v ? 1 : 0;\n if (typeof v === \"string\" && v.trim() !== \"\") return Number(v);\n if (v && typeof v === \"object\") {\n const keys = [\n \"value\",\n \"Value\",\n \"payload\",\n \"state\",\n \"State\",\n \"Dimming\",\n \"/Mode\",\n \"/Settings/ChargeCurrentLimit\",\n \"/SwitchableOutput/output_1/State\",\n \"/SwitchableOutput/output_1/Dimming\"\n ];\n for (let i = 0; i < keys.length; i++) {\n if (v[keys[i]] !== undefined) return getNum(v[keys[i]]);\n }\n }\n return NaN;\n}\n\nfunction clamp(v, min, max) {\n v = Number(v);\n if (!isFinite(v)) return min;\n return Math.min(max, Math.max(min, v));\n}\n\nfunction clampAmps(v) {\n v = clamp(v, MIN_AMPS, MAX_AMPS);\n v = Math.round(v / STEP) * STEP;\n return clamp(v, MIN_AMPS, MAX_AMPS);\n}\n\nfunction uiMode(on) {\n return {\n topic: \"alt_mode_ui\",\n _altFeedback: true,\n payload: {\"/SwitchableOutput/output_1/State\": on ? 1 : 0}\n };\n}\n\nfunction uiAmps(amps) {\n return {\n topic: \"alt_amps_ui\",\n _altFeedback: true,\n payload: {\"/SwitchableOutput/output_1/Dimming\": amps}\n };\n}\n\nfunction writeMode(mode, reason) {\n return {\n topic: \"/Mode\",\n payload: mode,\n reason: reason\n };\n}\n\nfunction writeLimit(amps, reason) {\n return {\n topic: \"/Settings/ChargeCurrentLimit\",\n payload: amps,\n reason: reason\n };\n}\n\nconst src = msg.alt_source || \"\";\nconst raw = getNum(msg.payload);\n\nif (!isFinite(raw)) {\n node.status({fill:\"red\", shape:\"ring\", text:\"bad payload\"});\n return null;\n}\n\nif (msg._altFeedback) {\n node.status({fill:\"grey\", shape:\"ring\", text:\"feedback ignored\"});\n return null;\n}\n\nif (src === \"mode_button\") {\n const on = raw === 1;\n const mode = on ? 1 : 4;\n context.set(\"mode\", mode);\n node.status({fill:on ? \"green\" : \"grey\", shape:\"dot\", text:on ? \"mode on\" : \"mode off\"});\n return [writeMode(mode, on ? \"button on\" : \"button off\"), uiMode(on), null, null];\n}\n\nif (src === \"mode_read\") {\n const mode = Number(raw);\n if (mode !== 1 && mode !== 4) {\n node.status({fill:\"yellow\", shape:\"ring\", text:\"mode read \" + mode});\n return null;\n }\n const on = mode === 1;\n context.set(\"mode\", mode);\n node.status({fill:on ? \"green\" : \"grey\", shape:\"dot\", text:on ? \"read mode on\" : \"read mode off\"});\n return [null, uiMode(on), null, null];\n}\n\nif (src === \"amps_button\") {\n const amps = clampAmps(raw);\n context.set(\"amps\", amps);\n node.status({fill:\"blue\", shape:\"dot\", text:\"set \" + amps + \"A\"});\n return [null, null, writeLimit(amps, \"button amps\"), uiAmps(amps)];\n}\n\nif (src === \"limit_read\") {\n const amps = clampAmps(raw);\n context.set(\"amps\", amps);\n node.status({fill:\"blue\", shape:\"ring\", text:\"read \" + amps + \"A\"});\n return [null, null, null, uiAmps(amps)];\n}\n\nnode.status({fill:\"yellow\", shape:\"ring\", text:\"unknown source\"});\nreturn null;","outputs":4,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":570,"y":220,"wires":[["06398e0e1a8b65b5"],["3b573574f26f4377"],["46a03417e049f617"],["c966bff42f3e2de8"]]},{"id":"cd1b632230a83366","type":"global-config","env":[],"modules":{"@victronenergy/node-red-contrib-victron":"1.6.64"}}]
this is what I made to adjust those settings you can just use the injects to see for yourself, let me know how it goes!
Thanks Osher, it works indeed when the Orion XS is setup as “Alternator charging the main battery”.
When setup as “Charging another battery from the main battery” the “/Settings/ChargeCurrentLimit” option is not available.
Strange situation as the Orion XS is often used to charge the main (LiFePO4) battery from the (AGM) starter battery.
That’s what Victron even shows on their Orion XS webpage.
Effectively your system is “Alternator charging the main battery”. Your engine alternator is connected directly to the start battery, typically via the starter motor, you have then connected your Orion XS to the start battery, so it is in effect in parallel with your start battery, both being charged/supplied by your alternator. You should have engine shut-down detection enabled, or better still ignition connected to the H terminal, so that the Orion will only run when engine is running, assuming you don’t sit there for hours-on-end with the ignition on and engine not running.
The Orion XS starts to transfer energy based on sensed starter battery voltage.
Either the alternator OR the Skylla IP65 charger is responsible for the higher starter battery voltage resulting in energy transfer so the tile should be named “Orion XS” as it is the Orion which is responsible for the charging even when the engine is not running.
It would be better if the Orion had the additional option “Charging the main battery from the starter battery” as per the picture here next to “Configurable voltage and current”.
I get what you’re saying. But you’re supposed to be using your boat/RV (when power is coming from the alternator) and not parked up and connected to shorepower!
Any additional option (as you propose) is exactly the same as charging from the alternator.