Maker Pro
Maker Pro

How to display high frequency (MHz) sinewave on PC?

saurabh17g

Mar 8, 2010
72
Joined
Mar 8, 2010
Messages
72
I have a 12MHz wave received from a circuit. I want to display it on PC.
Pls giv me some ideas about it.

Problem: This 12Mhz signal has to pass through a micro-controller and micro-controller will tell PC using RS232 about the waveform.
But microcontroller works on 1Mhz and due to interfacing and other stuff, the signal through ADC comming to microcontroller can' t exceed 10 to 100kHz.
So is there any other way to do this?
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Jan 21, 2010
25,510
Joined
Jan 21, 2010
Messages
25,510
No can do.

The 12MHz signal would have to be sampled at least 24 million times per second (preferably much faster). RS232 goes nowhere near this speed. The best you could get is around 10,000 samples per second (assuming 8 bit resolution).

The only way to do it would be to use some external hardware to sample and store the signal, then use the processor to read it out and send it (slowly) to the PC. And doing it that way, the external hardware would be the hard bit.
 

saurabh17g

Mar 8, 2010
72
Joined
Mar 8, 2010
Messages
72
what should this external hardware contain?
if i assume high sampling done using ADC, how would i store the signal? would i require microcontroller to do this? or is there any other way?
for storing the samples from ADC, assuming sampling rate 24MHz, and the input signal to be 1Hz(worst case) then there will be 24mega samples. so storing those samples will require 24x10^6x(8x2) memory=48Mbytes.
is there any other way?
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Jan 21, 2010
25,510
Joined
Jan 21, 2010
Messages
25,510
Using an oscilloscope would be the best way to view the signal.

Even sampling at twice the max frequency won't allow you to see the shape of the signal when the frequency gets anywhere near the maximum. All it does is ensure that you don't see something that isn't there (google Nyquist frequency). You would require a substantially higher sampling frequency (10x perhaps?) to get an idea of the shape.

120 megasamples per second is getting really fast. As you might imagine, getting an ADC to do this won't be simple or cheap. You would need a processor running at some multiple of this rate per second to transfer the data (unless you could use DMA).

And as I said before RS232 craps out at about 100,000 bits per second (and assume 10 bits per byte due to start and stop overhead).

Perhaps you should try to explain *why* you want to do this?
 

saurabh17g

Mar 8, 2010
72
Joined
Mar 8, 2010
Messages
72
@steve:
Reason to do this:

there are certain materials or samples whose properties are to be measured. One of this property is phase difference between the input and the output waveform passed through it.
the frequency requirement is around 10Mhz,
waveform should be displayed in order to document it.


one more thing:
I am planning to use PC audio card (stereo input) and display waveform using Matlab software. any suggestions for this?
Now, there is a problem.
Amplification of the received wave:
High freq opamp is necessary. this is bcos IC741, 0p07 will work for signals upto 1mhz. please suggest me some better opamp ic.
second:
I have only one audio port in my PC. so when 2nd waveform comes, it will get combined with the first bcos of single wire. so how to solve this problem?
 
Top