Skip to content

Releases: flip-dots/SolixBLE

v3.7.0

13 Apr 11:09

Choose a tag to compare

General changes

This is a small-ish release which adds proper support for the Solarbank 2 and improves the telemetry packet parsing to support parsing telemetry which is split across an arbitrary number of packets thanks to work done under #31 by @jul1an-s.

Added

  • Added MaxLoadSB2 enum for Solarbank2.
  • Added LightMode enum for Solarbank2.
  • Added GridStatus enum for Solarbank2.
  • Added SBUsageMode enum for Solarbank2.
  • Added SBPowerCutoff enum for Solarbank2.
  • Added error_code property for Solarbank2.
  • Added temperature_unit property for Solarbank2.
  • Added output_cutoff_data property for Solarbank2.
  • Added lowpower_input_data property for Solarbank2.
  • Added input_cutoff_data property for Solarbank2.
  • Added max_load property for Solarbank2.
  • Added usage_mode property for Solarbank2.
  • Added home_load_preset property for Solarbank2.
  • Added light_mode property for Solarbank2.
  • Added grid_status property for Solarbank2.
  • Added light_on property for Solarbank2.
  • Added battery_heating property for Solarbank2.

Changed

  • Telemetry data split across an arbitrary number of packets is now supported natively, previously it required device specific implementation for some devices.

v3.6.0

30 Mar 16:50

Choose a tag to compare

General changes

This is a fairly major (but not super massive) release which adds support for the Anker Prime 160w charger and changes a bunch of things behind the scenes, including improving logging, the automatic reconnection logic, and it should make it easier to add support for more Anker Prime devices.

Added

  • Added support for the Anker Prime 160w charger including port and timer control.
  • Added docs page explaining how to patch Anker app to produce detailed logs.

Changed

  • Payload parsing failures now produce detailed logs as to what went wrong as well as being more robust.
  • Renamed ports of Anker Prime 250w charger to match existing naming convention.
  • Tests now execute much faster due to usage of the fast_sleep and fast_timeout fixtures.

v3.5.0

22 Mar 19:15

Choose a tag to compare

General changes

This is a small release which adds more sensors for the C300(X) DC and fixes some broken ones. Big thanks to @terratec for the fixes/upgrades submitted under #8.

Added

  • Added dc_timer_remaining for C300DC.
  • Added dc_timer for C300DC.
  • Added battery_capacity for C300DC.
  • Added software_version for C300DC.
  • Added light for C300DC.
  • Added device_overload for C300DC.
  • Added serial_number for C300DC.
  • Added device_timeout for C300DC.
  • Added temperature_unit for C300DC.
  • Added is_display_on for C300DC.
  • Added light_timeout for C300DC.
  • Added solar_port for C300DC.
  • Added dc_12v_auto_on for C300DC.

Fixed

  • Fixed dc_power_out being incorrectly named dc_power_in for C300DC
  • Fixed charging_status using incorrect enum ChargingStatusC300DC for C300DC
  • Fixed display_mode using incorrect value for C300DC

Removed

  • Removed dc_power_in. Use solar_power_in for C300DC instead.
  • Removed ChargingStatusC300DC. Use ChargingStatus for C300DC instead.
  • Removed is_light_on for C300DC. Use light instead.
  • Removed dc_output_timeout for C300DC.

v3.4.0

12 Mar 10:05
1ce803f

Choose a tag to compare

General changes

This is a small release which just adds support for the C800(X).

Added

  • Added support for the C800(X) including AC/DC/Light/Display control.

v3.3.0

11 Mar 13:07
f14d216

Choose a tag to compare

General changes

This is a fairly huge upgrade that ended up changing way more things than I planned for so it might be a good idea to exercise caution when using it, but it has been tested for the last few days with no major issues. Big picture, the automatic connection retrying has been re-written to be more reliable, connecting and negotiating should now be faster, its now possible to control some aspects of the C300(X) and C1000(X) (i.e AC/DC on/off control), some properties have been renamed and had their types changed, if a property has a bad value it shouldn't prevent others from being readable anymore, more parameters should be available and parsable, logs should be more useful, and there are a load more tests to make sure things work.

Added

  • Added support for reading telemetry data spread across multiple packets.
  • Added support for setting AC/DC output for C300 and C1000.
  • Added support for setting lightbar brightness for C300 and C1000.
  • Added support for turning display on/off for C300 and C1000.
  • Added support for setting display brightness for C300 and C1000.
  • Added support for setting display timeout for C300 and C1000.
  • Added support for requesting status updates from C300 and C1000.
  • Added example script for controlling C300 and C1000.
  • Added note to documentation about strange unconnectable conditions.
  • Added note to documentation about automatic reconnection.
  • Added LightStatus.SOS to LightStatus.
  • Added negotiated property to SolixBLEDevice to determine negotiation status.
  • Added tests for negotiation, decryption, telemetry processing, bad values, and reconnection.

Changed

  • Changed documentation to use more generic device terms instead of power stations.
  • Changed automatic reconnection to attempt to silently reconnect and only run callbacks on failure.
  • Changed automatic reconnection to run callbacks on reconnection only if it failed to silently reconnect.
  • Changed payload parsing to log payload when parsing fails.
  • Changed logging of payloads to print potential types for the parameters of the first telemetry packet.
  • Changed logging of payloads to print potential types for the parameters for unknown packets, not just telemetry.
  • Changed logging of packets to print pattern, command, and payload.
  • Changed negotiations to automatically retry if no response is received in a time limit and just generally be more robust.
  • Use ac_output and PortStatus rather than ac_on and bool.
  • Use solar_port and PortStatus rather than dc_input_on and bool.
  • Use solar_power_in rather than dc_power_in.
  • Use dc_output rather than dc_port
  • Improved parsing of packets to validate header, length, and checksum.
  • Improved parsing of packets to be able to parse most packets, not just telemetry.
  • Disable usage of services cache to hopefully avoid UUID not found errors.

Fixed

  • Fixed issue where properties would not be updated if one of them was invalid or missing.
  • Fixed issue where inputs would show as PortStatus.OUTPUT instead of PortStatus.INPUT

Removed

  • Removed solar_port from C300 and C1000 as existing value changed with AC charging and actual is unknown.
  • Removed ac_on and bool and replaced it with ac_output and PortStatus.
  • Removed dc_input_on and bool and replaced it with solar_port and PortStatus.
  • Removed dc_power_in and replaced it with solar_power_in.
  • Removed dc_port and replaced it with dc_output.
  • Removed supports_telemetry from SolixBLEDevice.

v3.2.0

27 Feb 16:29
829a55e

Choose a tag to compare

General changes

Using data from the anker-solix-api project and work done under #10, #11, #12 I have been able to add support for a whole load of devices, will any of them work? Who knows, but it will be fun finding out.

Added

  • Added C300DC class for monitoring C300 power stations.
  • Added C1000G2 class formonitoring C1000 Gen 2 power stations.
  • Added F2000 class formonitoring F2000 (767 Powerhouse ) power stations.
  • Added F3800 class for monitoring F3800 power stations.
  • Added Solarbank2 class for monitoring Solarbank 2 systems.
  • Added Solarbank3 class for monitoring Solarbank 3 systems.
  • Added PrimeCharger250w class for monitoring the Anker 250w charger.

Changed

  • Added error catching when parsing telemetry messages into little sections of data. This should avoid the entire library not working if a packet gets cut off for some reason.

v3.1.1

27 Feb 11:01
5177f20

Choose a tag to compare

General changes

This restructures the project to spread the code across multiple files. This is needed for future expansion. This also adds some real documentation using readthedocs.io.

v3.1.0

26 Feb 15:31
a157028

Choose a tag to compare

General changes

This update completely re-writes the parsing system to use a new format which will be able to take advantage of the pre-existing database of devices created by the anker-solix-api project to allow me to add support for all of the documented devices.

Other quality of life improvements include adding automated tests for the parsing of C300 and C1000 telemetry, adding a CICD config to run those tests, a more helpful log of state changes in telemetry packets when in debug mode, fixing issues with parsing existing values, and adding some more sensors.

Added

  • Added ChargingStatus enum for the charging status of the device.
  • Added ac_on property for C300 and C1000 to show status of AC output.
  • Added temperature property for C300 and C1000 to show internal temperature.
  • Added charging_status property for C300 and C1000 to show charging status of device.
  • Added serial_number property for C300 and C1000 to show serial number of device.
  • Added software_version property for C300 and C1000 to show software version of device.
  • Added battery_health property for C1000 to show health of internal battery.
  • Added software_version_expansion property for C1000 to show software version of an expansion battery.
  • Added software_version_controller property for C1000 to show software version of the controller.
  • Added temperature_expansion property for C1000 to show temperature of expansion battery.
  • Added battery_percentage_expansion property for C1000 to show battery percentage of expansion battery.
  • Added battery_health_expansion property for C1000 to show battery health of expansion battery.
  • Added num_expansion property for C1000 to show number of expansion batteries.

Changed

  • Changed reporting of status updates in debug log to show different representations (e.g str, hex, int, uint, etc).

Fixed

  • Fixed incorrect value for hours_remaining property for C300 and C1000 when time > 25.5h.
  • Fixed incorrect value for days_remaining property for C300 and C1000 when time > 25.5h.
  • Fixed incorrect value for time_remaining property for C300 and C1000 when time > 25.5h.
  • Fixed incorrect value for timestamp_remaining property for C300 and C1000 when time > 25.5h.

v3.0.0

22 Feb 21:19

Choose a tag to compare

The latest firmware on Anker power stations forces the use of a custom encryption protocol which prevented this library from working, this update fixes that by implementing their rather bizzare protocol. Supported power stations running the latest firmware will now work again. Some other changes include improvements to logging, better retry logic, and a new method to get the serial number of the C300 (I plan on addding it for the C1000 later when I add some other sensors).

v2.1.1

14 Dec 17:34

Choose a tag to compare

Fix issue in disconnect function (I forgot to put an await).