Add basic ADC support

Planning on abstracting this behind hardware setup APIs, but this works
for a simple demo until then
This commit is contained in:
Aaron Cook 2025-09-08 15:38:08 -05:00
commit d439778949
9 changed files with 151 additions and 0 deletions

10
includes/hardware/adc.h Normal file
View file

@ -0,0 +1,10 @@
#ifndef _INCLUDES_HARDWARE_ADC_H_
#define _INCLUDES_HARDWARE_ADC_H_
/**
* @brief Read the ADC value from the given channel index. See "adc-channels" in
* your board overlay file.
*/
int adc_get_mv(int channel);
#endif /* _INCLUDES_HARDWARE_ADC_H_ */