ADS7846 code optimation