AnsweredAssumed Answered

IIO AD7192 driver ac excitation option works backwards?

Question asked by Paul.Moir on Sep 17, 2013
Latest reply on Sep 26, 2013 by larsc

Hello,

 

I've been using the ad7192 IIO driver with an AD7195 and I think I've noticed a problem with the AC bridge excitation.  This feature should only be available on the AD7195, but when you identify the driver as an ad7195 rather than ad7192, the control file in /sys/bus/iio... disappears.  That is to say, it seems to work opposite of what's expected.

 

In ad7192.c, about line 459, the ad7192 and ad7195 options are defined I think wrongly:

 

static struct attribute *ad7192_attributes[] = {
&iio_dev_attr_sampling_frequency.dev_attr.attr,
&iio_dev_attr_in_v_m_v_scale_available.dev_attr.attr,
&iio_dev_attr_in_voltage_scale_available.dev_attr.attr,
&iio_dev_attr_bridge_switch_en.dev_attr.attr,
&iio_dev_attr_ac_excitation_en.dev_attr.attr,
NULL
};

...


static struct attribute *ad7195_attributes[] = {
&iio_dev_attr_sampling_frequency.dev_attr.attr,
&iio_dev_attr_in_v_m_v_scale_available.dev_attr.attr,
&iio_dev_attr_in_voltage_scale_available.dev_attr.attr,
&iio_dev_attr_bridge_switch_en.dev_attr.attr,
NULL
};

 

It's no problem for me; I can work around it.  But if this is a bug, who do I report it to?

 

Thanks for your time, and thanks very much for providing the driver.

Outcomes