Best practices for sending digital data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I'm writing an IIO driver for custom IMU hardware. The most important
output is analog. However, the hardware also provides very important
digital data about the status of the measurement.

The register is basically a bitmask. Some of the bits are pertinent to
the specific measurement. They indicate whether the data is valid and
whether the measurements are saturated. So it makes sense to put them
to the same buffer as the analog measurements rather than use
attributes.

What would be the recommended channel type? Is that IIO_INDEX or maybe
IIO_COUNT? Or should I patch the kernel to add IIO_DIGITAL or
IIO_BITMAP?

On a related note, why is IIO so hard to extend with new channel types
and attributes? Why cannot I add angular acceleration in the driver
without patching the IIO subsystem? Why cannot I use yaw, pitch and
roll instead of X, Y and Z as the attributes? Why is IIO_MOD_CO2
defined but IIO_MOD_O2 is not, let alone IIO_MOD_DIMETHYLHYDRAZINE?

I understand that the IIO layer tries to be helpful with
standardization, but I believe it's too restrictive.

-- 
Regards,
Pavel Roskin
--
To unsubscribe from this list: send the line "unsubscribe linux-iio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux