Measuring current and voltage from the solar panel.
More...
#include <stdint.h>
Go to the source code of this file.
Measuring current and voltage from the solar panel.
Definition in file measure.h.
◆ adc_init()
Initialize ADC and pins for measuring current and voltage
Definition at line 16 of file measure.c.
◆ measure_current()
uint16_t measure_current |
( |
uint16_t |
offset | ) |
|
Measure the current on the solar panel. This function is expected to do some filtering
- Parameters
-
offset | : the offset as measured by measure_current_offset |
- Returns
- the current in microamperes
Definition at line 49 of file measure.c.
◆ measure_voltage()
uint16_t measure_voltage |
( |
void |
| ) |
|
Measure the voltage on the channel for the current. This function is expected to do some filtering.
- Returns
- The offset
Definition at line 37 of file measure.c.