Atmega 8 or 328 can handle AD9280?

Go To Last Post
56 posts / 0 new

Pages

Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'm trying to make a simple oscilloscope. For Hobby.

 

I intend to buy AD9280 32MS/s 8 bits.

 

Could I use it with ATmega at 30MS/s?

 

I have to read the data that come to 30MS/ss and put them in ATmega's memory.

 

I think that in order to read the value of a port and put it in memory we need to have 2 instructions.

If each instruction takes one clock, then clock at 60MHz could solve the problem.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

No Way at 30MSamples/second. Perhaps with XMega but even that would be challenged.

 

You might make 1MSample/Sec work with a 16MHz clock because it will take you significantly more than two instructions per sample, It will have to loop and that loop probably needs a test to tell when to stop sampling.

 

And, what memory are are these samples going to? For many families of regular MegaAVRs, 2K is the maximum memory available (true for M328). Your program will need some for its own execution, so you might have 1600 available.

 

There are quite a few "microprocessor oscilloscope" videos and tutorials out on the internet. I strongly suggest that you use some of those resources before you get much farther in your project. They will help you build something that works.

 

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

Last Edited: Sat. Feb 17, 2018 - 07:13 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:
I think that in order to read the value of a port and put it in memory we need to have 2 instructions.

Don't you also need to provide the clock to the AD9280 ?

 

But that simply reads the byte and puts it in memory - a useful oscilloscope will also need to read it out, and display it...

 

Miau wrote:
If each instruction takes one clock, then clock at 60MHz could solve the problem

So what does the datasheet say about the maximum clock frequency, then?

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ka7ehk wrote:
Perhaps with XMega but even that would be challenged.
XMEGA A1U has 2 ADC at 2Msps each for 4Msps total (interleave, DMA)

PIC32MZ EF is 3.84Msps max for 8b (200R max source) with 6 sample&hold for 23Msps total (interleave, DMA)

 

XMEGA A1U SRAM EBI is 8b async at 32MB/s (read, no ALE, DMA); if the ADC is 8b sync then a cPLD to mate the sync ADC to async XMEGA (instead, RE* ?)

PIC32MZ EF has 50MHz 16b async SRAM EBI; IIRC, some PIC32 also have a sync interface (context is TFT LCD, a pixel clock from PIC32)

Some PIC24 have 8b async SRAM EBI but I don't recall the frequency; some PIC24 also have a sync interface.

 

http://www.microchip.com/wwwproducts/en/atxmega128a1u

http://www.microchip.com/design-centers/32-bit/architecture/pic32mz-family

http://www.microchip.com/design-centers/16-bit/products/pic24h-e

 

Edits: instead, A1U

 

"Dare to be naïve." - Buckminster Fuller

Last Edited: Sun. Feb 18, 2018 - 12:36 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

The short answer to the subject question:  Yes, a Mega8 or Mega328 will work with AD9280.

 

The answer to the text question: check the spec sheet for the maximum clock rate, the internal ram size, and the number of clock cycles per instruction (of the instructions needed to read a port and write to SRAM). Then, consider just how you are going to implement the sampling loop, how you are going to start it and how you are going to stop it. Hint: looping, starting, and stopping add to the clock cycles per loop.

 

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 2

This is really a project for the FPGA...much faster and better suited for high speed shuffling of data (maybe using an AVR to give it directions).....or perhaps an ARM chip running at 400MHz.  If you are willing to sample slower, then an AVR might be for you .

As Jim mentioned, there are many web tutorials you should investigate before making your move.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

avrcandies wrote:
If you are willing to sample slower, then an AVR might be for you .
As AVR has single cycle 8 bit ports, AVR32 UC3 has single cycle 32 bit ports (local bus)

The most recent AVR32 UC3 are UC3L (50MHz max) and UC3C (66MHz max)

UC3C0 has an EBI and all have DMA; can local bus to an on-chip SRAM then DMA to EBI (SRAM, SDRAM, etc)

An advantage of a FPGA is reduced dwell.

 

http://www.microchip.com/ParamChartSearch/chart.aspx?branchID=2151 (AVR32)

 

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

gchapman wrote:

PIC32MZ EF is 3.84Msps max for 8b (200R max source) with 6 sample&hold for 23Msps total (interleave, DMA)

I do not believe. 1-2MS/s max. I think they They multiplied the conversion rate with the number of A / D converters to that number.

 

avrcandies wrote:

This is really a project for the FPGA...much faster

Sure with FPGA is a digital "serious" digital oscilloscope,

But the cheapest FPGA is at least 5 times more expensive than an Atmega.

Then I do not have a FPGA programmer.

 

 

Last Edited: Sun. Feb 18, 2018 - 06:15 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I do not believe. 1-2MS/s max. I think they They multiplied the conversion rate with the number of A / D converters to that number.

What a strange reaction.

 

Have you looked at the datasheet for the PIC32MZ EF?

"Experience is what enables you to recognise a mistake the second time you make it."

"Good judgement comes from experience.  Experience comes from bad judgement."

"Wisdom is always wont to arrive late, and to be a little approximate on first possession."

"When you hear hoofbeats, think horses, not unicorns."

"Fast.  Cheap.  Good.  Pick two."

"We see a lot of arses on handlebars around here." - [J Ekdahl]

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ka7ehk wrote:

Then, consider just how you are going to implement the sampling loop, how you are going to start it and how you are going to stop it. Hint: looping, starting, and stopping add to the clock cycles per loop

 

"Loop" It will not exist.

For example, if I want 500 points acquisition, there will be 500 pairs of two instructions one after the other.

 

The system will wait for the External Trigger in a loop.

Then it will read the 500 consecutive value of voltages.

 

It will transmit this data to PC via USB,

Then it will reset ant wait for Trigger signal (Loop)

 

A "serious" oscilloscope has several modes. Example Auto Mode..

It repeats the reading when the signal has the same value and the same growth trend (the same derivatives) - it will not have that.

 

It will not have any operational amplifier on the input.

 

 

 

 

Last Edited: Mon. Feb 19, 2018 - 05:53 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

joeymorin wrote:

Have you looked at the datasheet for the PIC32MZ EF?

PIC32MZ EF  was my first choice for this project. It is the fastest controller from Microchip.

I would be glad to get it wrong and to have it such a good conversion.

Last Edited: Sun. Feb 18, 2018 - 06:47 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ka7ehk wrote:

There are quite a few "microprocessor oscilloscope" videos and tutorials out on the internet. I strongly suggest that you use some of those resources before you get much farther in your project. They will help you build something that works.

 

I've been looking for such projects.

All had an A / D conversion up to 1-2MS / s.

If you know an oscilloscope diagram with an A / D conversion speed at least as suggested by me 30MS/s please tell me.

Last Edited: Sun. Feb 18, 2018 - 06:46 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It will not have any operational amplifier on the input.

 

You might want to re-think this.

 

An op-amp circuit will likely have a high input impedance, which is good, so it does not load down the circuit being looked at.

 

The op-amp can include a Low Pass Filter, which is necessary to prevent "aliasing" of higher frequency signals into the signal being seen on the O'scope.

 

The op-amp can include both amplitude "clamps", and protection from negative voltages, both of which might damage the (more expensive) ADC chip, or the micro.

 

JC 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

As DocJC mentioned, you should consider it essential to have a good analog front-end & protection....otherwise, why bother to do a bunch of work, only to have a ho-hum project?  I've used the PIC32MZEFH...very fast, but somewhat complicated ADC setup...many compplaints, though I think they finally got it ironed out.  This complex ADC automatically do series of conversions and many other things...worth looking into.  

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:
But the cheapest FGPA is at least 5 times more expensive than an Atmega.

But, as has been pointed out,  the ATMega has nowhere near the performance you're talking about!

 

Fast or Cheap - pick one !

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

But the cheapest FGPA is at least 5 times more expensive than an Atmega. 

Many hamburgers are more expensive than an Atmega, but I still eat burgers.   When you are finished, you probably won't remember the cost of the chips; for this project is more a matter of time & effort.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:

 

PIC32MZ EF  was my first choice

 

 

 

If I look at this link, I can see that I can select ADC ksps: 18 000.  Does that mean I can sample a signal at 18Msps?:

https://www.microchip.com/maps/m...

 

 

Edit: Interesting! They also introduced Atmel in this list!

 

avrcandies wrote:

  I've used the PIC32MZEFH..

I have found no PIC32MZEFH THT. Which PCB Adapter did you use? Or did you use a development kit?

 

 

Last Edited: Mon. Feb 19, 2018 - 06:38 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Miao

I have ben there too. Had an old analog dual channel oscilloscope, 20MHz bandwidth. Homebuilt DSO was meant as an upgrade to that. So, I decided the following:

 

Bandwidth minimum 50MHz
Dual channel
Corresponding sample rate, wanted 500M samples/s
Complex triggering (like single events or deviation from a curve form)
8 bit flash ADC for speed in conversions

 

And since I sometimes takes measurements on mains voltages: fully isolated inputs, isolated from both scope and each other. And fully protected up to minimum 600V. Double isolated probes for my own security.

 

To get sufficient sample rate, I would build the sampling and writing to RAM with logic gates and a programmable clock generator. Samples would be stored in dual ported RAM, samples written to one of the RAM ports, processor reads from the other port. In that way I could lessen demands on processor speed. FPGA might be a better choice, but I don't have the tool chain for it.

 

My project ended without any implementation, somebody offered me at second hand instrument with all of the above for a reasonable price: a Fluke Scopemeter 192B. Never looked back from that. Its my workhorse now.

I think your project is doable, but will take a lot of hours, and result could be disappointing in the end. But if you just want to experiment and learn, it might be a fine project for that.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

PIC32MZ2048EFH144...this is only one flavor, try different numbers for the PC32MZ...EFH....

 

 

do NOT use the MX...it has about 30 pages of errata & the ADC never worked properly---it was a nightmare for everyone, until the MZ came out

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

Last Edited: Mon. Feb 19, 2018 - 09:05 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

peteralarsen wrote:
fully isolated inputs, isolated from both scope and each other.

Then work on the battery and transmit it to PC or Android Phone with ESP9266.

 

peteralarsen wrote:

Bandwidth minimum 50MHz

Dual channel
Corresponding sample rate, wanted 500M samples/s

 

I read and I think we can achieve bandwidth 50MHz with 32MS/s A/D convertor.

For this we do the normal data acquisition at 32MS / s (real time).

And the software will be able to to convert it in non real time 50MHz bandwidth. Am I wrong?

 

e.g.

http://pic-microcontroller.com/d...

 

They write in this link:

"Analog bandwidth (Small Signal), 12/6/7 MHz ,For Gain 1/2/5" for a controller that have  2x1MS/s A/D

 

But if we use 32MS / s A/D?

will bandwidth increase 30 times???

 

 

Last Edited: Mon. Feb 19, 2018 - 09:55 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:
And the software will be able to to convert it in non real time 50MHz bandwidth. Am I wrong?
Sorry but what processor do you mean? Are you still talking about AVR (the subject of this message board) or something else?

 

Clearly a tiny/mega AVR is not up to the job of storing/processing 50MHz data so I guess this thread is now off topic for the "Tiny/Mega" forum but I need to understand where to move it to.

 

Moderator

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:
Then work on the battery and transmit it to PC or Android Phone with ESP9266.

 

I think its a bit more complicated. The 2 channels needs to share timing, and needs both isolation and protection. I mean protection of myself, not just the scope. For my purpose, yours could differ.

 

Miau wrote:
I read and I think we can achieve bandwidth 50MHz with 32MS/s A/D convertor. For this we do the normal data acquisition at 32MS / s (real time). And the software will be able to to convert it in non real time 50MHz bandwidth. Am I wrong?

 

You are thinking a sampling scope. Yes, a sampling scope can sample signals with a frequency much higher than the sampling rate of the scope. But only for repetitive signals. Complex triggering is not possible. For normal DSO operation you will need a sampling rate considerable faster than the frequency of the signal.

 

Miau wrote:
But if we use 32MS / s A/D? will bandwidth increase 30 times???

 

Bandwidth and sampling rate are two very different things. Bandwidth refers to the analog circuit of the input. Sample rate is how often you convert analog to digital.

 

As a rule of thump, I would like sample rate to be approximately 10 times the bandwidth.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

clawson wrote:
Clearly (sic?) a tiny/mega AVR is not up to the job

It's crystal clear to everyone else, but I'm not sure that the OP has actually grasped this yet ... ?

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

peteralarsen wrote:
a rule of thump

laugh

 

Note that it's a rule of thumb !

 

yes

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Note, repetitive pass sampling to increase bandwidth requires (I believe) that the when/timing of each sample to be precisely controlled.

 

So if you sample at 10MHz, and want to interweave 4 sweeps (to increase bw), each sample must be positioned accurately within 1/40MHz in time.

Thus the timing jitter of the samples must be more and more tightly controlled.

Say you are sampling at 10MHz (100 ns)...you may have +/15ns uncertainly when each sample happens...its hard to position in 4x more samples repetitively in between when each sample is +/-15ns

In other words, if you don't know exactly when the samples happen, you can't increase the bandwidth much.

 

You might need to research this, to see if this thought is true.

 

https://www.tek.com/document/application-note/real-time-versus-equivalent-time-sampling

 

 

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

peteralarsen wrote:

As a rule of thump, I would like sample rate to be approximately 10 times the bandwidth.

 

This commercial oscilloscope has:

https://www.circuitspecialists.c...

 

"

  • Shot bandwidth: DC to 40MHz
  • Max. Sample rate: 100MS/s

"

 

is only 2.5 multiplied.

 

Or, DSO3204 USB from Voltcraft 200MHz bandwidth and 250MS/s A/D conversion "speed".

 

 

Is with 0.25 times larger.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Get some "simple" logic to do the sampling to an external RAM, (where addr. is controlled by a counter), and then have the AVR to empty it.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

Silly question to OP but you don know you are not the first to do this? There's a whole load of "entry level" scopes on ebay, some built from "open" designs. On the whole the majority seem to be based around some kind of ARM though I believe some use MSP430 (it's good at analog). If it were me I'd be looking at other people's designs and try to understand what it was motivated them to use the chips they have. You will find some designs are FPGA based. For my money I would have thought FPGA might be the obvious choice for doing something like this.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:
Or, DSO3204 USB from Voltcraft 200MHz bandwidth and 250MS/s A/D conversion "speed".     Is with 0.25 times larger.

 

I my opinion, the effective bandwidth (what the scope can reliably show) is around 25MHz. A -3db analog bandwidth of 200MHz does not hurt, but does not correspond well with the sampling rate.

 

Try to grab pen and paper. Plot a 200MHz square wave, 5 nanoseconds period, 2.5 ns halfwave. Then plot the samples, 250MS/s on the square wave, 4ns apart.

 

Now look at your plot. Most full waves are sampled only once, and 40% of halfwaves are not sampled at all. The scope is useless at this frequency.

 

Lower the square wave frequency to 25MHz. You get 10 samples pr. period, and 5 pr. halfwave. Now it looks more like a square. But you can still not read rise and fall times of the signal.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 2

Miau wrote:

  • Shot bandwidth: DC to 40MHz
  • Max. Sample rate: 100MS/s

 

is only 2.5 multiplied.

 

You need to understand what those numbers mean.

 

Firstly, information theory says that you only need to sample at twice your highest frequency to be able to reconstruct a perfect sinewave. However, to do this requires perfect filtering which doesn't exist. So we need more than 2 times but how much?

 

That bandwidth figure above is the -3dB figure. So if you feed that scope with a 1V 40MHz sinewave it will read as about 700mV. So you cannot make accurate voltage measurements.

 

But when working with micros we often are dealing with square waves. So let's look at a 10MHz square wave. This is made up of sinewaves at 10MHz, 30MHz, 50MHz, 70MHz, etc etc. So our 40MHz bandwidth scope will display the 10MHz component OK, the 30MHz component will be included but will be in error and the 50MHz and 70MHz components will not be present.

 

So our 10MHz square wave...

...will display like this...

 

 

For simple yes/no testing to find a missing signal that might be enough, but for finding timing problems it will not be helpful.

 

This is what it would look like if we could see up to 7 times the basic frequency...

 

 

...which is better but still not very good. If we can go up to displaying (red line) 15 times our base frequency...

 

 

Which is probably good enough for most work.

 

So we need to display up to 15 times our base frequency which means we need to sample at 30 times our base frequency.

 

There are quite a few simplification in the above but I hope it explains the need to high sample rates.

 

#1 This forum helps those that help themselves

#2 All grounds are not created equal

#3 How have you proved that your chip is running at xxMHz?

#4 "If you think you need floating point to solve the problem then you don't understand the problem. If you really do need floating point then you have a problem you do not understand." - Heater's ex-boss

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Like so many things, the principle of an oscilloscope can be very simply - even trivially - stated:

 

Just read samples from the input, and display them on the screen.

 

It should be obvious that the practical implementation of a usable instrument is vastly more involved that this - but that seems to have escaped the OP...

 

#TrivialImplementation

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Brian Fairchild wrote:

You need to understand what those numbers mean.

 

Starting from a given signal we do FFT and we get a "spectrum".

 

Conversely, we can not start from a spectrum and get the signal. Because the phase information was lost.

It would be nice if we could start from the spectrum from spectral analyzer and get the signal that corresponds to it.

 

But it would not make sense the phase difference between two different frequencies.

 

I'm still thinking about using it in a spectrum analyzer as an information to create the oscillogram.

 

Anyway, I talked about cheaply IC. It's worth a test.

Last Edited: Mon. Feb 19, 2018 - 12:58 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:

Because the phase information was lost.

 

Not quite true. The usual output of an FFT/spectrum analyser is the power spectrum however that does not mean that the phase information is not available.

#1 This forum helps those that help themselves

#2 All grounds are not created equal

#3 How have you proved that your chip is running at xxMHz?

#4 "If you think you need floating point to solve the problem then you don't understand the problem. If you really do need floating point then you have a problem you do not understand." - Heater's ex-boss

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You need to understand what those numbers mean.

 

Firstly, information theory says that you only need to sample at twice your highest frequency...

Actually, what is somewhat buried under the rug is that sampling occur faster than twice the bandwidth (bandwidth is typically espoused as simply the highest freq component of interest).  Why is that slight difference important? Say we only worked signals in the freq range from  1.1897 to 1.2000 GHz...so one might say highest freq is 1.2GHz, need to sample at least 2.4GHz.  But the BW is only 10300 Hz, so actually we only need to sample at 20.6 KHz. That's a huge difference!  It can be tricky to do, but sometimes worth it  (say you need to go from 19.999 to 20.000 GHz, a 2MHZ ADC (min) will do). Of course, as mentioned, 2x cuts it ideally close, 10x is a big relief.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Interestingly enough, this just landed in my inbox:

 

https://www.electropages.com/2018/02/tough-price-test-for-high-end-makers/

 

 

It's talking about this:

 

https://www.redpitaya.com/

 

Oscilloscope application will turn your STEMlab board into a 2-channel Oscilloscope and 2-channel Signal generator. It is the perfect tool for educators, students, makers, hobbyists and professionals seeking affordable, highly functional test and measurement equipment. It enables generating and measuring electrical signals up to 50MHz.

 

https://www.redpitaya.com/f131/oscilloscope-signal-generator

 

 

Note:

based on a dual core ARM Cortex A9 + Xilinx Zynq 7010 FPGA SoC

Certainly not a little 8-bit AVR!!

 

surprise

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Years ago, Tek made a random sampling oscilloscope. It was a marvel of (just) pre-IC engineering. Tunnel diodes, discrete ramp generators, real transmission lines, and such. It was incredible for repetitive waveforms (turned a 35MHz scope into 600MHz, as I recall). But, while each sample may have been random in time, each random time interval was measurable and known at the time of the sample; the randomness was all relative to the trigger point (which relied on a tunnel diode as the "trigger comparator"). It also relied on a complete waveform being generated within the persistence of the CRT phosphor (of course, it used a real CRT). 

 

Jim

 

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

But, while each sample may have been random in time, each random time interval was measurable and known at the time of the sample;

Exactly--it is hard to put Humpty-dumpty (waveform) together if you don't know exactly where all the samples were taken.   You could say take sample x exactly at this time, or take the sample around some desired time & actually measure the exact time it was taken.  In either case, the exact timing (specified or measured) comes into play.

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Those are all just ADC chips.

 

There is no disputing that fast ADC chips are available.

 

But a simple little 8-bit microcontroller is simply not going to be able to process that volume of data at that speed.

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

"The system will wait for the External Trigger in a loop.

Then it will read the 500 consecutive value of voltages."

 

Well, one of the advantages of storage oscilloscope is that you can show signals ** before ** trigger...

 

This can be done on an arduino (forgot the link) with a ca 10ksamples/second rate, an a Ti launchpad (almost the same code, thanx energia) with 1Msamples/second -and has two independent ADcs : one can convert while the other is transferred to RAM-.

 

Even if you use external concerters : avr(16 Mhz)  SPI cannot go above 8Mhz (IIRC **did not check with data sheet)  : 1Mbits/second (if it is 8 bits, you achieve 1Msamples /second ). Even if external DAC is fast, the bottleneck is the AVR...

 

One should be aware one should sample at least 10 samples/period to have nice curves (far slower than Nyquist s) ... at least my eyes found lower sampling rates ugly.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hantek 6022BE USB ....48MSa / s ..........50Eur

https://www.amazon.de/Hantek-Dig...

 

 

 

awneil wrote:

 

https://www.redpitaya.com/

 

 

 measuring electrical signals up to 50MHz.

 

https://www.redpitaya.com/f131/oscilloscope-signal-generator

 

Red Pitaya.........,,,,,,,,,,,,,,,,,240 EUR !!!............."measuring electrical signals up to 50MHz."
I've been watching Red Pitaya since the project on Kikstarter.
They got the money on Kikstarter.
And that can be an interest

 

Last Edited: Tue. Feb 20, 2018 - 12:29 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

What is your point?

 

Surely, the question of your topic - "Atmega 8 or 328 can handle AD9280?" and "Could I use it with ATmega at 30MS/s?" - has be thoroughly answered several times now?

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

awneil wrote:

What is your point?

1. Is this oscilloscope worth made at amateur level or or bought?

 

2. If it is worth doing at diy level with which of the A / D converters mentioned above?

 

If I still try to make such an oscilloscope, there is a good idea to do something useful. 

This compares with commercial oscilloscopes, because if it comes out more expensive (At the same characteristics) it is useless.

Last Edited: Tue. Feb 20, 2018 - 12:39 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Miau wrote:
1. Is this oscilloscope worth made at amateur level or or bought?

You will certainly not make a better oscilloscope yourself, and you are unlikely to make it cheaper.

 

See #31.

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Do you know how to make all the electronic (high speed op amps, gain settings, electronic for the trigger, protections  etc.) ? 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

"

If I still try to make such an oscilloscope, there is a good idea to do something useful. 

This compares with commercial oscilloscopes, because if it comes out more expensive (At the same characteristics) it is useless."

Well, I made two oscilloscopes, one with Arduino, the other with Ti launchpad. Both were more expensive than a commercial product, had lower (a 1/100 ratio, to remain kind) sampling rates... but tought me things.

 

And commercial already made products are often, to days, less expensive than the sum of the price of their parts (I neglect PCBs, shipping : would make things even worse)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

dbrion0606 wrote:
but taught me things.

Yes, it could be a learning experience - but it's not going to get you a cheaper or better-performance scope than you can buy.

 

But, as sparrow2 suggested in #45, it seems that the OP has a lot of basics to cover before even starting on a project like this ...

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
Last Edited: Tue. Feb 20, 2018 - 01:05 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It is a bad idea to build one's own checkers, as one needs ... to check them (with a better one? anyway, looks like a egg and hen issue for an individual).

 

Better would be, if one wants to build a scope, to start by ... building a signal generator (square wave forms, triangular ones....) with known features. (xmega and ARM (texas, STM) are interesting, as their DMA allows to send analog data without CPU being "slowed" ; xmega is the basis of a cheap, tiny mixed signal oscilloscope -ask google about "gabotronics oscilloscope", where the MCU parts and the PC parts are open source; though it is slow -40ks/s IIRC-, it is a software jewel-).

 

The only way I found to have prices below commercial oscilloscope was to use a RPi or PC screen , with a python (+ matplotlib + serialpy/pyserial + some controls to ( modify sampling rate/start sampling a burst of data/ do what I found interesting)  ...) script;

even in this case, arduino (i.e avr based : I just added a non blocking "adc read " function...) was more expensive than a direct PC oscilloscope (and slower)... (PC screens are much more pleasant than tiny screens).

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

dbrion0606 wrote:
It is a bad idea to build one's own checkers, as one needs ... to check them (with a better one

a very good point!

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

For a hobbyist, it is not a bad point.. (in this context,seems OP is a hobbyist)

For a manufacturer, this point (which negates the notion of progress with instrumental techniques) is absurd ( a manufacturer has theoretical skills to simulate, experience to avoid bad practices, and clients to pay for skills and protest).

Last Edited: Tue. Feb 20, 2018 - 02:43 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You say you like the RedPitaya???

 

TECHNOLOGY

The ultimate FPGA technology, Xilinx Zynq 7010, coupled with very accurate high-end ADCs represents the core of the STEMLab circuit....

Red Pitaya is based on a dual core ARM Cortex A9 + Xilinx Zynq 7010 FPGA system-on-chip (SoC), which features a dual core processor and FPGA logic, allowing for software and hardware programming

 

ummm.... didn't I suggests this was better-suited for an FPGA way back in #6???   Why do you wait---get the Pitaya and move ahead!!!

When in the dark remember-the future looks brighter than ever.   I look forward to being able to predict the future!

Pages