Releases: macxq/foxess-ha
Removes random_user_agent dependency
This change removes the random_user_agent dependency from the code and requirement in manifest as the UserAgent is now hard coded to match the dev specs for the OpenApi
Update to default to v1 endpoints, and 2 additional BMS max battery current sensors
Updated to use Fox OpenApi v1 api call endpoints.
The OpenApi has deprecated some of the original v0 endpoint calls, {Inverter Device_Detail, Device_real-time data} - it is expected these will eventually be withdrawn in the future and this update changes the default behaviour to use the v1 api instead.
Note: I have been testing the v1 interface for several months with no problems; whilst there should be no reason for users to continue to use the v0 api endpoint, for legacy the addition of the flag Use_V1_Api: false in your platform config will force the integration to continue using v0 api calls (but they may eventually stop working in the future).
Added 2 variables for hybrid battery systems:
- Max Bat Charge Current (A)
- Max Bat Discharge Current (A)
These 2 sensors are provided by the battery management system (BMS) and show what the max battery charge or discharge current that is currently allowed by the BMS.
As battery SoC and lowest cell temperature changes these sensors will show how the BMS is adapting the charge and discharge power to cope with state of charge and temperature affects (specifically low temperature).
Whilst the OpenApi does not provide us with the lowest cell temperature, these sensors are the end result, i.e. what the maximum battery charge and discharge power that can be safely maintained. Your max battery charge / discharge power can be found by multiplying this max battery current by battery volts.
Update readme to add max bat charge/discharge current sensors
Some refactoring
Beta test release for Fox EVO system support
The Fox EVO system does not support the device detail (unlike every other Fox inverter - possibly an error?) and the api call fails see #325 .
The device list is correct and returns much of the information provided by the device detail api call, this modification adds a new config switch Evo: true and instead of making the device detail call, it will lookup the information in the device list and use that to fill the missing information.
Not all of the device detail information is provided by the list details call, however all the essential items are provided to allow the integration to run correctly (until Fox correct the OpenApi for Evo systems).
On EVO systems add the following switch Evo: true to the platform statement in configuration.yaml
sensor:
- platform: foxess
deviceID: [your deviceid]
deviceSN: [yourdevicesn]
Evo: true
This update also has an improved DNS and cloud failure retry mechanism and adds future support to use the Fox OpenAPI V1 interface as the V0 is showing as deprecated and will be withdrawn at some point in the future.
Hot Fixes for API error
Hot Fix for API error and other small fixes
See #306
Also corrects battery scaling fault in the OpenAPI on some later model batteries
Solar only inverter improved standby operation and additional Hybrid sensors PVEnergyTotal, SoH
Handles solar only inverter datalogger staying on-line and sending erroneous data (only accepts samples less than 6 minutes old)
Hybrid inverters now support these sensors
- PVEnergyTotal - The total PV production today in kWh
- SoH - Battery state of health will be populated if BMS supports it
All inverters
- The sensor.foxess_inverter gets these additional attributes Master, Manager, Slave firmware versions and for battery systems a list of all batteries fitted with there firmware versions
Tests Solar only inverter data sample age for improved off-grid detection
PLEASE DO NOT INSTALL THIS RELEASE IF YOU ARE NOT INVOLVED IN THE TESTING
This release is a test for solar only (T series) inverters where the datalogger does not sometimes switch to off-line when the inverter goes into standby - it now tests data sample age when an inverter is between on / off grid states and will allow data samples that are valid (i.e. less than 5 minutes in age).
Sets runningState to ‘164 - off-grid’ should datalogger go off-line
Sets runningState to ‘164 - off-grid’ should datalogger go off-line when reported by Device Detail.
Improved off-grid handling for solar only inverters
This changes the handling of solar inverters as some data loggers (T series) do not reliably go off-line when the inverter shuts down at sunset which can cause erroneous data in the sensors.
This corrects the behaviour by using the runningState flag which goes from 163 (on-grid) to 161 (waiting) when this happens and it will switch the internal state to off-line whilst the inverter is waiting for the next sun rise.
EDIT: minor change to switch only on state 161 (ignores 162 checking)
Improved off-grid handling for solar only inverters
This changes the handling of solar inverters as some data loggers (T series) do not reliably go off-line when the inverter shuts down at sunset which can cause erroneous data in the sensors.
This corrects the behaviour by using the runningState flag which goes from 163 (on-grid) to 161 (waiting) when this happens and it will switch the internal state to off-line whilst the inverter is waiting for the next sun rise.
Adds PV strings 7 through 18 for Fox R series inverters
Foss ESS R Series Inverters - 18 PV strings
As the R series inverters support up to 18 PV strings, this release extends the PV string entities from 6 and adds PV7-18 (each PV string has volt, power and current entities)
As most people do not have more than 6 PV strings, to minimise 'unknown' sensors this option has to be enabled in the config. This is done by adding the extra switch to the Platform statement in configuration.yaml with extendPV: true as follows -
- platform: foxess
deviceID: enter_your_inverter_id
deviceSN: enter_your_inverter_serial_number
apiKey: enter_your_personal_api_key
extendPV: true
Speeded up API performance
Now the OpenAPI is performing well, the enforced 5 second delay between API calls has been reduced to 2 seconds making startup much faster.
Fixed a bug with Error 41200 burning through personal API calls
In some rare cases users have reported that the device variables call fails with a Fox api error 41200 - this appears to be an internal error generated by the API where some of the returned data is invalid (most often the 'currentFault' variable). See #268