Update Ad4630 class and improve example#691
Update Ad4630 class and improve example#691machschmitt wants to merge 5 commits intoanalogdevicesinc:mainfrom
Conversation
tfcollins
left a comment
There was a problem hiding this comment.
Can you provide a context file for emulation testing?
|
|
||
| @property | ||
| def sample_averaging(self): | ||
| """Get the sample averaging. Only available in 30bit averaged mode.""" |
There was a problem hiding this comment.
Is the docstring and property name still correct? Does this apply to all supported parts?
There was a problem hiding this comment.
Hi @tfcollins
All parts are supported by the same drivers both in Linux and No-OS.
The IIO ABI used for controlling the sample averaging is oversampling_ratio. That applies to all supported parts.
The docstring abstracts the oversampling_ratio interface and presents it to users in terms of data sheet nomenclature (which is sample averaging). Should we update the docstrigs to match the underlying interfaces?
There was a problem hiding this comment.
Can you be more descriptive on what this means. sample_averaging seems to be a boolean but oversampling_ratio would be an integer
There was a problem hiding this comment.
| @@ -113,26 +119,25 @@ def sample_rate(self, rate): | |||
| @property | |||
| def sample_averaging_avail(self): | |||
| """Get list of all the sample averaging values available. Only available in 30bit averaged mode.""" | |||
| "ad4630-16", | ||
| "ad4630-24", | ||
| "ad4632-16", | ||
| "ad4632-24", |
There was a problem hiding this comment.
Update supported parts MD
AD4632-16 and AD4632-24 are now support in Linux. Add AD4632-16 and AD4632-24 to the list of supported/compatible parts. Also add those to the list of supported parts. Signed-off-by: Marcelo Schmitt <marcelo.schmitt@analog.com>
Use python argparse [1] to handle command-line arguments thus making the example more flexible with respect to its input arguments. This also extends the example to work with other ADCs that belong to the AD4000 series by enabling a device argument and using it to instantiate the correct ADC object. [1]: https://docs.python.org/3/library/argparse.html Signed-off-by: Marcelo Schmitt <marcelo.schmitt@analog.com>
In Linux, sample averaging for AD4630 and similar ADCs is supported through oversampling ratio attributes. Use the supported interfaces to handle sample averaging. Signed-off-by: Marcelo Schmitt <marcelo.schmitt@analog.com>
Add label to AD4630 plot axes to make it easier to understand data. Signed-off-by: Marcelo Schmitt <marcelo.schmitt@analog.com>
Add ADAQ4216 context file for emulation testing. Signed-off-by: Marcelo Schmitt <marcelo.schmitt@analog.com>
1a16f30 to
d74a7c7
Compare
|
Change log v1 -> v2:
|
Description
Update AD4630 pyadi-iio class to support AD4632-16/32 and to use supported Linux kernel interfaces for AD4630 and similar ADCs.
Also, update AD4630 example to use argparse, making the example more flexible with respect to command-line arguments.
Type of change
Please delete options that are not relevant.
How has this been tested?
Tested with ADAQ4216 remote setup.
Test Configuration:
Hardware: ADAQ4216
OS: Linux kernel 6.17-rc3
Documentation
No documentation changes are needed.
Checklist: