ADC auto-calibration status not checked
Auto-calibration of the ADCs is initiated here:
The code waits for the calibration to complete, but does not check whether it succeeded or not.
According to the ADC's manual, bit D14 of the board control register (BCR) will be set high if the calibration succeeded. This bit should be checked and reported by the code.