DPScope Build Your Own USB PC Based Oscilloscope
DPScope Build Your Own USB PC Based Oscilloscope
DPScope Build Your Own USB PC Based Oscilloscope
Step 11: Assembly - Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 Step 12: Assembly Step 1: Unpacking the Kit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 Step 13: Assembly Step 2: Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 Step 14: Assembly Step 3 - Component List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Step 15: Assembly Step 4 - Component Placement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Step 16: Assembly Step 5: Installing the First Part - R19 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Step 17: Assembly Step 6: Soldering the First Part . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Step 18: Assembly Step 7: Next Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Step 19: Assembly Step 8: Remaining Resistors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Step 20: Assembly Step 9: Capacitors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 Step 21: Assembly Step 10: Diodes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 Step 22: Assembly Step 11: Trimmers, Resonator, Jumper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 Step 23: Assembly Step 12: First Socket . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 Step 24: Assembly Step 13: Remaining Sockets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 Step 25: Assembly Step 14: BNC Connectors; Frontpanel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 Step 26: Assembly Step 14: BNC Connectors; Frontpanel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 Step 27: Assembly Step 15: LED Indicator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 Step 28: Assembly Step 16: IC Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 Step 29: Assembly Step 17: USB Cable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 Step 30: Assembly Step 18: Probe Calibration Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Step 31: Assembly Step 19: Putting It All Together . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Step 32: Assembly Step 20: Software Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Step 33: Assembly Step 21: Software Start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 Step 34: Assembly Step 22: Offset Adjustment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 Step 35: Assembly Step 22: Offset Adjustment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Step 36: Assembly Step 23: Probe Compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Step 37: Scope Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Step 38: All Done! . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 Related Instructables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
(external supply 7.5 - 9V / 300mA optional) Approx. size (in enclosure): 4.5" x 2.6" x 1.2" (114 mm x 66 mm x 31 mm) Component count: ~50 Solder connections to make: ~200 Required skill level for assembly: moderate; only through-hole components and DIP packages (no surface mount or fine pitch parts) Printed circuit board: Professional printed circuit board with corrosion-resistant, gold-plated pads and contacts (not cheap solder finish), with silkscreen to denote component locations. Enclosure: Sturdy ABS plastic enclosure with custom glass-fiber front- and back-panel, silkscreen. All holes pre-drilled - no drilling required. Microcontroller and USB interface: Fully pre-programmed; no programming required
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Step 8: Microcontroller
The Microcontroller is the heart of the DPScope. It is a 16-bit Microchip dsPIC30F2020 which has a lot of desirable features: Not only is it blazingly fast (it runs 32 MIPS on a 128 MHz clock - this is very slightly outside spec - max. 120 MHz - but works perfectly fine) and comes in a hobbyist-friendly DIP package; since it is geared towards digital signal processing or DSP (that's where the "ds" in the name comes from) it also has a bunch of useful mixed-signal periphery already built in: First and most important, it has an analog-to-digital converter that can acquire samples at 2 MSamples/sec. At least that's what the spec seems to say at first glance. The reality is - it can acquire two channels simultaneously at 1 MSample/sec each, and the Microchip marketing guys simply added those two numbers... anyway, that's perfectly fine for us because we need two channels anyway. The ADC has a resolution of 10 bits, but in order to maximize acquisition speed and reduce memory requirements only the upper 8 bits get used (i.e. one byte per sample). The reason for using a 128 MHz clock is the same - at that speed the dsPIC is just barely fast enough to repeatedly sample two channels and store the data into internal memory at 1 MHz sample rate. The analog bandwidth of the ADC is well above 1 MHz, so it's not a limiting factor in the signal chain. For sample rates faster than 1 MSample/sec - up to 20 MSamples/sec - the DPScope employs a technique called "equivalent time sampling" - basically it runs at 1 MSample/sec real sample rate and acquires only a subset of the data points at each sweep, and then overlays two or more subsequent sweeps (each with slightly increased start delay after the trigger) for a composite picture with higher effective timing resolution. You can read more details about this technique in the Tektronix application note"The XYZ of oscillscopes" . The second great feature of this microcontroller is a set of comparators with finely controllable threshold (10 bit resolution); most other Microchip devices have only very coarse compare threshold steps. These comparators are all we need to implement a full-blown scope trigger with adjustable threshold and selectable edge polarity (rising or falling edge, respectively), which cuts down on overall component count and thus cost and complexity. The only sore point with this dsPIC is its small RAM size - just 512 bytes. Some of that is taken up by program overhead (e.g. global variables, parameter stack and so on), and it was a challenge to get at least 200 bytes per channel (actually 205, since this works out to 410 points for FFT - where only one channel as acquired at a time and 410 is 4/5 of the 512 points needed for the FFT, which makes interpolating it to 512 points fairly straightforward); a future version of the scope may use a different dsPIC device (but right now there isn't any that has all the other features, runs at 5V, and is available in DIP package). Adding external RAM is not an option either - first, it would add cost and complexity, second, the dpPIC does not have enough output pins to control it, and third, at maximum sample rate there is no time for additional control tasks anyway. But 200 points is good enough for a full display, and in most applications the DPScope's delayed trigger capability provides exactly the same functionality that a longer capture memory would. Finally, the dsPIC supports SPI and USART communication, which it uses to control the other devices in the DPScope (adjustable gain amplifiers, offset DAC) and communicate with the PC, respectively.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
- Small soldering iron (about 17 Watts power) with sufficiently fine tip - Solder wire - Flat-nosed pliers (to bend component leads) - Small wire cutter (to cut off component legs) - 14mm wrench (to fasten the BNC connectors to the front panel) - Small Philips screwdriver (to adjust the trimmer resistors and for the enclosure - Small non-metal screwdriver (to adjust the trimmer capacitors) The time required for putting the scope together will depend on your experience a seasoned hobbyist should be able to do it in maybe two hours (I do it in 45 minutes but of course I know the component locations by heart now), but if you are new to this it will take longer.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
All components that are difficult to distinguish (e.g. resistors) are clearly labeled with their respective value (e.g. 100 pF). The integrated circuits and the diode are sensitive to electrostatic discharge it is good practice to use a grounded wrist strap to avoid damage to them during assembly, and to place all the components on an antistatic surface. Dont wear clothes that get easily charged up (e.g. wool sweater).
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
The picture on the bottom shows the PCB populated with all the resistors.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Below you see how the board should look like after this step.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Make sure the board fits and sits loosely on but does not push too hard against the standoffs inside the enclosure. If necessary loosen the nuts a bit so the connectors can move against the frontpanel. Tighten the nuts again sufficiently to hold the BNC connectors in place. Only now solder the BNC connectors onto the board start with the clamped-in feet, and finish with the signal wires. The clamped feet will need a lot of solder to fully fill up the mounting holes dont be shy, because thats the only thing holding the PCB in place.
Now put on the frontpanel the LED must go through the center hole. Put on the nuts again and tighten them down with a wrench. Be careful not to over-tighten them, damaging the connectors threads! The frontpanel now holds the LED securely in place. Turn the board around and solder the LEDs legs onto the board.
Note 1: Make sure to put the chips on in the correct orientation. Each chip has a notch on one end this notch must go on top of the notch in the silkscreen outline (and the notch in the socket if you installed those correctly!). Note 2: There are two different types of the 8-pin ICs make sure you install them in the correct locations as shown in the picture below. Installing them in the wrong place (or the wrong orientation) will destroy them when you power up the oscilloscope. You can distinguish the chips by the labels printed on them (two are labeled MCP6S22, one is labeled MCP4822).
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Red (red) Yellow (yel) Orange (org) Green (grn) Brown (brn) Black (blk)
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
The DPScopes frontpanel LED should blink a few times and then stay on. The blinking should last for about one second total. If thats the case then your oscilloscope has just passed the first functional test! Note 1: The DPScope software needs a screen resolution of at least 1024 x 768 pixels. Note 2: It is recommended to connect the DPScope to a USB port of your computer itself, or to a powered USB hub. Unpowered hubs tend to have large voltage drops, and the DPScopes level accuracy is dependent on a steady 5V supply voltage from the USB. You can test the voltage by connecting a voltmeter to the pins labeled + and - on the expansion header (bottom right on the PCB).
Attach the two probe cables to the BNC connectors (CH1 and CH2 on the frontpanel). Now we need to make two simple adjustments to optimize the scope performance.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Related Instructables
.... by vithrar
RF probe by neelandan
Comments
50 comments Add Comment view all 86 comments
Mar 15, 2011. 5:45 PM REPLY
saturnino says:
Most nicely explained project. Could there be another projects ? Best wiches. Carlos Ahumada Santiago de Chile
womai says:
Mar 18, 2011. 12:01 AM REPLY Yes, there will be. Right now I am working on a simple AWG (arbitrary waveform generator) and a very simple, no-frills oscilloscope (much less capable than the DPScope but also even lower cost). The AWG should make a nice complement to the DPScope. Both instruments will use the PC for control and display, just like the DPScope. The challenge here is to reduce component cost to absolute minimum. Microchip has a couple low-end, low-cost (a third of the price of a 18F2550 or 18F4550) USB-capable microcontrollers that will be fun to work with. Right now I'm waiting for the development board for them. Stay tuned!
hesslerk says:
Hi there,
I am working on a PIC project right now with the PIC18F4550. Would it be possible for you to send me your C++ code for the oscillator, ADC, and SPI communication? [email protected] Thanks! Kurt
womai says:
Mar 17, 2011. 11:48 PM REPLY This scope is based on the 16-bit dsPIC30F2020, which has a very different architecture compared to the 8-bit PIC18F series, so that won't help you much. For PIC18F series development I use MIkroelektronika's MikroC compiler and development boards. The compiler (2K limited demo download is free) comes with a few examples for the 18F4550 - just use these as a starting point, they should work right out of the box (they did for me). They use an external 8 MHz crystal and run the core at 48 MHz (maximum possible) which is probably what you want to do (USB needs exactly 48 MHz anyway). MikroC has native libraries for ADC and SPI - very easy to use - so there isn't any clever code I could share for that. E.g. adc read is my_var = adc_read(channel)
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
If you are interested in USB using the 18F4550, go to the MikroE web forum and search for "USB" and author "womai" - I posted a full example (including VB6 source code for the PC side).
jumbocat says:
Mar 4, 2011. 7:21 PM REPLY Wow, Im about 4 mos into building electronic projects, and I have yet to see such amazing detailed instructions for a project! You put a lot of thought into this. I will definitely be pick your self assembly up as soon as my Solder skills are better. Feb 2, 2011. 12:24 PM REPLY Although I cannot but marvel at the quality of your work, I could not bring myself to give you a good rating, or even consider buying your kit. I have been a member of Instructables for quite some time and even before that, I would pop in to check on some project or another and trust me it's not the first time I see someone advertising their work. And believe me I am totally fine with that. As a matter of fact, I believe that if one can profit from a great design and/or personal work, it's not bad at all, as long as there are willing customers. To be honest, I expected many more reactions in the comments so far, since I've seen people get upset for less obvious advertisement. But in most other cases, as I recall, the 'ibles were enough to complete the project without having to buy something from a specific someone. In your case, you repeatedly refused to give the firmware and the circuit layout when asked and sometimes you did not even bother to answer. I know that if I were more skilled in electronics and mc programming, I would work something out on my own, as you pointed out (using a proto-board for example). Again, I am not giving you fault here, I just expected a little more honesty from your side. You could have stated in the beginning that this is an 'ible to build a very specific kit, as others have done. "Build your own" is a bit misleading don't you think? If I were to follow this 'ible, I would be building *your* USB/PCBased Oscilloscope, not mine. I have no intention of being offensive or anything, so I apologize beforehand if my comment upset you, I just thought I should give my two cents.
rosenred says:
womai says:
No offense taken. Two things I'd like to comment on though:
First, I don't agree with "you did not even bother to answer". If you read through the list of comments, I make an effort to always comprehensively answer whatever question - technical or otherwise - somebody has. A few - not many - of the comments though were not questions at all, for all can tell these individuals only wished to express their opinion but did not really seek any response or comment from my side. They are of course entitled to their opinion, so I let them stand as-is. Second, I do think there is a lot to learn from this project even if you have no intention of getting the board or kit. The whole hardware design - as well as the high-level software design - is documented and explained in detail - so you get a proven, usable analog frontend - a variable gain amplifier chain with ove a MHz of bandwidth - for free (of better design quality than many low-end commercial scopes have as I can assure you), as well as a good idea how a real digital sampling scope works. In fact I personally know about more than one person who copied all or part of the analog portion for his/her own project. I have seen many other instructables where the total amount of usable information was quite a bit less than this alone. Finally, I have published a fully open scope design as well - including firmware, board layout and so on, which everybody is free to use if so desired, so overall I do feel I contribute to this community in the way intended: http://www.instructables.com/id/LCS-1M-A-Full-Featured-Low-Cost-Hobby-Oscillosc/ Regards, womai
rosenred says:
Feb 6, 2011. 1:32 PM REPLY Thank you very much for taking the time to answer. I never said though, you are not contributing to this community, I assure that would be horrible on my part. I do get your point. I might have exaggerated a little and for that I must apologize. Thank you for the link to your other project. Again (with my little experience in electronics) I cannot but admire the design. I sincerely hope you were not offended or in any other way annoyed by my comment. I just expressed what was in my head at the time of reading.
womai says:
Feb 6, 2011. 4:29 PM REPLY If you like to get a quick and easy start in electronics, have a look at the Picaxe microcontroller (on which my other scope project is based). www.picaxe.co.uk - typical times - for an absolute beginner! - to get up and running and have e.g. an LED blinking is normally measured in minutes, not hours or days (no kidding). That's what go me started with microcontrollers and re-started with electronics a few years back. There is a very beginner friendly support forum for any questions you may have. And no, I don't get any kickbacks from them ;-)
rosenred says:
Thanks! I was considering the Andruino, but I am sure this one would be much simpler for a beginner like me :) Much appreciated!
womai says:
Feb 7, 2011. 7:57 AM REPLY The Arduino is very nice platform with a large community. But IMHO the Picaxe has a much easier learning curve for an absolute beginner. The basic circuitry is the Picaxe, two resistors for the program download connection to the PC (using a serial cable or a USB-toserial converter cable), and potentially one 0.1uF capacitor between power and ground. Can't beat that in terms of simplicity! It's also very inexpensive - just a few $ will get you there. The good thing is, once you got you feet wet with the Picaxe (and gained some experience with general electronics while working with it),
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
moving over (or up) to any other platform (Arduino, bare PIC or Atmel or any other microcontroller) will be much easier as all the basic concepts stay the same.
lgeorge123 says:
Jan 4, 2011. 3:39 AM REPLY I use visual c# to display my scope screen , your screen is 40+ frames/sec , do you feel your screen flicker ? in my code I use timer to update my ADC data and set timer to 4ms interval , I feel my screen flicker very fast : private void timer1_Tick(object sender, EventArgs e) { Graphics g = pictureBox1.CreateGraphics(); // pictureBox1 is picture that display grid pictureBox1.Refresh(); // function to display adc data; }
womai says:
Jan 19, 2011. 2:31 PM REPLY No, my software does not suffer screen flicker. The flicker in your case is most likely due to the fact that you initialize the display (copying the grid) and then draw the traces on a control visible to the user. The drawing takes some time (and the display may update each time you draw a line, making it even slower). A better (flicker-free) method is to draw everything on a hidden control (e.g. a second display hidden behind the "real" display object) and then copy over the complete picture. That's what I use. It's faster, too, because the hidden display does not get updated while drawing.
kalnas says:
What bandwidth I can see with this oscilloscope? from 1.3 MHz to ...?(60MHz)? Thanks for answer
womai says:
Sep 24, 2010. 9:18 AM REPLY The analog bandwidth is ~1.3 MHz. The maximum sample rate is 1 MSamples/sec real-time (for single-shot acquisition) and 20 MSa/sec in equivalent time mode (for repetitive signals). The 20 MSamples/sec means you can display signals up to ~2 MHz frequency (at that frequency they will be somewhat attenuated because the analog bandwidth is a bit lower than that, but you can still display them.)
lgeorge123 says:
Can you disclose how you do the trigger level function of your scope , as I want to do a project in my college .
womai says:
Aug 30, 2010. 9:22 AM REPLY For the trigger I use the built-in comparators of the dsPIC. It has an internal DAC (10 bits resolution) to set the compare threshold (note that it only covers 0V to VCC/2, so the scope has a 1:2 voltage divider in front of the comparator inputs). The comparator is set up so it generates an interrupt when the input rises above the threshold (i.e. compare output going from low to high); that calls an interrupt function which then performs the signal capture. You need to put a jump address to this function in the dsPIC's interrupt table at the proper location (see dsPIC data sheet). There is also a bit to invert the compare output so you can easily trigger on rising and falling edges, respectively. The beauty of all this for the scope is that apart from the voltage divider (two 1kOhm resistors) all the trigger circuit hardware resides within the dsPIC. For details about the comparators DACs etc. please refer to the dsPIC30F2020 data sheet - but basically you just write the appropriate value to a specific address in the dsPIC's RAM.
taurus123 says:
Jul 30, 2010. 5:03 PM REPLY This is not much of a scope, especially when you are doing digital work. It is slow, the software freezes, the screenshots are not that great. Look around before you buy this. For a few more bucks, you can do better than this. Apr 6, 2010. 12:07 AM REPLY
iEdd says:
I just built mine, and I'm a bit disappointed. Here's the problems I have so far: 1. The microcontroller gets pretty hot. I think hot enough to burn your finger if you leave it there for more than 10-15 seconds. 2. The waveforms in the software will be active for about 5 seconds, then freeze for about 5 seconds, then active again, etc.
3. After about 1 minute of constant operation, it freezes. The waveforms are frozen, but the software still works (I can move the sliders, etc). So I think it's a hardware/firmware problem and the microcontroller that is freezing. I have to unplug the USB cable and plug it back in to get it going again. Is any of this normal? I've been looking, but haven't found any shorts or bridges in my soldering. Has anyone else had these problems?
womai says:
Hello iEdd,
the microcontroller becoming hot is not a problem, but a feature :-) But seriously, this is normal, the Microchip dsPIC30F series is known for that, it uses relatively large power which produces heat accordingly. I should probably add a note to the assembly instructions so people don't wonder. I measure about 65degC on my DPScopes, which is indeed uncomfortable to touch but will not affect reliability (the chips are spec'd up to 125 degC operating temperature). The software freezing up is not normal though. I have built dozens of DPScopes so far and had them continuous in operation for days and weeks without this happening, on different computers. Also I have not a single other user report about this happening. As a first step, please try to operate the scope on a different computer and see if the problem persists.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Jeffrey G C says:
Jun 16, 2010. 11:26 AM REPLY Womai, i bought your dpscope also, and mine does the the same thing with the software, where it will work for a little while, but then after measuring, the waveform freezes, sometimes i cant even see the waveform, i have actually put it into a modded removable hard drive case this way i have a place to put a fan that will hopefully keep it cooler, i dont remember if that fixed it or not, i havent used it in a while, but i have another question, is it possible to not use the +5 power supply from the usb? in other words, is it possible to use a wallwart power supply to supply the power to the board, i saw that there were provisions in your schematics to run on external power, but i couldnt get it to to turn it on with the wall adapter, the i put in the 5v regulator, and the capacitor as well, i just made some rough mods, i painted it, but havent finished the whole thing yet, so if anyone likes i can put pics up when i finish it, it may be a while though
womai says:
Jun 16, 2010. 1:25 PM REPLY Hello Jeffrey, can you tell me what exactly the marking of your dsPIC is? Especially on the second line, does it say -20E or -30E? And the what is the last line (which is the batch code)? I recently encountered a batch of marginal dsPICs that had some issues (they did not freeze but their ADC was working too slowly once it heated up). That said, this only affected about 1% of the dsPICs I have tested. As for the external power supply, yes, all the hooks are there, you only need to add a 7805 regulator and another 100uF capacitor. Please refer to the assembly guide for details. From your description I suspect you simply forgot to move the power supply jumper to the "ext." position. (been there, done that :-) Wolfgang
Jeffrey G C says:
Jun 17, 2010. 4:08 AM REPLY 20E/SP 0841262 and i do have it on the ext power setting, so i know that shouldnt be an issue, the light wont blink on when the power setting is on ext, so i have no idea why its not turning on.
womai says:
Jul 14, 2010. 9:04 AM REPLY If the LED blinks when powered from USB, but not when (supposedly) running on external power, then something is not right with the external supply. Things to check: - is jumper set to "ext." when trying to run on external supply? - is the supply feeding into the "+" and "-" points close to the 7805 regulator? (not the test points close to the CAL connector)? - what is the spec of the external supply? - needs to be able to deliver ~500mA current, and have a voltage of ~9V (you need a bit more than 5V because the regulator adds ~2V drop) - use a voltmeter to measure the scope supply after the regulator (the "+" and "-" test points close to the CAL connector (not the points close to the regulator)! The measurement result should be close to 5V (+/- maybe 0.2V) By the way, I have added a user forum to the DPScope webpage (go to http://www.dpscope.com --> User Forum, or direct link http://dpscope.freeforums.org/). Going forward this is will be the best place to get help as I check it daily. Out of some reason Instructable stopped sending me notification when a comment gets posted so I may not see it for days or weeks.
iEdd says:
Apr 8, 2010. 9:00 PM REPLY Thanks for the reply. I've tried it on my Mac through VMWare and by booting into Windows, but it's the same install. I'll have to try it on another windows machine later. Also, wrt to software for mac - you mentioned that it would be good if an individual would get it working for mac/linux. I can get your DPScope program running on Snow Leopard with Darwine, which is easy. Just install as normal. Problem is, it doesn't recognise the scope. Are there any clever people out there that can get winehelper to emulate the COM port through the mac's USB? I don't think it should be that difficult, I'm just not that experienced with darwine or FTDI drivers.
womai says:
Jul 14, 2010. 8:59 AM REPLY I have added a user forum to the DPScope webpage (go to http://www.dpscope.com --> User Forum, or direct link http://dpscope.freeforums.org/). Going forward this is will be the best place to get help as I check it daily. Out of some reason Instructables stopped sending me notification when a comment gets posted so I may not see it for days or weeks when you post here (on Instructables). Jul 14, 2010. 5:59 AM REPLY I found several c# and c++ programs about pc based oscilloscope , they have buffer size range from ten thousands to store data from adc . If you use a rectangle size said 700x500 pixel to display the waveform , a maximium of horizontal 700 pairs of data to display on this rectangle . But the buffer size is ten thousand long , how can this rectangle accommodate this large buffer size ??
lgeorge123 says:
womai says:
Jul 14, 2010. 8:50 AM REPLY That works pretty much the same as scrolling through a text document longer than one page - only one screen of data (e.g. 700 pairs in your example) is displayed, but there is a scrollbar that you can use to look at different section of the long text (or waveform). The only difference is that the scrolling is horizontal, while in a text file you typically scroll vertically. Often there also is a possibility to fit the full waveform on the screen for a quick overview, of course you won't be able to see every little detail that way - like a thumbnail.
UltraMagnus says:
where is the firmware? without it this is nothing but instructions for a commercial proprietary kit.
avscb says:
You are right
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
jolshefsky says:
Jul 5, 2010. 4:00 PM REPLY I have been using your scope for several months now, and I'm generally satisfied; my complaint is largely offset by the extremely low cost and high functionality. My complaint is a design flaw in the offset voltage. It is reflected in the output across the 1 megohm voltage divider, sourcing several microamps of current. It is not a problem with measuring buffered signals, but it gets in the way of reading sensitive circuits. I had been using it on a high-impedance oscillator incircuit, and the DC bias would affect the operation of the circuit in a noticeable way. I think that if the DC bias were not present, the circuit would behave better. One workaround would be to set the offset voltage to zero although that prevents reading negative voltages. I think the input circuit needs a bit of a redesign. Offhand I can't think of a good way to do it without going to a full-blown differential input internally biased against VCC/2 which of course adds a couple op-amps to an already crowded (and power hungry) device. Simply floating the BNC ground to the offset voltage instead of tying it to system ground would alleviate the problem on isolated circuits, but grand external ground loops would probably thwart that (i.e. watching signals from the audio output of the computer would short the BNC ground to the PC ground which is tied to the USB ground, etc.)
womai says:
Jul 9, 2010. 9:10 PM REPLY Probably the easiest solution would be to AC-couple the signal. I.e. add a series capacitor between your point of measurement and the scope input. Depending on your frequency, a ceramic capacitor of 10...100nF should be a good choice. That will float your measurement point and avoid and bias issues. Note that due to the offset voltage the scope trace will not be centered around the zero marker, but that should be a very minor issue. The way the offset generation works was a design tradeoff I decided to make, and in 99% of the cases it won't affect usability at all; on the upside it allows the whole scope to work with just a single +5V supply rail. The clean alternative would have been to add a negative supply rail - could be done e.g. with a voltage inverter. The downside of that would be more components, potentially a larger board, and an increase of about $10 in cost. Given that the aim was to create something simple and very affordable for a hobbyist, that wouldn't have been a good choice in my opinion. Apr 26, 2010. 7:49 PM REPLY
camx says:
Built the scope and it works well. Very nice design.
raptorofaxys says:
Apr 3, 2010. 2:38 PM REPLY Great project! I've been looking for a long time for something around the same price point, and you really delivered a lot more than I was expecting to get for that sum. Many thanks for such an excellent kit! I just finished assembling it and playing around with it for a bit and it delivers.
Azayles says:
Mar 27, 2010. 4:06 PM REPLY Put it together fairly quick with no problems at all, aside from forgetting to solder the rest of the pins on one of the chips :P Works PERFECTLY! I'm so impressed, I've never been so pleased with something I've soldered together myself, and it worked first time :D Been using it to test the output of a servo controller circuit I built so I could check the PWM signals. The ability to save and load scope parameters is a BIG bonus! Thanks again, Wolfgang, you've made an electronics geek very happy!
Azayles says:
Mine arrived in the post this morning. Thanks, Wolfgang! Can't wait to get this thing put together and calibrated :D
I wanna say a very big personal thank you again as I've wanted my own scope for as long as I can remember, but have never found an affordable solution which is of good design quality as this kit is. Please let me know if you start selling kits for other equipment ;-) Next stop, a really good function generator with arbitrary waveform generation :D
MrMike says:
Great write up and an excellent kit. Easy to follow instructions even for a beginner.
Mine arrived 3/22/10 after a 3 week parts delay, (with timely updates form the author) and took me about 2.5 hours to put together and calibrate. Thanks for marking the caps, I didn't need to pull out the the microscope or the LCR bridge. This simple scope is a great addition to the tool box for any experimenter / hobbyist out there, and you can't beat the price.
cardinalflyer says:
Mine is all built up. http://s794.photobucket.com/albums/yy222/cardinal634/?action=view¤t=IMG_1593.jpg I added a switch & capacitor to each channel to make the input similar to a Tektronix oscilloscope I have.
This change lets me switch in a capacitor in series with the input signal. That way if I want to see what is happening on a DC signal, I can switch to AC coupling - the DC is blocked by the capacitor and I can look at the signal at a higher resolution. I found some small switches, drilled 1/4 inch holes below the seam of the box and placed so that it didn't interfere with or touch anything else. The lead from the BNC connecter was not installed in the PCB - it was pulled up and wired to the center of the switch. One lead of the cap was soldered to the PCB instead. A wire was added to that same lead and connected to one side of the switch. The other side of the capacitor was connected to the other side of the switch. The plastic tie-lock helped the board and the end plates in place while I figured out where switch would. To prevent mangling the box while drilling, I started with a 1/16" hole and then used a unibit from home depot to slowly open the hole a drill size at a time. There are more shots before & after the portion of schematic. I am new to photobucket, can't find a way to delete stuff.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/
Azayles says:
Just bought one! (told you I would ;-) ) Can't wait till it comes :D I ordered the kit version 'cause I like building things myself plus it's cheaper :P I'll probably post back here when it arrives to leave comments :D
pipponum1 says:
Feb 28, 2010. 1:12 PM REPLY Hi I have a question: you have a 1Ms/s interface with 8 bit per sample. It's 8Mb/s. Two channels are 16Mb/s. How can you send data to pc via a 500kbps interface? Do you throw away packages or.. How? Thanks
womai says:
Feb 28, 2010. 2:46 PM REPLY My scope works like any other digital sampling scope: It does not stream data to the PC at that speed. Instead, it captures one waveform record (~200 points per channel in this case) and stores it in the microcontroller's internal memory. After that it transfers that data to the PC (at 500 kbaud) where it gets displayed. Then it waits for the next trigger, captures another record, transfers that, and so on. On my computer I get about 35 - 40 records per second. For the eye it makes no difference, changes of the waveform display perfectly fluently - you won't be able to tell if it's 40 or 4000 records persecond anyway (remember, movies are just 25 pictures per second, the eye isn't faster than that). So overall, at fast sample rate the scope spends most of the time transferring and displaying the data. As I said, every other digital real-time scope works the same. There are scopes that can do 40 GSamples (yes, 40 billion samples) per second on several channels simultaneously, no data connection to the PC could get even close to carry that as streaming data.
pipponum1 says:
Mar 6, 2010. 4:17 AM REPLY Thank you for the answer. Another question. Is it possible to buy only the firmware? Simply the .hex file (which - I think - is not editable) sent by e-mail? If it is possible, how much is it? Thanks
gtkindust says:
Embedded link in step 10 for Diptrace is wrong. It shows www.dptrace.com should be www.diptrace.com
womai says:
Thanks for pointing this out! Should be correct now.
saLZBURG says:
I am interrested in building this scope but microchip doesn't have a 24 F 2020. What other chip could be used instead.
womai says:
Mar 1, 2010. 1:25 PM REPLY Actually the scope uses a dsPIC30 F2020, not a PIC24F2020 (which does not exist as you found out). But there is no need to order your own - a preprogrammed 30F2020 is included in the scope kit (which you can get from my website, www.dpscope.com).
womai says:
Mar 2, 2010. 7:10 AM REPLY Ok, just realized where you got the notion that it's a 24F2020 - a typo in my description. Corrected now. Sorry for the confusion.
media1328 says:
Mar 1, 2010. 9:52 AM REPLY Hello. many many thanks i have been looking for this scope for long times but now i can have it. my only question is how can i get the PCB for top and bottom layers? all bests for you Dear Womai.
womai says:
Hi,
the PCB is included with the scope kit that you can get from my website (www.dpscope.com), so no need to fabricate your own. The PCB isn't suitable for home-brew methods anyway since it has pretty small vias and narrow lines, and having one produce a single one professionally would cost more than the whole scope kit.
media1328 says:
Mar 1, 2010. 8:44 PM REPLY Hello thanks for your mail. as I understood I have to buy your kit and it's not possible I make it by myself. and in other hand I can't buy it directly because I have no credit cart. and or pay pal or such accounts so that many thanks again. and if it was possible for you to send me the top and bottom layout i can make the PCB by myself your help will be appreciated. thanks and good luck Media.
http://www.instructables.com/id/DPScope-Build-Your-Own-USBPC-Based-Oscilloscope/