ADC code working