Skip to content

Commit a7090a5

Browse files
Add RPC to set reactive power (#60)
A new RPC, named `SetPowerReactive` has been added to set reactive power for inverters, and other components that support it. Also, the parameters to the RPC can be sent using the message `SetPowerReactiveParam`.
2 parents 7ad160d + fce1c73 commit a7090a5

File tree

2 files changed

+32
-1
lines changed

2 files changed

+32
-1
lines changed

RELEASE_NOTES.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,12 @@
5050

5151
A new inverter component states have been added: `Unknown`
5252

53+
* [Added RPC to set reactive power](https://github.com/frequenz-floss/frequenz-api-microgrid/pull/60)
54+
55+
A new RPC, named `SetPowerReactive` has been added to set reactive power for
56+
inverters, and other components that support it. Also, the parameters to the
57+
RPC can be sent using the message `SetPowerReactiveParam`.
58+
5359
## Bug Fixes
5460

5561
<!-- Here goes notable bug fixes that are worth a special mention or explanation -->

proto/frequenz/api/microgrid/microgrid.proto

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ service Microgrid {
179179
// ==== vales here are allowed and will be accepted
180180
rpc AddInclusionBounds(SetBoundsParam) returns (google.protobuf.Timestamp);
181181

182-
// Sets the power output of a component with a given ID, provided the
182+
// Sets the active power output of a component with a given ID, provided the
183183
// component supports it.
184184
//
185185
// Note that the target component may have a resolution of more than 1 W.
@@ -198,6 +198,19 @@ service Microgrid {
198198
};
199199
}
200200

201+
// Sets the reactive power output of a component with a given ID, provided the
202+
// component supports it.
203+
//
204+
// Note that the target component may have a resolution of more than 1 VAr.
205+
// E.g., an inverter may have a resolution of 88 VAr.
206+
// In such cases, the magnitude of power will be floored to the nearest
207+
// multiple of the resolution.
208+
rpc SetPowerReactive(SetPowerReactiveParam) returns (google.protobuf.Empty) {
209+
option (google.api.http) = {
210+
get : "/v1/components/{component_id}/setPowerReactive/{power}"
211+
};
212+
}
213+
201214
// Starts the component, and brings it into a state where it is immediately
202215
// operational.
203216
//
@@ -368,6 +381,18 @@ message SetPowerActiveParam {
368381
float power = 2;
369382
}
370383

384+
// Parameters for setting the reactive power of an appropriate component using
385+
// the `SetPowerReactive` RPC.
386+
message SetPowerReactiveParam {
387+
// The ID of the component to set the output reactive power of.
388+
uint64 component_id = 1;
389+
390+
// The output reactive power level, in VAr.
391+
// -ve values are for inductive (lagging) power , and +ve values are for
392+
// capacitive (leading) power.
393+
float power = 2;
394+
}
395+
371396
// Parameters for setting bounds of a given metric of a given component.
372397
message SetBoundsParam {
373398
// An enumerated list of metrics whose bounds can be set.

0 commit comments

Comments
 (0)