Lines Matching refs:adc_diff
151 s16 adc_diff; member
1606 state->adc_diff = dib0090_read_reg(state, 0x1d); in dib0090_get_offset()
1614 state->adc_diff -= dib0090_read_reg(state, 0x1d); in dib0090_get_offset()
1721 dprintk("adc_diff = %d, current step= %d\n", (u32) state->adc_diff, state->step); in dib0090_dc_offset_calibration()
1722 if (state->step == 0 && state->adc_diff < 0) { in dib0090_dc_offset_calibration()
1727 …dprintk("adc_diff = %d, min_adc_diff = %d current_step = %d\n", state->adc_diff, state->min_adc_di… in dib0090_dc_offset_calibration()
1731 if (state->dc->pga && state->adc_diff < 0) in dib0090_dc_offset_calibration()
1733 if (state->dc->pga == 0 && state->adc_diff > 0) in dib0090_dc_offset_calibration()
1738 if ((state->adc_diff & 0x8000) == (state->min_adc_diff & 0x8000) && steps(state->step) < 15) { in dib0090_dc_offset_calibration()
1741 state->min_adc_diff = state->adc_diff; in dib0090_dc_offset_calibration()
1745 if (abs(state->adc_diff) > abs(state->min_adc_diff)) { in dib0090_dc_offset_calibration()
1746 …dc_diff N = %d > adc_diff step N-1 = %d, Come back one step\n", state->adc_diff, state->min_adc_d… in dib0090_dc_offset_calibration()
1752 state->dc->addr, state->adc_diff, state->step); in dib0090_dc_offset_calibration()
2107 state->adc_diff = 3000; in dib0090_captrim_search()
2153 if (adc < state->adc_diff) { in dib0090_captrim_search()
2154 …CAPTRIM=%d is closer to target (%d/%d)\n", (u32) state->captrim, (u32) adc, (u32) state->adc_diff); in dib0090_captrim_search()
2155 state->adc_diff = adc; in dib0090_captrim_search()
2199 state->adc_diff = dib0090_get_slow_adc_val(state); in dib0090_get_temperature()
2206 state->temperature = ((s16) ((val - state->adc_diff) * 180) >> 8) + 55; in dib0090_get_temperature()