Skip to content

Store remote and shared voltage control - #192

Draft
m-bossart wants to merge 5 commits into
mainfrom
mb/remote-control
Draft

m-bossart wants to merge 5 commits into
mainfrom
mb/remote-control

Conversation

@m-bossart

@m-bossart m-bossart commented Sep 28, 2026 •

Copy link
Copy Markdown

Remote and shared voltage control

Stores the remote and shared voltage control data.

What changes

  • The plain-integer regulated_bus_number, remote_bus_control and rmpct columns become nullable foreign keys to bus: remote_regulated_bus_id on every regulating device, the VSC and LCC references on two_terminal_hvdc_lines, and regulated_bus_id/regulated_bus_side on transformer_circuits.
  • Generators get voltage_setpoint with its unit basis.
  • Transformer circuits get load_drop_compensation_r and _x as REAL columns.
  • New tables: voltage_control_groups (droop characteristic as typed columns, modeled on plants) and voltage_control_associations (positive weights, one group per member or converter terminal).
  • CHECKs reject a device naming its own bus. Triggers enforce the rules that need the arc and the member type.
  • Remote references are non-owning (ON DELETE SET NULL). A droop controller's own regulated bus cascades.
  • The side and terminal enums store UNDEFINED, not NULL.
  • The unit registry gains the Impedance per-unit rule and the Admittance kind. The registry and reference DDL are regenerated, and user_version is 2.

Before merge

CI checks out SiennaSchemas v0.1.0, so the registry staleness and DDL drift gates will fail until the pin moves to the release that includes Sienna-Platform/SiennaSchemas#67.

Verification

338 tests pass, units sync reports 0 FAIL, and the registry seal is verified (2026-09-24).

Stack

Merge in this order.
The Julia branches pin each other's mb/remote-control branches in [sources], and each pin moves back to main or psy6 as its dependency merges.

Depends on: Sienna-Platform/SiennaSchemas#67.

🤖 Generated with Claude Code

Replace the plain-integer regulated_bus_number, remote_bus_control and rmpct
columns with nullable foreign keys to the bus table: remote_regulated_bus_id
on generators, storage, synchronous condensers, sources, switched shunts,
FACTS devices and converters, the VSC and LCC references on
two_terminal_hvdc_lines, and regulated_bus_id with regulated_bus_side and
load_drop_compensation on transformer_circuits. Generators also get
voltage_setpoint with its unit basis. Same-row CHECKs reject a device naming
its own bus and a transformer naming a bus without regulating voltage;
triggers enforce the rules that need the arc.

Add voltage_control_groups (VoltageDroopControl and ReactivePowerSharing,
modeled on plants with the droop characteristic as typed columns) and
voltage_control_associations with positive weights, one group per member or
converter terminal, and a member-type trigger. Register the new columns,
add the Impedance per-unit basis rule, regenerate the sealed registry and
the reference DDL, and bump user_version to 2.
The whole-complex Y_increase column is registered as Admittance; the per-part
admittance columns keep their scalar kinds.
load_drop_compensation_r and load_drop_compensation_x replace the JSON blob,
registered like the circuit's r and x; registry and reference DDL regenerated.
The regulated-bus and tap-transformer references are non-owning, so they follow
settlement_point_id with ON DELETE SET NULL; null already means the device
regulates its own bus or has no tap transformer. A droop controller's own
regulated bus cascades, since the controller exists for that bus.
…t NULL

Both enums gain an UNDEFINED member, following TransformerControlObjective and
the other sentinel enums, so the columns are NOT NULL with that default and the
membership index needs no COALESCE.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant