Skip to content

Commit

Permalink
Merge pull request #40 from johanschelin/master
Browse files Browse the repository at this point in the history
Change batterycount deviceclass and set notrun to 0
  • Loading branch information
RustyDust authored Sep 30, 2023
2 parents 5153818 + 8ee6df2 commit 274ce8b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions custom_components/sonnenbatterie/mappings.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,8 @@
"modules": {
"sensor": "module_count",
"friendly_name": "Battery module count",
"unit": "",
"class": SensorDeviceClass.BATTERY,
"unit": None,
"class": None,
},
},
"inverter": {
Expand Down
2 changes: 1 addition & 1 deletion custom_components/sonnenbatterie/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def generateDeviceInfo(configentry_id,systemdata):
class SonnenBatterieSensor(CoordinatorEntity,SensorEntity):
def __init__(self,id,deviceinfo,coordinator,name=None):
self._attributes = {}
self._state = "NOTRUN"
self._state = "0"
self._deviceinfo=deviceinfo
self.coordinator=coordinator
self.entity_id = id
Expand Down

0 comments on commit 274ce8b

Please sign in to comment.