Lines Matching refs:adc
119 #define SMM665_VMON_ADC_TO_VOLTS(adc) ((adc) * vref / 256) argument
122 #define SMM665_12VIN_ADC_TO_VOLTS(adc) ((adc) * vref * 3 / 256) argument
125 #define SMM665_AIN_ADC_TO_VOLTS(adc) ((adc) * vref / 512) argument
128 #define SMM665_TEMP_ADC_TO_CELSIUS(adc) (((adc) <= 511) ? \ argument
129 ((int)(adc) * 1000 / 4) : \
130 (((int)(adc) - 0x400) * 1000 / 4))
147 u16 adc[SMM665_NUM_ADC]; /* adc values (raw) */ member
180 static int smm665_read_adc(struct smm665_data *data, int adc) in smm665_read_adc() argument
199 rv = i2c_smbus_read_byte_data(client, adc << 3); in smm665_read_adc()
231 if (radc != adc) { in smm665_read_adc()
233 adc, radc); in smm665_read_adc()
268 data->adc[i] = val; in smm665_update_device()
365 int adc = attr->index; in smm665_show_input() local
371 val = smm665_convert(data->adc[adc], adc); in smm665_show_input()