Calibration

The test fixture design is outside the scope of this application note. However, a flowchart of a calibration firmware in the AVR is given. It uses the external DAC through the test fixture and runs its own calibration algorithm.

There is no need for using several ADC channels, only switching between single ended and differential conversion. The ADC parameters are the same regardless of which channel is used. The multiplexer does not introduce any errors.

The firmware could be implemented as shown in the figure below.

Figure 1. Flowchart for Calibration Firmware

This piece of firmware is programmed into the AVR prior to calibration, and is replaced by the actual application firmware afterward. Once again, the EESAVE fuse must be programmed to preserve the calibration parameters in EEPROM during Flash reprogramming.