Analog Digital Analog converter with math channels

Post discussions on projects you are working on
Post Reply
lab!fyi
Newbie
Posts: 0
Joined: Mon Dec 12, 2016 6:58 pm

Analog Digital Analog converter with math channels

Post by lab!fyi »

Since many of the MSO digital channels are often unused it is possible to construct math channel based ADAC and gain additional analog channel(s). Results will depend on external hardware. Simple and precise power supply measurements could be done even with Arduino Uno.

Using 2205 MSO I have done following so far:

12bit ADAC using Arduino Due as 7MSa/s pattern generator producing 12x12bit sine wave.
Math formula: LowPass((2048*D11+1024*D10+512*D9+256*D8+128*D7+64*D6+32*D5+16*D4+8*D3+4*D2+2*D1+1*D0)/4096, 100000)-0.5
PicoScope_2205_MSO__LP_ADAC12.png
8bit ADAC using Arduino Uno R3 as voltmeter listening to PSU voltage with analog pin & resistive voltage divider:
Math formula: LowPass((128*D7+64*D6+32*D5+16*D4+8*D3+4*D2+2*D1+1*D0)/256, 100000)*14.7
Last number is tweaked according to voltage divider (Do not exceed Arduino 5V input!)
PicoScope_2205_MSO__LP_ADAC8.png
Picture of test setup connected to Arduino Uno and Agilent UT1272A as control provided.
PicoScope_2205_MSO__ADAC.jpg
Useful feature is that there is no noise which is often present on just analog channel. Can rig it up to form even 2 additional 8bit analog channels. I have no pattern generator or ADC fast enough to see what is practical bandwidth with all analog and digital channels in use.

Currently I use 100kHz LowPass to remove random peak glitches. When pushing for speed records this should be removed or reset to higher frequency.

If there is time skew due to Arduino processing time you can create time-skewed copies of real analog channels using formula X[T], for example A[-0.000001] should delay analog by 1 microsecond. Least possible step is 1ns AFAIK.

Arduino sketches attached for both scenarios:
PicoScope_Arduino_ADAC.zip
(1.16 KiB) Downloaded 558 times

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

Re: Analog Digital Analog converter with math channels

Post by Martyn »

Looks interesting :)
Martyn
Technical Support Manager

lab!fyi
Newbie
Posts: 0
Joined: Mon Dec 12, 2016 6:58 pm

Re: Analog Digital Analog converter with math channels

Post by lab!fyi »

New improved ADAC and test pattern generators for Arduino Uno & Due:
Arduino_Uno__ADC__59kSa.zip
(1.02 KiB) Downloaded 528 times
LowPass((128*D7+64*D6+32*D5+16*D4+8*D3+4*D2+2*D1+1*D0)/256/0.996,15000)*4.8
Arduino_Uno__ADC__8x8bit_2398Hz_sine_pattern.zip
(1.02 KiB) Downloaded 520 times
LowPass((128*D7+64*D6+32*D5+16*D4+8*D3+4*D2+2*D1+1*D0)/256/0.996,15000)-0.5
Arduino_Due__ADC__687kSa.zip
(986 Bytes) Downloaded 508 times
LowPass((2048*D11+1024*D10+512*D9+256*D8+128*D7+64*D6+32*D5+16*D4+8*D3+4*D2+2*D1+1*D0)/4096/0.9998,175000)*3.33
Arduino_Due__ADC__12x12bit_1465Hz_sine_pattern.zip
(1.19 KiB) Downloaded 528 times
LowPass((2048*D11+1024*D10+512*D9+256*D8+128*D7+64*D6+32*D5+16*D4+8*D3+4*D2+2*D1+1*D0)/4096/0.9998,175000)-0.5

Note that formulas are not optimized (...4096/0.9998... etc), this to give clear picture what does what.
Last edited by lab!fyi on Thu Jan 12, 2017 1:21 pm, edited 1 time in total.

lab!fyi
Newbie
Posts: 0
Joined: Mon Dec 12, 2016 6:58 pm

Re: Analog Digital Analog converter with math channels

Post by lab!fyi »

Some screenshots also:

Arduino Uno ADAC listening to signal gen @ 59kSa/s
PicoScope__Arduino_Uno__ADAC__59kSa.png
Arduino Uno 2398Hz 8x8bit sine pattern
PicoScope__Arduino_Uno__ADAC__8x8bit_2398Hz_sine_pattern.png
Arduino Due ADAC listening to signal gen @ 687kSa/s, non-time-skewed CH2 for comparison
PicoScope__Arduino_Due__ADAC__687kSa.png
Arduino Due 1456Hz 12x12bit sine pattern
PicoScope__Arduino_Due__ADAC__12x12bit_1465Hz_sine_pattern.png

Post Reply