-
Notifications
You must be signed in to change notification settings - Fork 15
Add Meter electrical component with transformer ratios support #440
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: v0.x.x
Are you sure you want to change the base?
Add Meter electrical component with transformer ratios support #440
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds support for electrical meters with transformer ratios to track current and voltage transformer configurations over time. The implementation introduces new protobuf messages for representing instrument transformers (CTs and VTs) used in metering applications.
Changes:
- Added
TransformerRatio,TransformerRatioThreePhase,MeterTransformerRatio, andMetermessages to support metering with instrument transformers - Updated
ElectricalComponentCategorySpecificInfoto include the newMetercomponent category - Updated release notes to document the new messages
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| proto/frequenz/api/common/v1alpha8/microgrid/electrical_components/electrical_components.proto | Adds four new messages for meter transformer ratios and updates ElectricalComponentCategorySpecificInfo oneof to include Meter |
| RELEASE_NOTES.md | Documents the new messages and updates to ElectricalComponentCategorySpecificInfo |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
proto/frequenz/api/common/v1alpha8/microgrid/electrical_components/electrical_components.proto
Outdated
Show resolved
Hide resolved
proto/frequenz/api/common/v1alpha8/microgrid/electrical_components/electrical_components.proto
Show resolved
Hide resolved
proto/frequenz/api/common/v1alpha8/microgrid/electrical_components/electrical_components.proto
Outdated
Show resolved
Hide resolved
a815d54 to
b3bfab0
Compare
The following new messages have been added: - `TransformerRatio`: Represents a single transformer ratio with primary and secondary values. - `TransformerRatioThreePhase`: Represents a three-phase transformer ratio, containing individual `TransformerRatio` messages for each phase. - `MeterTransformerRatio`: Represents a meter's transformer ratio (either CT or VT) along with its operational lifetime. - `Meter`: Represents a meter with lists of current and voltage transformer ratios. Each list contains `MeterTransformerRatio` entries to allow tracking historical configurations. Additionally, the `ElectricalComponentCategorySpecificInfo` message has been updated to include the new `Meter` component category. Signed-off-by: Tiyash Basu <tiyash.basu@frequenz.com>
b3bfab0 to
2f9140b
Compare
| message TransformerRatioThreePhase { | ||
| // The transformer ratio for phase 1 (L1/A/R). | ||
| TransformerRatio phase_1 = 1; | ||
|
|
||
| // The transformer ratio for phase 2 (L2/B/Y). | ||
| TransformerRatio phase_2 = 2; | ||
|
|
||
| // The transformer ratio for phase 3 (L3/C/B). | ||
| TransformerRatio phase_3 = 3; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure about this struct, so some input would be nice.
The reason I am not sure about this is that I do not know of a practical scenario in which the transformer ratios will be different for each phase. In theory, this could happen if someone decides to measure just different single-phase lines using the same meter (say to save costs) or electricians had to use a different transformer due to them running out of the standard kind. But how likely is this to happen, and if we need to support these edge cases?
My gut says we need to support these edge cases, but I could be over-engineering here.
|
I am marking it blocked and draft to prevent accidental merges, since we realized we need t align on the requirements here. |
The following new messages have been added:
TransformerRatio: Represents a single transformer ratio with primary and secondary values.TransformerRatioThreePhase: Represents a three-phase transformer ratio, containing individualTransformerRatiomessages for each phase.MeterTransformerRatio: Represents a meter's transformer ratio (either CT or VT) along with its operational lifetime.Meter: Represents a meter with lists of current and voltage transformer ratios. Each list containsMeterTransformerRatioentries to allow tracking historical configurations.Additionally, the
ElectricalComponentCategorySpecificInfomessage has been updated to include the newMetercomponent category.