Board for precision measurement of current and voltage, with UART output in floating point and CRC. ADC gain is set to 0.5x to have full range capabilities.
| Measurement | Range |
|---|---|
| Current | 0-55A |
| Voltage | 9-34V |
By default current readings are sent in floating point format with CRC attached, if string output is needed change the OUTPUT_MODE flag to STRING.
Instead if floating point output is needed (required by Air_Telemetry and E_Motor_TestBench) set the OUTPUT_MODE flag to BYTES.
Can be enabled changing the OP_MODE flag to CURRENT_CONTROL.
PA15 -> Throttle input signal (from receiver)
PB3 -> Switch input signal (from receiver)
PB5 -> ESC control signal (to ESC input)
A PID control loop is executed at 50Hz frequency to generate PWM output signal applied to the ESC.
There are 2 operating modes switched by PB3 signal: passthrough and active control.
During startup the board will wait (showing 0.00A and 0.00V as telemetry output) for the following command sequence:
throttle down -> throttle up -> throttle down
Once telemetry output starts it means calibration is completed and the system is ready to be operated.
Passthrough is executed when PB3 hightime is lower than the threshold, active control is enabled when it is higher than the threshold.
In active control mode when Throttle input is lower or higher than the respective thresholds PID control will be bypassed and MIN or MAX throttle will be sent to the ESC (right now only low threshold is active). An IWDG is implemented so if the timer that generates PWM signal for ESC control does not refresh the microcontroller will be reset (2 seconds timeout).
Accuracy data for Current readings (LAB enviroment 23C)
| Input Current (A) | Current Reading (A) | Absolute Error (A) | Relative Error |
|---|---|---|---|
| 3 | 3.6 | -0.6 | -20.00% |
| 5 | 5.4 | -0.4 | -8.00% |
| 7 | 7.15 | -0.15 | -2.14% |
| 9 | 9.01 | -0.01 | -0.11% |
| 11 | 10.9 | 0.1 | 0.91% |
| 13 | 12.85 | 0.15 | 1.15% |
| 15 | 14.8 | 0.2 | 1.33% |
| 17 | 16.8 | 0.2 | 1.18% |
| 19 | 18.75 | 0.25 | 1.32% |
| 21 | 20.9 | 0.1 | 0.48% |
| 23 | 22.9 | 0.1 | 0.43% |
| 25 | 24.9 | 0.1 | 0.40% |
| 27 | 26.9 | 0.1 | 0.37% |
| 29 | 28.85 | 0.15 | 0.52% |
| 31 | 30.8 | 0.2 | 0.65% |
| 33 | 32.8 | 0.2 | 0.61% |
| 35 | 34.8 | 0.2 | 0.57% |
| 37 | 36.75 | 0.25 | 0.68% |
| 39 | 38.75 | 0.25 | 0.64% |
| 41 | 40.75 | 0.25 | 0.61% |
| 43 | 42.75 | 0.25 | 0.58% |
| 45 | 44.75 | 0.25 | 0.56% |
| 47 | 46.75 | 0.25 | 0.53% |
| 49 | 48.7 | 0.3 | 0.61% |
| 51 | 50.7 | 0.3 | 0.59% |
| 53 | 52.65 | 0.35 | 0.66% |
| 55 | 54.6 | 0.4 | 0.73% |
Accuracy data for Voltage readings (LAB enviroment 23C)
| Input Voltage (V) | Voltage Reading (V) | Absolute error (V) | Relative error |
|---|---|---|---|
| 9.008 | 9.03 | -0.022 | -0.24% |
| 9.998 | 10.02 | -0.022 | -0.22% |
| 11.01 | 11.03 | -0.02 | -0.18% |
| 12.003 | 12.025 | -0.022 | -0.18% |
| 13.006 | 13.03 | -0.024 | -0.18% |
| 13.999 | 14.019 | -0.02 | -0.14% |
| 15.011 | 15.032 | -0.021 | -0.14% |
| 16.004 | 16.022 | -0.018 | -0.11% |
| 17.003 | 17.023 | -0.02 | -0.12% |
| 18.005 | 18.023 | -0.018 | -0.10% |
| 18.996 | 19.012 | -0.016 | -0.08% |
| 20.007 | 20.023 | -0.016 | -0.08% |
| 21 | 21.017 | -0.017 | -0.08% |
| 22.002 | 22.018 | -0.016 | -0.07% |
| 22.997 | 23.015 | -0.018 | -0.08% |
| 24.007 | 24.026 | -0.019 | -0.08% |
| 26.008 | 26.03 | -0.022 | -0.08% |
| 28.005 | 28.024 | -0.019 | -0.07% |
| 30.009 | 30.024 | -0.015 | -0.05% |
| 32.005 | 32.012 | -0.007 | -0.02% |
| 34.013 | 34.017 | -0.004 | -0.01% |