From a84a67e279a64b1188f17c0aa54c2442f5a99b56 Mon Sep 17 00:00:00 2001 From: Terry Fu Date: Thu, 23 May 2024 15:09:08 -0400 Subject: [PATCH] Error Voltage Readings (#184) * Fixed voltage algorithm. (#182) * Merged submodules. * Version `1.0.12`. * Bug fixed: integer offside. (#185) * Merged submodules. --- arduino/leads_vec_power/leads_vec_power.ino | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arduino/leads_vec_power/leads_vec_power.ino b/arduino/leads_vec_power/leads_vec_power.ino index c9d899ed..76e2e60f 100644 --- a/arduino/leads_vec_power/leads_vec_power.ino +++ b/arduino/leads_vec_power/leads_vec_power.ino @@ -2,7 +2,7 @@ const int PIN_VOT[] = {A0}; -VoltageSensor VOT(PIN_VOT); +VoltageSensor VOT(30000.0, 7500.0, PIN_VOT); void setup() { Serial.begin(9600); @@ -10,6 +10,6 @@ void setup() { } void loop() { - returnFloat(VOLTAGE_SENSOR, VOT.read() * 5.08594953775); + returnFloat(VOLTAGE_SENSOR, VOT.read()); delay(100); }