Skip to content

Instantly share code, notes, and snippets.

View dirkjanfaber's full-sized avatar

Dirk-Jan Faber dirkjanfaber

View GitHub Profile
@dirkjanfaber
dirkjanfaber / README.md
Last active November 9, 2026 20:17
Node-RED subflow: keep the Victron Dynamic ESS sell price in line with a supplier's feed-in bonus (time window, yearly cap), with GX warnings.

Feed-in bonus (Victron Dynamic ESS)

Some energy suppliers pay a bonus on exported solar: an extra share of the market price during part of the day, often up to a yearly cap. Examples are NextEnergy (+50 %, 06:00-22:00, 6,000 kWh) and Zonneplan (+10 %, sunrise to sunset, 7,500 kWh).

This subflow runs once a day on a Victron GX (or any Node-RED with access to the VRM API):

  • reads this year's export from VRM and projects the year total
  • works out the bonus that will really be paid under the cap
  • warns you, also as a GX notification, when export heads past the cap
  • optionally writes the Dynamic ESS sell price in VRM as a schedule: normal price outside the bonus window, price plus bonus inside it
@dirkjanfaber
dirkjanfaber / flow.json
Last active March 13, 2024 09:03
Buy or sell, based on time of day (Node-RED)
[
{
"id": "31b15ddbce69ea1f",
"type": "tab",
"label": "Remco Schilder",
"disabled": false,
"info": "",
"env": []
},
{
@dirkjanfaber
dirkjanfaber / gist:81d51dda52854a30aa1f1b2839e562fc
Last active January 22, 2024 13:53
Dynamic ESS system efficency
[
{
"id": "eb74a53e0e431bfc",
"type": "inject",
"z": "5288063e6fbe9823",
"name": "",
"props": [
{
"p": "payload"
},
@dirkjanfaber
dirkjanfaber / flow.json
Last active November 29, 2023 13:34
Node-Red way to "activate scheduled charge no.4 at 10pm if battery is below x% SoC" with a standard Victron node (no coding required)
[
{
"id": "13b8708c2a084ab6",
"type": "tab",
"label": "Soc based schedule activation",
"disabled": false,
"info": "",
"env": []
},
{
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <stdbool.h>
#include <math.h>
#include <velib/utils/ve_item_utils.h>
#include <velib/vecan/products.h>
#include <velib/utils/ve_logger.h>
@dirkjanfaber
dirkjanfaber / serial-flow.json
Created August 30, 2023 14:31
Node-Red show serial
[
{
"id": "dbd3635678fe7351",
"type": "victron-input-system",
"z": "fc595badb082c140",
"service": "com.victronenergy.system/0",
"path": "/Serial",
"serviceObj": {
"service": "com.victronenergy.system/0",
"name": "Venus system"
@dirkjanfaber
dirkjanfaber / gist:21e262da24411ec2dcf96ce89f8407c2
Last active July 5, 2023 10:57
Graph EskomSePush api calls
[
{
"id": "cd12b4d0f3bb0e8c",
"type": "ui_chart",
"z": "482a4fb117466f9e",
"name": "",
"group": "89d78a937bb98c19",
"order": 0,
"width": 0,
"height": 0,
@dirkjanfaber
dirkjanfaber / two-inputs.json
Created June 23, 2023 19:17
Node Red decision flow based on two inputs
[
{
"id": "188103abad4ff1bc",
"type": "tab",
"label": "2 inputs",
"disabled": false,
"info": "",
"env": []
},
{
@dirkjanfaber
dirkjanfaber / entsoe.json
Last active May 31, 2023 06:37
Entsoe Node-RED interface
[
{
"id": "e78d2a1efd2c46e1",
"type": "subflow",
"name": "Entsoe",
"info": "",
"category": "",
"in": [
{
"x": 220,
@dirkjanfaber
dirkjanfaber / ruuvi-tamper-flow.json
Created May 10, 2023 17:50
Graph Ruuvi tag movement in Node-RED
[
{
"id": "728dba344d605fca",
"type": "victron-input-temperature",
"z": "da916ea9eff5bed3",
"service": "com.victronenergy.temperature/41",
"path": "/AccelX",
"serviceObj": {
"service": "com.victronenergy.temperature/41",
"name": "RuuviTag"