Quote:is there a way to know which code is the best code? the present code or the previous code?
Forget what is closest to the Actual Value. This is the funda of Digital Calibration.
You set your resolution acc. to max. error you can tolerate.
After that, you just have to accept one or two bit error depending on your scheme.
Resolving / Rounding off final code requires Delta/2 comparison, which again means higher resolution either in analog OR Digital cktry --> Hardware Overhead.