Re: [PATCH 0/2] iio: chemical: Add driver and bindings for acd10

From: Akhilesh Patil

Date: Wed Dec 02 2026 - 07:06:17 EST


On Mon, Nov 23, 2026 at 11:28:42AM +0200, Andy Shevchenko wrote:
> On Sun, Nov 22, 2026 at 06:30:43AM +0000, Akhilesh Patil wrote:
> > This patch series adds support for Aosong ASAIR acd10 CO2 (Carbon
> > dioxide) sensor driver in IIO subsystem.
>
> There is no answer to the question "Why a brand new driver?"

Sure. Will add a section describing it in v2 patch series.

>
> > Patch 1: Adds bindings for this hardware
> > Patch 2: Adds driver code for acd10 under drivers/iio/chemical
> >
> > Quick overview of acd10:
> > - This is CO2 sensor based on NDIR technology.
> > - Can measure CO2 concentration up to 5000ppm
> > - Supports serial interface over UART with 1200 baud rate.
> >
> > Datasheet: https://www.es.co.th/Schemetic/PDF/ACD10.PDF
> >
> > Protocol:
> > acd10 defines 4 types of UART frames - read co2, get software version,
> > get instrument number and set single point calibration.
> > Frame format: fixed header, length of data, command code, Actual data,
> > checksum. Response from the sensor follows same format.
> > Total length of each tx and rx frame for 4 commands is fixed and defined in
> > the datasheet. Driver uses this information to write and read from
> > sensor for each command over serdev interface.
> >
> > Testing:
> > Driver is tested on Texas Instruments am62x sk board with sensor
> > connected on UART5 on 40pin IO expander. Additional 3.3 to 5v
> > bidirectional logic translator is used to interface with 3.3v IOs of
> > am62x. Values are read using iio sysfs interface. Also I have blown into
> > the sensor to observe sensor output increase due to CO2 in my exhale.
> > Waveforms for read co2, get sw rev and get ins num commands are
> > validated on logic analyzer.
> >
> > Slight deviation from datasheet:
> > For command get software version, datasheet mentions frame length of 16
> > bytes including D11 reserved, however it is observed that sensor sends
> > 15 bytes with length field 0xb (11 bytes of data), but actual data is 10
> > bytes. Hence, this is handled in the driver.
> >
> > Driver supports reading co2, getting sw version and instrument number.
> > Single point calibration and preheat implementation is left for
> > future contributions.
>
> --
> With Best Regards,
> Andy Shevchenko
>
>