const PA12 = flux.getNodeById("c6c8a3a4-9a2a-4443-86c2-5f1d8a721aa8");
const PA13 = flux.getNodeById("7968045d-8e7e-4909-8451-26abb351351d");
const PA14 = flux.getNodeById("c63c8bc7-b216-4f70-a6a7-3eb3f9cda466");
const PB0 = flux.getNodeById("443cda4d-70d3-4182-a362-fbb69ad2678e");
const PB7 = flux.getNodeById("a49a1017-1acb-41a8-8872-b8e5f304cea8");
const STM_RST = flux.getNodeById("a7454e58-124e-4406-990e-c9f9836f9966");
const STM_GND = flux.getNodeById("4c0da192-9146-45fe-b14e-25c98b5e6859"); // Common
const STM_VDD = flux.getNodeById("bed4e081-980f-4bd7-8dc4-60998085030a"); // Vin
const voltageReading = flux.createOutputNode("STM voltage");
const voltageRST = flux.createOutputNode("RESET voltage");
const voltagePB7 = flux.createOutputNode("PB7 voltage");
const mySwitch = flux.controls.find(control => control.name === "PB7");
flux.on("setup", (event) => {