ConfigurationΒΆ

balanz has a high number of configuration options. They are contained within a standard .INI file which should hopefully be self-explanatory.

balanz.ini with default values and explanations is included below for completeness:

[logging]
model = INFO
ocpp = WARNING
balanz = INFO
cp_v16 = INFO
websockets.client = INFO
websockets.server = INFO
api = INFO
user = INFO
AUDIT = INFO

[capacity]
log_capacity = 100000
audit_capacity = 10000

[host]
; Host to listen on (default: 0.0.0.0)
addr = 0.0.0.0
; Port to listen on (default: 9999)
port = 9999
; watchdog stale time for charger (and server if LC/proxy) connections in seconds.
watchdog_stale = 500
; watchdog run / check interval in seconds
watchdog_interval = 100
; ping timeout in seconds
ping_timeout = 60
; Require HTTP Basic Auth login. Will be checked against sha'ed value on charger object
; If no such value present, it will be generated and send to charger by configuring
; the 'AuthenticationKey' field.
http_auth = True
; Delay after CP connect before setting new AuthorizationKey (seconds)
; Note, that this will cause certain CP's (e.g ABB) to restart after setting.
http_auth_delay = 45
; Hack for testing by allowing authentication information to come via protocol.
http_auth_via_protocol = True
; Certificate along with any chain required to ensure it. To be used with TLS websockets. 
; If provided end point will be wss://<addr>:<port>/<charge-point-id>
; If not provided TLS will be disabled, so ws://<addr>:<port>/<charge-point-id>
; cert_chain = cert/cert-chain.pem
; Certifiate private for certificate
; cert_key = cert/cert.key

[api]
; user file to use for authentication with format "user_id","user_type","auth_sha"
users_csv = model/users.csv

[ext-server]
; CSMS external server (for LC/proxy mode). If not set, then running as full CSMS server
;server = wss://abb.cdlink.chargedot.com:9043/
; How to handle any charging related messages (SetChargingProfile/ClearChargingProfile)
; coming from the server. 3 options, 'Accepted', 'Rejected', 'Forward'
server_charging_call = Accepted

[csms]
; Allow concurrent use of Tag (in multiple sessions across chargers)
allow_concurrent_tag = False
; Heartbeat interval in sec (to be set as a result of receiving boot_notification)
heartbeat_interval = 120
; Charger transaction stale timeout. Timeout in seconds of CP inactivity after which any transaction
; (and therefore allocation, tag usage, etc.) will be considered no longer valid. 
; NOTE: This CAN be dangerous. Default 1 hour
transaction_timeout = 3600
; Watchdog interval in seconds to check transaction timeout
transaction_interval = 60

[balanz]
; balanz loop intervals in seconds. IF set to 0, balanz functionality (i.e. SmartCharging) will
; be inactive. It will simply not run, neither to set default profile, or update them.
run_interval = 5
; balanz loop will check for urgent tasks (charger to be initialized, EV connected) every run_interval
; seconds. A full review including rebalancing will happen every intervals_full times. 
intervals_full = 12
; balanz loop wait before first run in seconds
first_wait = 300
; Minimum allocation per connector in A
min_allocation = 6
; Default maximum allocation per connector in A. May be set per charger
default_max_allocation = 32
; Margin (in A) that usage must be lower than offered before lowering
margin_lower = 0.8
; If usage is within this margin (in A) of what is offered, more can be offered
margin_increase = 0.6
; usage_threshold in A. If usage is below this when offered the minimum (6A default), then take remove allocation
usage_threshold = 2
; Minimum offer increase interval. Can only increase offer every this many seconds.
min_offer_increase_interval = 115
; Maximum offer increase in A.
max_offer_increase = 3
; Default charger piority
default_priority = 1
; Waiting time in sec after balanz reductions before implementing any increases
wait_after_reduce = 5
; Usage monitoring interval in seconds (rolling). This is used for usage monitoring and charging priority calculation.
usage_monitoring_interval = 300
; Minimum time since last allocation for when to consider removing allocation from SuspendedEV status. Seconds
suspended_allocation_timeout = 300
; energy threshold after which any delayed charging scenario is assumed to be over (Wh). Default 1000 (so 1kWh)
energy_threshold = 1000
; Interval to try initiating charging again because of delayed or suspended charging in seconds
suspended_delayed_time = 3600
; Interval to try initiating charging again because of delayed or suspended charging in seconds when energy
; threshold has been crossed (so NOT the initial delayed charging). Default 21600 (so 6 hours)
suspended_delayed_time_not_first = 21600
; Suspend until top of hour. Flag to indicate that next offer should be made around the next top of the hour
; Only valid for first wait, i.e. until energy_threshold has been reached.
suspend_top_of_hour = True

[model]
; Allow chargers to auto-register. Will be added to chargers CSV file. 
; If false, will reject any request from unknown chargers.
charger_autoregister = True
; Autoregister to which group. 
charger_autoregister_group = Default
; CSV file with groups. Default model/groups.csv'
groups_csv = model/groups.csv
; CSV file with chargers. Default model/chargers.csv
chargers_csv = model/chargers.csv
; CSV file with tags. Default model/tags.csv
tags_csv = model/tags.csv
; CSV file with firmware definitions. Default model/firmware.csv
firmware_csv = model/firmware.csv

[history]
; CSV file for storing completed sessions. Default history/sessions.csv. Comment to omit saving sessions.
session_csv = history/sessions.csv
; Minimum usage change (in A) before to make a history entry
minimum_usage_change = 0.5
; audit log files
audit_file = history/audit_log.txt