generic_buffer and 24 bits samples

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

 



Greetings,

I'm trying to use an st_pressure based sensor to sample pressure
data using generic_buffer tool. However it seems that it does not
support data packed onto 24 bits samples.
st_pressure driver defines scan_type for my device as:
<code>
/* ... */
    .scan_type = {
        .sign = 'u',
        .realbits = 24,
        .storagebits = 24,
        .endianness = IIO_LE,
    },
</code>

What is the proper way to make this work ? Using 32 bits storagebits
field ? Enhance generic_buffer to support 24 bits samples ? Anything
else ??

It seems iio_compute_scan_bytes consider sample data as a simple byte
stream. So I'm wondering what are the alignment constraints for sample
start address ? Should they be aligned onto their natural "word"
boundaries, i.e. 16 bits for u16, 32 bits for u32, etc... ? And for
24 bits samples ?

Regards.
Grégor
--
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