diff --git a/src/machine/machine_rp2_adc.go b/src/machine/machine_rp2_adc.go index fc9a8268e..d5f21b1aa 100644 --- a/src/machine/machine_rp2_adc.go +++ b/src/machine/machine_rp2_adc.go @@ -73,14 +73,15 @@ func (c ADCChannel) Configure(config ADCConfig) error { func (c ADCChannel) getOnce() uint16 { // Make it safe to sample multiple ADC channels in separate go routines. adcLock.Lock() - rp.ADC.CS.ReplaceBits(uint32(c), 0b111, rp.ADC_CS_AINSEL_Pos) + rp.ADC.CS.ReplaceBits(uint32(c)<