The story is simple. I decided my electronics learning journey had reached a point where an oscilloscope would be a useful tool to have.
However, I'm not sure how long this electronics hobby will last and so I didn't want to spend big dollars on what might become an expensive paper weight. In fact I'm such a cheapskate that I didn't even want to spend small dollars.
After some research and checking out my (sparse) parts bin and various piles of junk in the garage I figured I could build a microcontroller based scope that would be good enough for my very modest needs - without having to purchase any extra hardware.
MicrocontrollerThe first step was to choose which of my microcontroller development boards to use. I have a few Arduino boards (a Uno and Nano) and a Raspberry PI Pico. The 500kS/s sampling rate of the Pico vs the 77kS/s maximum sample rate of the Arduino’s meant this decision was a no-brainer as long as I could find some appropriate software.
SoftwareObviously I would need to run some software on the Pico to capture the samples, display the waveforms and handle things like triggering and scaling. Not having the inclination (or skills) to write the software myself I put my Google search skills to the test. After nearly giving up I finally came across a project called Scoppy. The software that runs on the Pico is open source but it doesn’t provide any UI. For that you need to install an Android app which unfortunately is not open source so not ideal. However in the absence of any better alternatives I decided to go with that.
EnclosureFor the enclosure I decided to use the case of a PVR that I rescued from a dumpster some time ago.
After ripping out the HDD and circuit board I found that a piece of 9cm x 15cm perf board fit perfectly on the existing standoffs built into the bottom of the case.
Of course there was never any possibility of using real oscilloscope probes as they would definitely blow my $0 budget and after all the scope will only be measuring low frequency signals. DMM type probes would do but alas I didn’t have any 4mm sockets in the parts bin.
The zero-cost solution I came up with was to use the RCA connectors on the back of the PVR enclosure.
It seems like every piece of A/V equipment I have ever bought came with RCA cables, most of which have never been used but of course I’ve kept them ‘just in case’.
The RCA cables were easily converted into usable probes by cutting off a suitable length of cable and attaching a jumper wire. As a bonus the inner conductor is shielded, though I’m not sure if this makes any difference at the low frequencies that the scope can measure.
SchematicThe analog front end of the scope mainly follows the design here, giving the scope four voltage ranges. Most of the components used are very generic (jellybean?) and I was able find all but the BAT46 diode from my parts bin (I just used a 1N4148 instead of the BAT46 - seems to work fine).
Each scope input is connected to a resistor divider that attenuates the signal by a factor of two. A pair of 1N4818 diodes are used to protect the the op-amp non-inverting inputs from negative voltages. Voltage protection is not provided on the positive side because the LM324 is rated to 32V which is way above anything I anticipate measuring.
The four voltage ranges are implemented by varying the value of the op-amp's feedback resistor. Given the limited range of resistors on hand the voltage ranges for the scope ended up being:
- 0.30 to 6.30V
- 0.30 to 3.63V
- 0.30 to 1.05V
- 0.30 to 0.30V
Why -0.30V and not zero? If the low end of the voltage ranges were zero then the op-amp would need to output 0V for the scope to correctly show an input voltage of 0V - but the negative supply to the op-amp is also 0V and so it would never be able to swing the output voltage that low.
The op-amp outputs are connected to the ADCs on the Pico via current limiting resistors. Schottky diodes prevent the voltage on the ADC pins from rising above the absolute maximum allowable voltage of 3.6V.
The scope includes a low pass filter on the output of the signal generator so that a sine wave can be generated from a suitable PWM signal.
AssemblyAssembly was straightforward. Here’s what it looked like after all of the parts were soldering onto the perf board.
But wait! What are those fat, ugly white things you might ask. Well, for some of the longer connections on the board I decided to use lengths of Apple USB cable (the sort with the now obsolete connectors). I used these not only because I was running short of hookup wire but also because these cables are shielded and so there was a hope that they would insulate the ADC inputs from noise.
Finished ProductOK. So it’s ugly, unsophisticated and has low specifications but for where I am in my electronics learning journey my ‘Parts Bin Scope’ works just fine for me. Who knows, one day I might splash out and buy a real scope like a DSO138 ;)
1. Switches to change input voltage range
The lack of switches in the parts bin has meant that the input voltage range can only be changed by opening up the enclosure and moving a header attached to the op-amp feedback resistors. Very annoying.
2. Better access to logic analyzer inputs
Only two of the logic analyzer inputs have connectors accessible from outside the enclosure - so a dedicated connector would be useful to be able to use all 8 channels.
3. Logical analyzer level shifting
The voltage at the logic analyzer inputs is limited to 3.3V. It would be convenient if it also accepted 5V logic.
Comments