Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f94aa354 authored by Michael Hennerich's avatar Michael Hennerich Committed by Greg Kroah-Hartman
Browse files

iio: impedance-analyzer: New driver for AD5933/4 Impedance Converter, Network Analyzer



The AD5933 is a high precision impedance converter system solution
that combines an on-board frequency generator with a 12-bit, 1 MSPS,
analog-to-digital converter (ADC). The frequency generator allows an
external complex impedance to be excited with a known frequency.

The response signal from the impedance is sampled by the on-board ADC
and a discrete Fourier transform (DFT) is processed by an on-chip DSP engine.
The DFT algorithm returns a real (R) and imaginary (I) data-word at each
output frequency.

Changes since V1:

Apply list review feedback:
Consistently use poll_time_jiffies.
Use be|le cpu endian helpers where applicable.
Add various comments.

Changes since V2:

Fix KernelVersion tag in Documentation.
Declare ad5933_default_pdata static.
Fix typos.

Signed-off-by: default avatarMichael Hennerich <michael.hennerich@analog.com>
Acked-by: default avatarJonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 2051f25d
Loading
Loading
Loading
Loading
+30 −0
Original line number Diff line number Diff line
What:		/sys/bus/iio/devices/iio:deviceX/outY_freq_start
KernelVersion:	3.1.0
Contact:	linux-iio@vger.kernel.org
Description:
		Frequency sweep start frequency in Hz.

What:		/sys/bus/iio/devices/iio:deviceX/outY_freq_increment
KernelVersion:	3.1.0
Contact:	linux-iio@vger.kernel.org
Description:
		Frequency increment in Hz (step size) between consecutive
		frequency points along the sweep.

What:		/sys/bus/iio/devices/iio:deviceX/outY_freq_points
KernelVersion:	3.1.0
Contact:	linux-iio@vger.kernel.org
Description:
		Number of frequency points (steps) in the frequency sweep.
		This value, in conjunction with the outY_freq_start and the
		outY_freq_increment, determines the frequency sweep range
		for the sweep operation.

What:		/sys/bus/iio/devices/iio:deviceX/outY_settling_cycles
KernelVersion:	3.1.0
Contact:	linux-iio@vger.kernel.org
Description:
		Number of output excitation cycles (settling time cycles)
		that are allowed to pass through the unknown impedance,
		after each frequency increment, and before the ADC is triggered
		to perform a conversion sequence of the response signal.
+1 −0
Original line number Diff line number Diff line
@@ -62,6 +62,7 @@ source "drivers/staging/iio/addac/Kconfig"
source "drivers/staging/iio/dac/Kconfig"
source "drivers/staging/iio/dds/Kconfig"
source "drivers/staging/iio/gyro/Kconfig"
source "drivers/staging/iio/impedance-analyzer/Kconfig"
source "drivers/staging/iio/imu/Kconfig"
source "drivers/staging/iio/light/Kconfig"
source "drivers/staging/iio/magnetometer/Kconfig"
+1 −0
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@ obj-y += addac/
obj-y += dac/
obj-y += dds/
obj-y += gyro/
obj-y += impedance-analyzer/
obj-y += imu/
obj-y += light/
obj-y += magnetometer/
+16 −0
Original line number Diff line number Diff line
#
# Impedance Converter, Network Analyzer drivers
#
comment "Network Analyzer, Impedance Converters"

config AD5933
	tristate "Analog Devices AD5933, AD5934 driver"
	depends on I2C
	select IIO_RING_BUFFER
	select IIO_SW_RING
	help
	  Say yes here to build support for Analog Devices Impedance Converter,
	  Network Analyzer, AD5933/4, provides direct access via sysfs.

	  To compile this driver as a module, choose M here: the
	  module will be called ad5933.
+5 −0
Original line number Diff line number Diff line
#
# Makefile for Impedance Converter, Network Analyzer drivers
#

obj-$(CONFIG_AD5933) += ad5933.o
Loading