Removed all references to MICROCONTROLLER_VOLTAGE_DISABLE
This commit is contained in:
parent
72db13fc2d
commit
bc34403d71
@ -279,9 +279,6 @@ float common_hal_mcu_processor_get_temperature(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
float common_hal_mcu_processor_get_voltage(void) {
|
float common_hal_mcu_processor_get_voltage(void) {
|
||||||
#if MICROCONTROLLER_VOLTAGE_DISABLE
|
|
||||||
return NAN;
|
|
||||||
#else
|
|
||||||
struct adc_sync_descriptor adc;
|
struct adc_sync_descriptor adc;
|
||||||
|
|
||||||
static Adc *adc_insts[] = ADC_INSTS;
|
static Adc *adc_insts[] = ADC_INSTS;
|
||||||
@ -327,7 +324,6 @@ float common_hal_mcu_processor_get_voltage(void) {
|
|||||||
adc_sync_deinit(&adc);
|
adc_sync_deinit(&adc);
|
||||||
// Multiply by 4 to compensate for SCALEDIOVCC division by 4.
|
// Multiply by 4 to compensate for SCALEDIOVCC division by 4.
|
||||||
return (reading / 4095.0f) * 4.0f;
|
return (reading / 4095.0f) * 4.0f;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t common_hal_mcu_processor_get_frequency(void) {
|
uint32_t common_hal_mcu_processor_get_frequency(void) {
|
||||||
|
@ -73,9 +73,6 @@
|
|||||||
#define MICROPY_PY_SYS_PLATFORM "MicroChip SAMD51"
|
#define MICROPY_PY_SYS_PLATFORM "MicroChip SAMD51"
|
||||||
#elif defined(SAME54)
|
#elif defined(SAME54)
|
||||||
#define MICROPY_PY_SYS_PLATFORM "MicroChip SAME54"
|
#define MICROPY_PY_SYS_PLATFORM "MicroChip SAME54"
|
||||||
// #ifndef MICROCONTROLLER_VOLTAGE_DISABLE
|
|
||||||
// #define MICROCONTROLLER_VOLTAGE_DISABLE (1)
|
|
||||||
// #endif
|
|
||||||
#endif
|
#endif
|
||||||
#define SPI_FLASH_MAX_BAUDRATE 24000000
|
#define SPI_FLASH_MAX_BAUDRATE 24000000
|
||||||
#define MICROPY_PY_BUILTINS_NOTIMPLEMENTED (1)
|
#define MICROPY_PY_BUILTINS_NOTIMPLEMENTED (1)
|
||||||
@ -243,8 +240,4 @@
|
|||||||
CIRCUITPY_COMMON_ROOT_POINTERS \
|
CIRCUITPY_COMMON_ROOT_POINTERS \
|
||||||
mp_obj_t playing_audio[AUDIO_DMA_CHANNEL_COUNT];
|
mp_obj_t playing_audio[AUDIO_DMA_CHANNEL_COUNT];
|
||||||
|
|
||||||
#ifndef MICROCONTROLLER_VOLTAGE_DISABLE
|
|
||||||
#define MICROCONTROLLER_VOLTAGE_DISABLE (0)
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif // __INCLUDED_MPCONFIGPORT_H
|
#endif // __INCLUDED_MPCONFIGPORT_H
|
||||||
|
Loading…
x
Reference in New Issue
Block a user