How to set resolution enhancement by using Python --Picoscope 4425A

Post general discussions on using our drivers to write your own software here
Post Reply
bzy
Newbie
Posts: 0
Joined: Wed Feb 22, 2023 6:44 am

How to set resolution enhancement by using Python --Picoscope 4425A

Post by bzy »

@Neil
I am tring to set resolution enhancement of channel B as 16bits by using Python,
Could please give me an example code to set it?
I tried to use ps4000aOpenUnitWithResolution, but I can not figure out how to define PS4000A_DEVICE_RESOLUTION.

bennog
Advanced User
Advanced User
Posts: 208
Joined: Mon Nov 26, 2012 9:16 am
Location: Netherlands

Re: How to set resolution enhancement by using Python --Picoscope 4425A

Post by bennog »

In the PS software this is done in the software so you have to program this yourselves.
You can do this with a moving average function.

Benno

Martyn
Site Admin
Site Admin
Posts: 4500
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots

Re: How to set resolution enhancement by using Python --Picoscope 4425A

Post by Martyn »

Some of our scopes have flexible resolution settable on the device, and this is available on the PicoScope 4444 hence why it is available in the API for the ps5000a.dll. The PicoScope 4425a is fixed at 12 bit and can't use this function, so to get an extra 4 bits you will need to do this in software as the PicoScope application does. Please see the following article discussing Resolution Enhancement.

Please see https://www.picotech.com/library/oscill ... nhancement

To get 16 bits for your PicoScope 4225a you will need to average the first 256 samples you collect and then place the value in position one, now move onto the second sample and average 256 samples from this point and place the value in position two. Repeat this process through your complete buffer and you will have the same results that you get with the PicoScope software.
Martyn
Technical Support Manager

bennog
Advanced User
Advanced User
Posts: 208
Joined: Mon Nov 26, 2012 9:16 am
Location: Netherlands

Re: How to set resolution enhancement by using Python --Picoscope 4425A

Post by bennog »

The option Martyn described will give some delay to your signal compared with the not enhanced channel data.
Beter option is to take the average of your sample and 127 samples before your sample and 127 samples after your sample.
This will give the same effect without the delay in the enhanced and not enhanced signal.

Benno

Post Reply