monitor averaging of analog inputs (cmd line util)

Applications, development tools, FPGA, C, WEB
Post Reply
edgo
Posts: 34
Joined: Wed Jun 25, 2014 11:38 pm

monitor averaging of analog inputs (cmd line util)

Post by edgo » Mon Dec 15, 2014 8:30 pm

All, please find monitor averaging of analog inputs (cmd line util) here in the /Test/ directory:

https://github.com/edgo914/RedPitaya

Usage now shows the following:

redpitaya> monitor
monitor version 0.00-0000-devbuild

Usage:
read addr: address
write addr: address value
read analog mixed signals: -ams [-a for averaging over 1 sec [number of samples, default of 100]]
set slow DAC: -sdac AO0 AO1 AO2 AO3 [V]

An example of this being run:

redpitaya> monitor -ams -a 1000
#ID Desc Raw Val
0 Temp(0C-85C) af7 72.535
1 AI0(0-3.5V) 11 0.033
2 AI1(0-3.5V) 24 0.062
3 AI2(0-3.5V) 13 0.034
4 AI3(0-3.5V) 15 0.034

The above data shows averaging of the analog inputs, 1000 samples over approx. 1 second timeframe.

Note that only the first 5 lines of the analog mixed signals is output for this mode. The Zynq SoC temperature is also averaged, for consistency, though not the goal of this exercise.

Why did we create this? We found that running "monitor -ams" showed too much fluctuation over multiple runs for the analog inputs. We hoped to use the analog inputs for resistance temperate detectors (RTDs). Unfortunately the 12-bit resolution was found to not be sensitive enough for our purposes (got spoiled by 24-bits, I guess!). Hopefully this averaging feature will be of use to others.

dam5h
Posts: 1
Joined: Fri Sep 05, 2014 4:17 pm

Re: monitor averaging of analog inputs (cmd line util)

Post by dam5h » Fri Jan 09, 2015 8:23 pm

We need averaging in our application as well so I was happy to see this post. I'd like to average as many time traces as I can fit on the device, which I believe based on the bit limit is 260k.

Looking at the diff from the main branch it looks like all the alteration here is in the C code. Did you consider doing averaging in real time on the FPGA? That is our goal as we need the processing to be as fast as possible. Nevertheless I will take a look at your code to see what you've done, thank you for sharing!

edgo
Posts: 34
Joined: Wed Jun 25, 2014 11:38 pm

Re: monitor averaging of analog inputs (cmd line util)

Post by edgo » Fri Jan 09, 2015 10:19 pm

Did not consider averaging in real time on the FPGA. Once we determined that there was not enough resolution for our purposes ... well, for us it wasn't a matter of speed, but accuracy. Not accurate enough.

Post Reply
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie

Who is online

Users browsing this forum: No registered users and 20 guests