|
28 | 28 |
|
29 | 29 | _MeterDataMethods: dict[ComponentMetricId, Callable[[MeterData], float]] = { |
30 | 30 | ComponentMetricId.ACTIVE_POWER: lambda msg: msg.active_power, |
| 31 | + ComponentMetricId.ACTIVE_POWER_PHASE_1: lambda msg: msg.active_power_per_phase[0], |
| 32 | + ComponentMetricId.ACTIVE_POWER_PHASE_2: lambda msg: msg.active_power_per_phase[1], |
| 33 | + ComponentMetricId.ACTIVE_POWER_PHASE_3: lambda msg: msg.active_power_per_phase[2], |
31 | 34 | ComponentMetricId.CURRENT_PHASE_1: lambda msg: msg.current_per_phase[0], |
32 | 35 | ComponentMetricId.CURRENT_PHASE_2: lambda msg: msg.current_per_phase[1], |
33 | 36 | ComponentMetricId.CURRENT_PHASE_3: lambda msg: msg.current_per_phase[2], |
|
59 | 62 |
|
60 | 63 | _InverterDataMethods: dict[ComponentMetricId, Callable[[InverterData], float]] = { |
61 | 64 | ComponentMetricId.ACTIVE_POWER: lambda msg: msg.active_power, |
| 65 | + ComponentMetricId.ACTIVE_POWER_PHASE_1: lambda msg: msg.active_power_per_phase[0], |
| 66 | + ComponentMetricId.ACTIVE_POWER_PHASE_2: lambda msg: msg.active_power_per_phase[1], |
| 67 | + ComponentMetricId.ACTIVE_POWER_PHASE_3: lambda msg: msg.active_power_per_phase[2], |
62 | 68 | ComponentMetricId.ACTIVE_POWER_INCLUSION_LOWER_BOUND: lambda msg: ( |
63 | 69 | msg.active_power_inclusion_lower_bound |
64 | 70 | ), |
|
82 | 88 |
|
83 | 89 | _EVChargerDataMethods: dict[ComponentMetricId, Callable[[EVChargerData], float]] = { |
84 | 90 | ComponentMetricId.ACTIVE_POWER: lambda msg: msg.active_power, |
| 91 | + ComponentMetricId.ACTIVE_POWER_PHASE_1: lambda msg: msg.active_power_per_phase[0], |
| 92 | + ComponentMetricId.ACTIVE_POWER_PHASE_2: lambda msg: msg.active_power_per_phase[1], |
| 93 | + ComponentMetricId.ACTIVE_POWER_PHASE_3: lambda msg: msg.active_power_per_phase[2], |
85 | 94 | ComponentMetricId.CURRENT_PHASE_1: lambda msg: msg.current_per_phase[0], |
86 | 95 | ComponentMetricId.CURRENT_PHASE_2: lambda msg: msg.current_per_phase[1], |
87 | 96 | ComponentMetricId.CURRENT_PHASE_3: lambda msg: msg.current_per_phase[2], |
|
0 commit comments