after having installed and configured driver dbus-aggregate-batteries, I realized that the driver remains empty after a start.
My setup is 4 LiFePO4 battery banks, each with 16 cells. The first two battery banks each have an individual BMS and make use of ProductName "SerialBattery(Jkbms)" and have custom names Bat01 and Bat02. Furthermore, the last two battery banks make use of a CAN-SMARTBMS-BAT that manages both battery banks, i.e. Bat03 and Bat04. Its custom name is Bat03/Bat04.
This is the resulting output:
INFO:root:Mon Oct 9 22:11:25 2023: Starting AggregateBatteries.
INFO:root:registered ourselves on D-Bus as com.victronenergy.battery.aggregate
INFO:root:Mon Oct 9 22:11:25 2023: Initial Ah read from file: 280Ah
INFO:root:Mon Oct 9 22:11:25 2023: Last balancing done at the 175. day of the year
INFO:root:Mon Oct 9 22:11:25 2023: Starting battery monitor.
INFO:root:Mon Oct 9 22:11:25 2023: Connected to DBus, and switching over to GLib.MainLoop()
INFO:dbusmonitor:===== Search on dbus for services that we will monitor starting... =====
INFO:dbusmonitor:Found: com.victronenergy.battery.ttyUSB2, scanning and storing items
INFO:dbusmonitor: com.victronenergy.battery.ttyUSB2 has device instance 2
INFO:dbusmonitor:Found: com.victronenergy.solarcharger.socketcan_can0_vi0_uc211136, scanning and storing items
INFO:dbusmonitor: com.victronenergy.solarcharger.socketcan_can0_vi0_uc211136 has device instance 0
INFO:dbusmonitor:Found: com.victronenergy.settings, scanning and storing items
INFO:dbusmonitor: com.victronenergy.settings has device instance 0
INFO:dbusmonitor:Found: com.victronenergy.battery.socketcan_can1, scanning and storing items
INFO:dbusmonitor: com.victronenergy.battery.socketcan_can1 has device instance 512
INFO:dbusmonitor:Found: com.victronenergy.battery.socketcan_can0_vi0_uc171335, scanning and storing items
INFO:dbusmonitor: com.victronenergy.battery.socketcan_can0_vi0_uc171335 has device instance 0
INFO:root:Mon Oct 9 22:11:26 2023: Searching Settings: Trial Nr. 1
INFO:root:Mon Oct 9 22:11:26 2023: com.victronenergy.settings found.
INFO:dbusmonitor:Found: com.victronenergy.vebus.ttyS4, scanning and storing items
INFO:dbusmonitor: com.victronenergy.vebus.ttyS4 has device instance 276
INFO:dbusmonitor:Found: com.victronenergy.solarcharger.socketcan_can0_vi2_uc270152, scanning and storing items
INFO:dbusmonitor: com.victronenergy.solarcharger.socketcan_can0_vi2_uc270152 has device instance 2
INFO:dbusmonitor:Found: com.victronenergy.battery.aggregate, scanning and storing items
INFO:dbusmonitor: com.victronenergy.battery.aggregate has device instance 0
INFO:dbusmonitor:Found: com.victronenergy.battery.ttyUSB1, scanning and storing items
INFO:dbusmonitor: com.victronenergy.battery.ttyUSB1 has device instance 1
INFO:dbusmonitor:===== Search on dbus for services that we will monitor finished =====
INFO:root:Mon Oct 9 22:11:31 2023: Searching batteries: Trial Nr. 1
INFO:root:Mon Oct 9 22:11:31 2023: SerialBattery(Jkbms) found, named as: Bat02.
INFO:root:Mon Oct 9 22:11:31 2023: CAN-SMARTBMS-BAT found, named as: Bat03/04.
ERROR:root:Mon Oct 9 22:11:31 2023: Number of cells of batteries is not correct. Exiting.
This is my current configuration in settings.py:
# Version 3.0
#######################################
########## Hardware settings ##########
#######################################
NR_OF_BATTERIES = 4 # Nr. of physical batteries to be aggregated
NR_OF_CELLS_PER_BATTERY = 16
NR_OF_MPPTS = 3 # Nr. of MPPTs
DC_LOADS = False # If DC loads with Smart Shunt present, can be used for total current measurement
INVERT_SMARTSHUNT = False # False: Current subtracted, True: Current added
#######################################
############ DBus settings ############
#######################################
BATTERY_SERVICE_NAME = 'com.victronenergy.battery' # Key word to identify services of physical Serial Batteries (and SmartShunt if available)
BATTERY_PRODUCT_NAME_PATH = '/ProductName' # Path of Battery Product Name
BATTERY_PRODUCT_NAME1 = 'SerialBattery(Jkbms)' # Key word to identify the batteries (to exclude SmartShunt)
BATTERY_PRODUCT_NAME2 = 'CAN-SMARTBMS-BAT' # Key word to identify the batteries (to exclude SmartShunt)
BATTERY_INSTANCE_NAME_PATH = '/CustomName' # if CustomName doesn't exist, set '/ProductName'
MULTI_KEY_WORD = 'com.victronenergy.vebus' # Key word to identify service of Multis/Quattros (or cluster of them)
MPPT_KEY_WORD = 'com.victronenergy.solarcharger' # Key word to identify services of solar chargers
SMARTSHUNT_NAME_KEY_WORD = 'SmartShunt' # Key word to identify services of SmartShunt
SEARCH_TRIALS = 10 # Trials to identify of all batteries before exit and restart
READ_TRIALS = 10 # Trials to get consistent data of all batteries before exit and restart
#######################################
############ DBus settings ############
#######################################
CURRENT_FROM_VICTRON = True # If True, the current measurement by Multis/Quattros and MPPTs is taken instead of BMS
OWN_SOC = True # If True, the self calculated charge indicators are taken instead of BMS
CHARGE_SAVE_PRECISION = 0.0025 # Trade-off between save precision and file access frequency
#######################################
##### Charge/Discharge parameters #####
#######################################
# Please note: Victron EES disables CCL if DC-coupled PV feed-in is active
OWN_CHARGE_PARAMETERS = True # Calculate own charge/discharge control parameters (True) from following settings
# or use them from battery driver (False)
CHARGE_VOLTAGE = 3.40 # Constant voltage charge = this value * nr. of cells
BALANCING_VOLTAGE = 3.45 # This voltage per cell will be set periodically and kept until balancing below CELL_DIFF_MAX and next charge cycle
BALANCING_REPETITION = 10 # in days
MAX_CELL_VOLTAGE = 3.50 # If reached by 1-st cell, the CVL is dynamically limited. DC-coupled PV feed-in will be disabled to enable the CCL.
DISCHARGE_VOLTAGE = 3.10 # If reached, discharge current set to zero
MIN_CELL_VOLTAGE = 2.90 # If reached, discharge current set to zero
CELL_DIFF_MAX = 0.025 # If lower: re-enable DC-coupled PV feed in (if was enabled before); go back from BALANCING_VOLTAGE to CHARGE_VOLTAGE
MAX_CHARGE_CURRENT = 480 # Max. charge current at normal conditions
MAX_DISCHARGE_CURRENT = 225 # Max. discharge current at normal conditions
# settings limiting charge and discharge current if at least one cell gets full or empty
# the lists may have any length, but the same length for voltage and current
# linear interpolation is used for values between
CELL_FULL_LIMITING_VOLTAGE = [CHARGE_VOLTAGE, BALANCING_VOLTAGE, MAX_CELL_VOLTAGE] # [min, .... ,max]
CELL_FULL_LIMITED_CURRENT = [1, 0.05, 0]
CELL_EMPTY_LIMITING_VOLTAGE = [DISCHARGE_VOLTAGE - 0.1, DISCHARGE_VOLTAGE, MIN_CELL_VOLTAGE] # [min, .... ,max]
CELL_EMPTY_LIMITED_CURRENT = [0, 0.05, 1]
#######################################
####### Logging and reporting #########
#######################################
SEND_CELL_VOLTAGES = 0 # 0: Disable Cell Info in dbus, 1: Format: /Cell/BatteryName_Cell<ID>
LOGGING = 2 # 0: no logging, 1: print to console, 2: print to file
LOG_PERIOD = 600 # in seconds; if 0, periodic logging is disabled
Does anybody have a hint as how to configure dbus-aggregate-batteries based on the specific setup of having multiple battery banks where the individual BMS manage a different number of cells?
Hi Peter, your CAN batteries present themselves as a single battery. You can try setting NR_OF_BATTERIES = 3. But if you connect different batteries in parallel the current distribution may be incorrect.
Hi,
after having installed and configured driver dbus-aggregate-batteries, I realized that the driver remains empty after a start.
My setup is 4 LiFePO4 battery banks, each with 16 cells. The first two battery banks each have an individual BMS and make use of ProductName "SerialBattery(Jkbms)" and have custom names Bat01 and Bat02. Furthermore, the last two battery banks make use of a CAN-SMARTBMS-BAT that manages both battery banks, i.e. Bat03 and Bat04. Its custom name is Bat03/Bat04.
This is the resulting output:
This is my current configuration in settings.py:
Does anybody have a hint as how to configure dbus-aggregate-batteries based on the specific setup of having multiple battery banks where the individual BMS manage a different number of cells?
Best regards, Peter
Best regards, Peter