|
27 | 27 | api_key="eBatChargeToday", |
28 | 28 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
29 | 29 | device_class=SensorDeviceClass.ENERGY, |
| 30 | + state_class=SensorStateClass.TOTAL_INCREASING, |
30 | 31 | ), |
31 | 32 | GrowattSensorEntityDescription( |
32 | 33 | key="mix_battery_charge_lifetime", |
|
42 | 43 | api_key="eBatDisChargeToday", |
43 | 44 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
44 | 45 | device_class=SensorDeviceClass.ENERGY, |
| 46 | + state_class=SensorStateClass.TOTAL_INCREASING, |
45 | 47 | ), |
46 | 48 | GrowattSensorEntityDescription( |
47 | 49 | key="mix_battery_discharge_lifetime", |
|
57 | 59 | api_key="epvToday", |
58 | 60 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
59 | 61 | device_class=SensorDeviceClass.ENERGY, |
| 62 | + state_class=SensorStateClass.TOTAL_INCREASING, |
60 | 63 | ), |
61 | 64 | GrowattSensorEntityDescription( |
62 | 65 | key="mix_solar_generation_lifetime", |
|
72 | 75 | api_key="pDischarge1", |
73 | 76 | native_unit_of_measurement=UnitOfPower.WATT, |
74 | 77 | device_class=SensorDeviceClass.POWER, |
| 78 | + state_class=SensorStateClass.MEASUREMENT, |
75 | 79 | ), |
76 | 80 | GrowattSensorEntityDescription( |
77 | 81 | key="mix_battery_voltage", |
|
101 | 105 | api_key="elocalLoadToday", |
102 | 106 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
103 | 107 | device_class=SensorDeviceClass.ENERGY, |
| 108 | + state_class=SensorStateClass.TOTAL_INCREASING, |
104 | 109 | ), |
105 | 110 | GrowattSensorEntityDescription( |
106 | 111 | key="mix_load_consumption_lifetime", |
|
116 | 121 | api_key="etoGridToday", |
117 | 122 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
118 | 123 | device_class=SensorDeviceClass.ENERGY, |
| 124 | + state_class=SensorStateClass.TOTAL_INCREASING, |
119 | 125 | ), |
120 | 126 | GrowattSensorEntityDescription( |
121 | 127 | key="mix_export_to_grid_lifetime", |
|
132 | 138 | api_key="chargePower", |
133 | 139 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
134 | 140 | device_class=SensorDeviceClass.POWER, |
| 141 | + state_class=SensorStateClass.MEASUREMENT, |
135 | 142 | ), |
136 | 143 | GrowattSensorEntityDescription( |
137 | 144 | key="mix_load_consumption", |
138 | 145 | translation_key="mix_load_consumption", |
139 | 146 | api_key="pLocalLoad", |
140 | 147 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
141 | 148 | device_class=SensorDeviceClass.POWER, |
| 149 | + state_class=SensorStateClass.MEASUREMENT, |
142 | 150 | ), |
143 | 151 | GrowattSensorEntityDescription( |
144 | 152 | key="mix_wattage_pv_1", |
145 | 153 | translation_key="mix_wattage_pv_1", |
146 | 154 | api_key="pPv1", |
147 | 155 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
148 | 156 | device_class=SensorDeviceClass.POWER, |
| 157 | + state_class=SensorStateClass.MEASUREMENT, |
149 | 158 | ), |
150 | 159 | GrowattSensorEntityDescription( |
151 | 160 | key="mix_wattage_pv_2", |
152 | 161 | translation_key="mix_wattage_pv_2", |
153 | 162 | api_key="pPv2", |
154 | 163 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
155 | 164 | device_class=SensorDeviceClass.POWER, |
| 165 | + state_class=SensorStateClass.MEASUREMENT, |
156 | 166 | ), |
157 | 167 | GrowattSensorEntityDescription( |
158 | 168 | key="mix_wattage_pv_all", |
159 | 169 | translation_key="mix_wattage_pv_all", |
160 | 170 | api_key="ppv", |
161 | 171 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
162 | 172 | device_class=SensorDeviceClass.POWER, |
| 173 | + state_class=SensorStateClass.MEASUREMENT, |
163 | 174 | ), |
164 | 175 | GrowattSensorEntityDescription( |
165 | 176 | key="mix_export_to_grid", |
166 | 177 | translation_key="mix_export_to_grid", |
167 | 178 | api_key="pactogrid", |
168 | 179 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
169 | 180 | device_class=SensorDeviceClass.POWER, |
| 181 | + state_class=SensorStateClass.MEASUREMENT, |
170 | 182 | ), |
171 | 183 | GrowattSensorEntityDescription( |
172 | 184 | key="mix_import_from_grid", |
173 | 185 | translation_key="mix_import_from_grid", |
174 | 186 | api_key="pactouser", |
175 | 187 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
176 | 188 | device_class=SensorDeviceClass.POWER, |
| 189 | + state_class=SensorStateClass.MEASUREMENT, |
177 | 190 | ), |
178 | 191 | GrowattSensorEntityDescription( |
179 | 192 | key="mix_battery_discharge_kw", |
180 | 193 | translation_key="mix_battery_discharge_kw", |
181 | 194 | api_key="pdisCharge1", |
182 | 195 | native_unit_of_measurement=UnitOfPower.KILO_WATT, |
183 | 196 | device_class=SensorDeviceClass.POWER, |
| 197 | + state_class=SensorStateClass.MEASUREMENT, |
184 | 198 | ), |
185 | 199 | GrowattSensorEntityDescription( |
186 | 200 | key="mix_grid_voltage", |
|
196 | 210 | api_key="eCharge", |
197 | 211 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
198 | 212 | device_class=SensorDeviceClass.ENERGY, |
| 213 | + state_class=SensorStateClass.TOTAL_INCREASING, |
199 | 214 | ), |
200 | 215 | GrowattSensorEntityDescription( |
201 | 216 | key="mix_load_consumption_solar_today", |
202 | 217 | translation_key="mix_load_consumption_solar_today", |
203 | 218 | api_key="eChargeToday", |
204 | 219 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
205 | 220 | device_class=SensorDeviceClass.ENERGY, |
| 221 | + state_class=SensorStateClass.TOTAL_INCREASING, |
206 | 222 | ), |
207 | 223 | GrowattSensorEntityDescription( |
208 | 224 | key="mix_self_consumption_today", |
209 | 225 | translation_key="mix_self_consumption_today", |
210 | 226 | api_key="eChargeToday1", |
211 | 227 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
212 | 228 | device_class=SensorDeviceClass.ENERGY, |
| 229 | + state_class=SensorStateClass.TOTAL_INCREASING, |
213 | 230 | ), |
214 | 231 | GrowattSensorEntityDescription( |
215 | 232 | key="mix_load_consumption_battery_today", |
216 | 233 | translation_key="mix_load_consumption_battery_today", |
217 | 234 | api_key="echarge1", |
218 | 235 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
219 | 236 | device_class=SensorDeviceClass.ENERGY, |
| 237 | + state_class=SensorStateClass.TOTAL_INCREASING, |
220 | 238 | ), |
221 | 239 | GrowattSensorEntityDescription( |
222 | 240 | key="mix_import_from_grid_today", |
223 | 241 | translation_key="mix_import_from_grid_today", |
224 | 242 | api_key="etouser", |
225 | 243 | native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR, |
226 | 244 | device_class=SensorDeviceClass.ENERGY, |
| 245 | + state_class=SensorStateClass.TOTAL_INCREASING, |
227 | 246 | ), |
228 | 247 | # This sensor is manually created using the most recent X-Axis value from the chartData |
229 | 248 | GrowattSensorEntityDescription( |
|
0 commit comments