This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
resources:eval:user-guides:ad4130:mbed_iio_app [06 Jul 2022 11:33] – minor updates2 Mahesh Phalke | resources:eval:user-guides:ad4130:mbed_iio_app [31 May 2023 07:54] (current) – Mahesh Phalke | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ===== AD4130 | + | ===== AD4130 IIO Application===== |
- | ====Introduction==== | + | |
- | This page gives an overview of using the ARM Mbed platform | + | ===== Introduction |
+ | |||
+ | This page gives an overview of using the ARM platforms | ||
Devices AD4130 Evaluation board and SDP-K1 controller board. This example code leverages | Devices AD4130 Evaluation board and SDP-K1 controller board. This example code leverages | ||
the ADI developed IIO (Industrial Input Output) ecosystem to evaluate the AD4130 device by providing a | the ADI developed IIO (Industrial Input Output) ecosystem to evaluate the AD4130 device by providing a | ||
device debug and data capture support. | device debug and data capture support. | ||
- | The overview of an entire system is shown below: | ||
- | |||
- | {{ : | ||
- | IIO oscilloscope is used as a client application running on windows-os, which is ADI developed GUI for ADC data visualization and device debug. The physical interface used for communicating client application with firmware application (IIO device) is UART/VirtualCOM (*For now only SDP-K1 supports high speed VirtualCOM port @1Mbps or higher speed for faster data transmission). The firmware application communicates with IIO device (AD4130) using ADI No-OS drivers and platform drivers middle-ware | + | {{section> |
---- | ---- | ||
===Useful links=== | ===Useful links=== | ||
+ | {{section> | ||
* [[adi> | * [[adi> | ||
* [[adi> | * [[adi> | ||
- | * [[https:// | ||
- | * [[https:// | ||
---- | ---- | ||
Line 30: | Line 28: | ||
< | < | ||
- | AD4130 uses SPI communication for device register access and data capture. For data transmission to IIO client, VirtualCOM Or UART serial communication is used. SDP-K1 by default uses the VCOM serial interface for higher speed data transmission. | + | AD4130 uses SPI communication for device register access and data capture. |
- | SDP-K1 is powered through USB connections from the computer. SDP-K1 acts as a Serial device when connected to PC, which creates a COM Port to connect to IIO Oscilloscope GUI running on windows-os. The COM port assigned to a device can be seen through the device manager for windows-based OS. | + | |
- | {{ :resources:eval:user-guides: | + | {{section>resources/tools-software/ |
- | + | ||
- | SDP-K1 can support | + | |
- | + | ||
- | {{ : | + | |
---- | ---- | ||
Line 43: | Line 36: | ||
===== Software Downloads ===== | ===== Software Downloads ===== | ||
- | <WRAP round download> | + | {{section>resources/tools-software/product-support-software/iio_support_software_downloads#Software Downloads& |
- | Latest firmware (Use below link): | + | |
- | * [[https:// | + | |
- | </ | + | |
- | + | ||
- | === Quick Start to Use Mbed IIO Firmware === | + | |
- | If you have some familiarity with the Mbed platform, the following is a basic list of steps required to start running the code, see below for more detail: | + | |
- | + | ||
- | * Connect the AD4130 EVAL-board to the SDP-K1 controller board as specified in hardware connections section. | + | |
- | * Connect the SDP-K1 controller board to your computer over USB provided along with SDP-K1 board. | + | |
- | * Import the code into Keil Studio from above firmware download link by using " | + | |
- | * Right click on the project name and select ‘Set Active Project’ option. | + | |
- | + | ||
- | {{ : | + | |
- | + | ||
- | * Fix library import issues by selecting ‘Mbed Libraries’ tab at the bottom side of IDE and then clicking on the ‘Fix all problems’ option. Allow some time to checkout all library dependency. | + | |
- | + | ||
- | {{ : | + | |
- | + | ||
- | * Compile the code as shown below: | + | |
- | {{ : | + | |
- | + | ||
- | * After a successful build, a binary will be generated and available for download - store this onto your local drive. | + | |
- | * Drag and drop this binary to the USB drive hosted by your controller board (e.g. SDP-K1) to program the microcontroller. | + | |
- | + | ||
- | ==== Libiio: IIO Library ==== | + | |
- | This library provides an abstracted library interface to communicate IIO device and IIO client application (e.g. IIO Oscilloscope) without worrying about the low level hardware details. Download and install below [[wiki/LibIIO#libiio]] windows installer in your computer. | + | |
- | <WRAP round download> | + | |
- | Libiio installer for Windows (Use below link): | + | |
- | * [[repo> | + | |
- | </ | + | |
- | + | ||
- | ==== IIO Oscilloscope (Client) ==== | + | |
- | This is a GUI (Graphical User Interface) based IIO client application for data visualization and device configuration/ | + | |
- | <WRAP round download> | + | |
- | Download and install below IIO Oscilloscope windows installer in your computer. | + | |
- | IIO Oscilloscope installer for Windows (Use below link): | + | |
- | * [[repo> | + | |
- | </ | + | |
---- | ---- | ||
==== Evaluating AD4130 Using IIO Ecosystem ==== | ==== Evaluating AD4130 Using IIO Ecosystem ==== | ||
- | <note>Ensure that hardware connection has been made properly in between Controller Board (SDP-K1) and AD4130 Eval board. Also ensure all software's (IIO firmware, Libiio windows installer and IIO Oscilloscope windows installer) are downloaded and installed in your computer before trying to communicate with AD4130 device..< | + | |
+ | {{section>resources/ | ||
==== Running IIO Oscilloscope (Client) ==== | ==== Running IIO Oscilloscope (Client) ==== | ||
Line 140: | Line 96: | ||
{{ : | {{ : | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ==== Python Environment and Scripts ==== | ||
+ | |||
+ | Data capture, sensor measurement, | ||
+ | |||
+ | {{section> | ||
---- | ---- | ||
Line 179: | Line 143: | ||
=== Sensor Channels Calibration === | === Sensor Channels Calibration === | ||
It is possible to calibrate the device channels which are connected to external sensors. The sensors calibration (gain and offset) is done by executing the python script “ad4130_calibration.py”. | It is possible to calibrate the device channels which are connected to external sensors. The sensors calibration (gain and offset) is done by executing the python script “ad4130_calibration.py”. | ||
- | |||
- | ---- | ||
- | |||
- | ==== Python Environment and Scripts ==== | ||
- | Data capture, sensor measurement, | ||
- | |||
- | === Setting-up Python Environment === | ||
- | * Install python into your local machine. The python scripts are developed and executed using python 3.8.0 version, so recommend using version 3.8.0 or beyond. [[https:// | ||
- | * Once python is installed, make sure the environment path (on windows machine) is set properly. You can verify if python is installed properly by typing “python --version” command on command line tool such as gitbash, command prompt, power shell, etc. | ||
- | {{ : | ||
- | |||
- | * Install the “pyadi-iio” python package by executing command “python -m pip install pyadi-iio”. Detailed guide on installing it is available here: [[repo> | ||
- | |||
- | {{ : | ||
- | |||
- | === Modifying/ | ||
- | * All python scripts specific to ad4130 IIO firmware are stored into “scripts” folder present in the project directory. So, any script must be executed from this folder. | ||
- | |||
- | * Update the ‘uri’ interface in script according to COM port assigned to your device (sdp-k1). | ||
- | |||
- | {{ : | ||
- | |||
- | * Executing the python script by using command “python script_name.py” | ||
---- | ---- |