AnsweredAssumed Answered

AD5933 number of measurements

Question asked by north on Jun 18, 2015
Latest reply on Jun 22, 2015 by mcee



I am using AD5933 with AVR ATmega128. I tried to configure the IC for the following task: do sweep in 10k-100kHz range with 10k increment and repeat every frequency 60 times. I am using external 16 MHz clock.


Here is my issue... I expected that I will have 600 measurement points, but I have only 540 (see attached file for capacitor impedance magnitude). Here is my configuration:

float start_freq = 10000.0;

float freq_inc = 10000.0;

unsigned char num_inc = 9;


start_freq = start_freq*33.554432;

   pom_b[0] = (0x000000ff) & ((unsigned long int)start_freq>>16);

   pom_b[1] = (0x000000ff) & ((unsigned long int)start_freq>>8);

   pom_b[2] = (0x000000ff) & ((unsigned long int)start_freq);

   Byte_write (0x82, pom_b[0]);

   Byte_write (0x83, pom_b[1]);

   Byte_write (0x84, pom_b[2]);


freq_inc = 33.554432*freq_inc;

   pom_b[0] = (0x000000ff) & ((unsigned long int)freq_inc>>16);

   pom_b[1] = (0x000000ff) & ((unsigned long int)freq_inc>>8);

   pom_b[2] = (0x000000ff) & ((unsigned long int)freq_inc);

   Byte_write (0x85, pom_b[0]);

   Byte_write (0x86, pom_b[1]);

   Byte_write (0x87, pom_b[2]);


   pom_b[0] = (num_inc>>8); //Hi (num_of_inc_pom); //

   pom_b[1] = (num_inc); //Lo (num_of_inc_pom); //


   Byte_write (0x88, pom_b[0]);

   Byte_write (0x89, pom_b[1]);


  //place AD5933 in standby

  Byte_write(0x80, 0xB5);

  //externall clock 16.00 MHz

  Byte_write (0x81, 0x01);

  //place AD5933 in standby

  Byte_write (0x80, 0xB5);

  //2 Vp-p, x1 gain

  Byte_write(0x80, 0x05);

  //init with start frequency

  Byte_write(0x80, 0x15);


  //start sweep

  Byte_write(0x80, 0x25);

while(!(Byte_read(0x8F) & 0x04))



Did I miss something?


Should I change configuration for this task: frequency sweep from 10k to 100k with 10 k step: (10 (init), 20 (step1), 30, 40, 50, 60, 70, 80, 90 and 100k (step 9)).