19 lines
425 B
C
19 lines
425 B
C
#pragma once
|
|
|
|
#include <stdint.h>
|
|
|
|
struct OpticalCurrentMeasurement {
|
|
uint16_t senseRaw;
|
|
uint16_t vccRaw;
|
|
float senseAdcVoltage;
|
|
float vccAdcVoltage;
|
|
float senseVoltage;
|
|
float vccVoltage;
|
|
float currentMa;
|
|
};
|
|
|
|
void optical_current_begin(void);
|
|
bool optical_current_poll(OpticalCurrentMeasurement &measurement);
|
|
OpticalCurrentMeasurement optical_get_led_measurement(void);
|
|
float optical_get_led_current_ma(void);
|