1
\$\begingroup\$

Looking to convert a voltage output from a circuit in order to show a voltage/time graph. From my knowledge I would have thought the best way to transmit the data would be to use the mic input on the computer because it would just be a series of pulses (specific circuit) or something using a USB interface. Can anyone guide me or have any better ideas?

\$\endgroup\$
  • 1
    \$\begingroup\$ A DMM with a computer interface. \$\endgroup\$ – Ignacio Vazquez-Abrams Mar 3 '15 at 18:10
  • \$\begingroup\$ I thought for a moment you were asking how to look at a voltage waveform and transmute this information into the generating circuit (the 'convert' keyword). Alas, the question is not quite so outrageous. Most scopes can do this for you out of the box (sample and store waveform data). \$\endgroup\$ – sherrellbc Mar 3 '15 at 18:14
  • \$\begingroup\$ Try googling "strip-chart recorder software" \$\endgroup\$ – Tut Mar 3 '15 at 18:27
3
\$\begingroup\$

The line-in and microphone inputs certainly can be used as a recording interface to the computer. The only difference physically between the line-in and mic inputs is their sensitivity; line-in can take about +/- 0.5-1.5v, where mic input can be much less than that, down to +/- a few millivolts depending on how much "boost" is added by the computer. The mic input is also much noisier when the boost is increased, leading to "jitter" in the sampled data.

If you're handy with application coding, consider that a recorded .WAV audio file is nothing more than a raw, 16-bit precision, 2-channel data, sampled 44,100 times per second. 16-bit meaning each one of the samples have a range of 2^16 bits or 65535. The tricky part is that the data is signed, meaning it ranges from -32768 through 0, to +32767. A good example of the actual contents of a .WAV file can be found here. So some fairly straightforward conversion and scalar math is needed to linearize the data if desired. Then it's just a matter of getting that data into visual form. One way would be to convert/export it as a .csv (comma-separated values) file. Most spreadsheet applications can read these, and fairly easily chart the data beautifully. Of course, for the more astute programmer, it's possible to code an entire application and draw directly to the application window.

But there are a few more things to consider about the hardware. Use a large-ish inline cap to block DC, and a recorded value of zero will always be no signal... but then it will have poor DC measurement characteristics. A more practical approach would be to build an op-amp front-end, where you can apply or remove a DC offset from the input signal, as well as scale it to fit in the window of what the soundcard can accept. Then add a switch across the cap, to DC-couple the source, and presto, you almost have a very basic oscilloscope.

This is pretty close to the idea of a "soundcard oscilloscope", and there are a lot of articles of others doing such a thing, such as this.

It may be a great hobby project, but of course it will not compare to the precision, performance, and reliability of any real oscilloscope. Some will tout fantastic characteristics, but trust me, they always fall short of the real thing. If you have more than a passing interest in electronics, you'll want to get a real oscilloscope. eBay can be a great place to find a bargain, but do ask someone knowledgeable before you buy anything. Dave over at EEVblog has lots of oscilloscope reviews, and can (quickly?) get you up-to-speed in all the features and terminology.

\$\endgroup\$
0
\$\begingroup\$

Most of the modern Digital Storage Oscilloscopes (DSO) can record and store a voltage waveform as files into memory devices with USB interface.

If you don't have access to a DSO, then an ADC + microcontroller can help you to store/transmit the data.

A circuit simulator can give you the graph if your circuit and inputs can be simulated.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.