Skip to content

Commit

Permalink
Fix get_total_energy_production_t_kwh
Browse files Browse the repository at this point in the history
  • Loading branch information
augustynski-lukasz authored Jun 20, 2024
1 parent a798cc8 commit b3262b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion driver_amiplus.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ struct Amiplus: Driver
esphome::optional<double> ret_val{};
uint32_t usage = 0;
size_t i = 11;
uint64_t total_register = tarrif < 4 ? 0x8E00833C | ((tarrif*16) << 24) : 0x8E8010833C;
uint64_t total_register = tarrif < 4 ? 0x8E00833C | ((tarrif*16) << 16) : 0x8E8010833C;
while (i < telegram.size()) {
uint64_t c = tarrif < 4 ?
(((uint32_t)telegram[i+0] << 24) | ((uint32_t)telegram[i+1] << 16 ) | ((uint32_t)telegram[i+2] << 8) | ((uint32_t)telegram[i+3]) )
Expand Down

0 comments on commit b3262b7

Please sign in to comment.