1.12.3 Offset Error – Differential Channels
With differential channels, the offset measurement can be performed much easier since no external input voltage is required. The two differential inputs can be connected to the same voltage internally and the resulting output value is then the offset error. Since this method gives no exact information on where the first transition occurs, it gives an error of ½ to 1 LSB (worst case).
To compensate for offset errors when using differential channels, subtract the offset error from every measured value.
In signed mode compensating for offset error caused by temperature, VCC or reference drift can easily be done using two channels. E.g. set the ADC channel 0 MUXPOS to ADC pin 0 and MUXNEG to ADC pin 1. With channel 1 you do the opposite, set MUXPOS to ADC pin 1 and MUXNEG to ADC pin 0. Channel 0 should give you a positive value and channel 1 should give you a negative value.
From these values you should get a real-time offset compensated result by applying this formula: (CH0 + CH1*-1)/2.