Skip to content

Commit 5c3ce0a

Browse files
Merge pull request #5200 from nvlsianpu/nrf51_adcIn_range_extend
Extend nRF51 AnalogIn voltage range to 3.6 V
2 parents df484e7 + f861b37 commit 5c3ce0a

File tree

1 file changed

+1
-1
lines changed
  • targets/TARGET_NORDIC/TARGET_NRF5/TARGET_MCU_NRF51822_UNIFIED

1 file changed

+1
-1
lines changed

targets/TARGET_NORDIC/TARGET_NRF5/TARGET_MCU_NRF51822_UNIFIED/analogin_api.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ uint16_t analogin_read_u16(analogin_t *obj)
6767

6868
// initialization by assigment because IAR dosen't support variable initializer in declaration statement.
6969
adc_channel.config.config.resolution = NRF_ADC_CONFIG_RES_10BIT;
70-
adc_channel.config.config.input = NRF_ADC_CONFIG_SCALING_INPUT_FULL_SCALE;
70+
adc_channel.config.config.input = NRF_ADC_CONFIG_SCALING_INPUT_ONE_THIRD;
7171
adc_channel.config.config.reference = NRF_ADC_CONFIG_REF_VBG;
7272
adc_channel.config.config.ain = (obj->adc_pin);
7373
adc_channel.p_next = NULL;

0 commit comments

Comments
 (0)