Re: [PATCH v2 7/7] iio: adc: Add ti-ads1263-adc2 driver
From: Kurt Borja
Date: Sun Jun 28 2026 - 16:09:00 EST
On Sun Jun 28, 2026 at 12:22 PM -05, David Lechner wrote:
> On 6/28/26 12:36 AM, Kurt Borja wrote:
>> The TI ADS1263 embeds a second 24-bit delta-sigma ADC (ADC2) with its
>> own input mux, reference, gain and sample-rate selection.
>>
>> Model ADC2 as a separate IIO device on the auxiliary bus: the ti-ads1262
>> SPI driver instantiates the auxiliary device and exports a small set of
>> TI_ADS1262-namespaced helpers for the conversion and register accesses
>> that must go through the shared bus. ADC2 channels are derived from the
>> parent's configured channels.
>>
> Can these just be additional channels in the main iio device rather
> than a separate iio device?
I guess we can do it, but wouldn't it be quite a mess? I think doing it
that way adds a lot of complexity: channel naming, available scan masks
(because both ADCs can be sampled at the same time), optimized software
sequencing would only work in ADC1 channels, ADC2 doesn't have a DRDY
IRQ, etc.
IMO separating both drivers makes everything simpler, easier to
understand and easier to maintain in the future.
--
Thanks,
~ Kurt