Save average amplitude at each frequency

Forum for discussing PicoScope version 6 (non-automotive version)
Post Reply
eltitofranki
Newbie
Posts: 0
Joined: Tue Feb 17, 2015 11:43 am

Save average amplitude at each frequency

Post by eltitofranki »

Hi,

I need to measure the oscillation modes of a metallic box. The setup is as follows: A function generator is connected to an amplifier, which is connected to a piezoelectric that acts as a sound emmiter. Another piezo is connected as a sound receiver, and this is connected to PicoScope 4227. The signal is displayed correctly in PicoScope 6 in Windows. However, I need to make a frequency sweep and, for each value of the frequency (which I change manually from the function generator), save the average amplitude. Hence, I need a text file with one column as the frequency and another column as the amplitude, I do not need to save the whole waveform.
How can I do it?
Any help would be appreciated.

Hitesh

Re: Save average amplitude at each frequency

Post by Hitesh »

Hi eltitofranki,

There are two ways of capturing information but unfortunately they will not generate a single file with the values so you will need to manually create this:

1. Use Maths Channels

You can the Math Channels feature in PicoScope 6 to create maths channels for frequency and average amplitude. You can then save this to a csv or text file for each buffer but it will have a value for each sample in the waveform, so you will have to extract data out.

2. Use Measurements

The Measurements feature can be used to add measurements such as Frequency and AC RMS (or DC average) for each waveform in the buffer.

You would then manually enter the values into a file or if you use the PicoScope Automation command via a Windows command line interface, you can write the values shown in the measurement table to a text or csv file. Unfortunately, you would have to do this for each waveform in the buffer, then extract out the required values.

Below are example commands for text and csv file output:

Code: Select all

picoscope.com /a Measurements.CSV? >> test.txt

picoscope.com /a Measurements.CSV? >> test.csv
I hope this helps.

AndrewA
PICO STAFF
PICO STAFF
Posts: 400
Joined: Tue Oct 21, 2014 3:07 pm

Exporting PicoScope 6 Measurements

Post by AndrewA »

I created a batch file which uses a pico macro to save every measurement from each buffer in a psdata file.
But you have tell the batch file how many buffers there are in the psdata file.

To use-
1. Open the your saved psdata file, note the number of buffer waveforms. And set up the measurements you need.
2. Open a cmd box where the batch and macro files are.
3. Type 'measure.bat 32' (for 32 buffer waveforms)

The macro writes 3 lines for each buffer measurement- (And starts at buffer 32)

Code: Select all

32 
0ms: Measurements.CSV?
A,AC RMS,999.5 mV,999.5 mV,999.5 mV,999.5 mV,0 V,1,WholeTrace,
The batch and marco files are attached.
Attachments
measure.zip
batch and marco files
(558 Bytes) Downloaded 831 times
Regards Andrew
Technical Specialist

Hitesh

Re: Save average amplitude at each frequency

Post by Hitesh »

Hi,

Just an update with regards to the original request. Using the DeepMeasure feature introduced in PicoScope 6.13.1 Beta, you can capture a sweep in a single waveform trace and then export the table of measurements.

This will provide the frequency, max, min and peak-to-peak voltage for each cycle in the trace. You can export the data to csv file although it is not possible to select which columns to export.

Regards,

Post Reply