Source Code For Impedance Sweep - Analog Devices EVAL-AD5933EBZ User Manual

Evaluating the ad5933 1 msps, 12-bit impedance converter network analyzer
Table of Contents

Advertisement

UG-364

SOURCE CODE FOR IMPEDANCE SWEEP

RESET: BY ISSUING A RESET COMMAND TO
THE CONTROL REGISTER, THE DEVICE IS
PLACED IN STANDBY MODE.
This section outlines the evaluation board code structure required
to set up the
AD5933
frequency sweep. The sweep flow outline is
shown in Figure 24. Each section of the flow diagram is explained
with the help of the visual basic code extracts. The firmware
code (c code), which is downloaded to the USB microcontroller
connected to the AD5933, implements the low level I
control (that is, read and write vendor request).
The code extract, which is shown in the Evaluation Board
Source Code Extract section, shows how to program a single
frequency sweep starting at 30 kHz, with a frequency step of
10 Hz and with 150 points in the sweep. The code assumes
that a 16 MHz clock signal is connected to Pin 8 (MCLK) of
PROGRAM FREQUENCY SWEEP PARAMETERS
INTO RELEVANT REGISTERS
(1) START FREQUENCY REGISTER
(2) NUMBER OF INCREMENTS REGISTER
(3) FREQUENCY INCREMENT REGISTER
PLACE THE AD5933 INTO STANDBY MODE.
PROGRAM THE INITIALIZE WITH START
FREQUENCY COMMAND TO THE CONTROL
REGISTER.
AFTER A SUFFICIENT AMOUNT OF SETTLING
TIME HAS ELAPSED, PROGRAM THE START
FREQUENCY SWEEP COMMAND IN THE
CONTROL REGISTER.
POLL THE STATUS REGISTER TO CHECK IF
THE DFT CONVERSION IS COMPLETE.
N
Y
READ VALUES FROM THE REAL AND
IMAGINARY DATA REGISTER.
Y
POLL THE STATUS REGISTER TO CHECK IF
FREQUENCY SWEEP IS COMPLETE.
Y
PROGRAM THE AD5933
INTO POWER-DOWN MODE.
Figure 24. Sweep Flow Outline
the AD5933. The impedance range under test is from 90 kΩ
to 110 kΩ. The gain factor is calculated at the midpoint of the
frequency sweep, that is, 30.750 kHz. The calibration is carried
out with a 100 kΩ resistor connected between VOUT and VIN.
The feedback resistor = 100 kΩ.
2
C signal
The first step in Figure 24 is to program the three sweep
parameters necessary to define the frequency sweep (that is,
the start frequency, number of increments, and frequency
increments). Refer to the
Rev. 0 | Page 12 of 28
Evaluation Board User Guide
PROGRAM THE INCREMENT FREQUENCY OR
THE REPEAT FREQUENCY COMMAND TO THE
CONTROL REGISTER.
N
AD5933
data sheet for more details.

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the EVAL-AD5933EBZ and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents