Skip to content

Commit 15a14e8

Browse files
committed
replicate anologWrite fixes for analogRead
1 parent 47abc87 commit 15a14e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cores/arduino/sdk/core-implement/CommonAnalog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ float getVCCV( void ){
8585

8686
int indexAnalogRead(pin_size_t index){
8787
// todo: replace with mbed "AnalogIn" functionality
88-
pin_size_t pinNumber = pinNumberByIndex(index);
88+
pin_size_t pinNumber = pinNameByIndex(index);
8989
if(pinNumber == (pin_size_t)NC){ return 0; }
9090
ap3_adc_channel_config_t* config = NULL;
9191
for(size_t idx = 0; idx < (sizeof(ap3_adc_channel_configs)/sizeof(ap3_adc_channel_config_t)); idx++){

0 commit comments

Comments
 (0)