build fix for non pico boards

This commit is contained in:
graham sanderson 2023-06-08 10:04:05 -05:00
parent 4005af122e
commit 0d4a9f28c0
1 changed files with 2 additions and 1 deletions

View File

@ -35,7 +35,7 @@ int power_source(bool *battery_powered) {
int power_voltage(float *voltage_result) {
#ifndef PICO_VSYS_PIN
return PICO_ERROR_NO_DATA;
#endif
#else
#if CYW43_USES_VSYS_PIN
cyw43_thread_enter();
// Make sure cyw43 is awake
@ -73,4 +73,5 @@ int power_voltage(float *voltage_result) {
const float conversion_factor = 3.3f / (1 << 12);
*voltage_result = vsys * 3 * conversion_factor;
return PICO_OK;
#endif
}