const aTerminalId = "f1c64112-96ca-9adf-9ea5-70bc6f06d5ae";
const bTerminalId = "afbc4e75-e2be-000a-58e9-2925c8d3b846";
const yTerminalId = "b1d2cd10-1507-5a54-e5d8-dd5729c46b58";
const aTerminal = flux.getNodeById(aTerminalId, "elementTerminal");
const bTerminal = flux.getNodeById(bTerminalId, "elementTerminal");
const yTerminal = flux.getNodeById(yTerminalId, "elementTerminal");
if (!aTerminal || !bTerminal || !yTerminal) {
throw new Error("Oops! Couldn't find terminals");
}
const aVoltage = flux.createOutputNode("a-voltage");
aVoltage.name = "A";
aVoltage.unit = "V";
const bVoltage = flux.createOutputNode("b-voltage");
bVoltage.name = "B";
bVoltage.unit = "V";
const yVoltage = flux.createOutputNode("y-voltage");
yVoltage.name = "Y";
yVoltage.unit = "V";
flux.on("setup", () => {
const highVoltageProp = flux.properties.find((prop) => prop.name === "High Voltage");