adc hal code generation