![]() |
![]() |
![]() |
|
|
|||||||
| Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution. |
|
|
Thread Tools | Display Modes |
|
|
(permalink) |
|
I know there are projects like this out there, but I would like to attempt my own.
I would like a high speed analog front end feeding an external ADC interfaced to a PIC via SPI, and PIC to PC via USB, and a Visual Basic or C# program written to display the data. This is somewhat of a big project, but I think I can pull it off given my past experience. First question: What is the max transmission speed of an 18F series pic on the SPI bus? I can't seem to find it in the data sheet. |
|
|
|
|
|
|
(permalink) |
|
alright this might be way off but i imagine your best bet would be to find a REALLY old one and try to emulate what the components are doing. i think a CRT screen would be a must since the inputs would be so much easier
|
|
|
|
|
|
|
(permalink) |
|
Max clock on the SPI for 18F2525 is Fosc/4 (or Tcy). Document is DS39626E-page 166.
If you have a different PIC family, search for SCK. |
|
|
|
|
|
|
(permalink) |
|
Mkay, so with a 40MHz xtal oscillator, anything more than 10Msps is definitely a waste. And I probably can't even come close to that when you consider overhead of the SPI and USB functions for two channels.
I essentially want two channels of data to the PIC as fast as it can go, and the PIC spitting it out over USB2.0 to the PC. Any idea what kind of sampling rate I would be looking at overall for a dual channel system? |
|
|
|
|
|
|
(permalink) |
|
With a 40MHz oscillator, your transfers will take on average 4*10 Fosc, or 1 MHz max.
|
|
|
|
|
|
|
(permalink) |
|
I was just looking at the dsPIC4011 with it 30MIPs run clock and 1000ksps 10bit A/D would make a nice scope PIC.
|
|
|
|
|
|
|
(permalink) |
|
SPI speed will be listed under Electrical Specifications, in the form of required delays.
Keep in mind a scope generally won't continuously dump data to the computer. This could exceed viewable speed. Instead, you have a triggering event, capture say 256 samples, and you may not begin capturing on the next triggerable event if it's too soon. But capture speed is still very important because that affects your max sampleable frequency. 100ksamp/sec would not correctly read components above 50khz (Nyquist rate). Note that the 30F series has pretty high power consumption at high speeds, and it's not as fast as the lower power 33F. There's faster 33F devices up to 1.1Msamp/sec IIRC, and the processor's up to 40MIPs. You probably need a USB port for sure though. There's also the new PIC32 line, half the product tree has USB.
__________________
I thought what I'd do was I'd pretend I was one of those deaf-mutes. |
|
|
|
|
|
|
(permalink) |
|
To see data prior to the trigger you must start sampling data at run and continuously sample up to and some distance past the trigger event.
__________________
search engine for electronic partsJunebug USB PIC programmer kit., USB Bit Wacker, Homepage The 15 Minute Printed Circuit Board! (+drill time) |
|
|
|
|
|
|
(permalink) |
|
I realize this is not as fun as doing it yourself, but have a look at this:
pcscope @ yahoo . co . uk |
|
|
|
|
|
|
(permalink) |
|
Yes the simplest way to do it would be a dsPIC they have internal ADCs capable of 1000ksps and some even 2000ksps. An external SPI ADC would not provide much better because the SPI line will run at max 40Mhz for the high end dsPICs.So if the ADC takes 1 byte of data to get 1 sample you get 5000ksps.
For a real good scope a difrent method must be used.A ADC with parallel output (all high speed ADCs are like that for the obvius speed problems of SPI) and just connect its data lines to a RAM chip.Then there is a binary counter connected to the RAMs address bus and the clock line of the counter and ADC conected to a oscilator. So for evry pulse of the clock line 1 sample is stored in to the ram chip. With this method i guess up to 100Msps is posible. Also this would preferdaby be asembeld from SMD components on a well designed PCB because you are dealing with very high freqency signals. As for the analog front end you should have a good modern opamp to amplify the signal so you can have a like 100mV and 10mV range and some kind or resistor divider cirucit to provide the ranges for voltages higher than 5V. Also you need to have a AC and DC setting where the AC has its 0V at acualy half of the supply voltage so the signals that go below 0 dont get cut off. But for a start a dsPIC and its internal ADC should do.
__________________
Il give you shocking experience. |
|
|
|
|
|
|
(permalink) |
|
thats a very good price but what is the top frequency ?
__________________
I AM the exeption that disproves the rule in many ways but the rules still apply (unfortunately) my site:www.simons-photography.com http://rushdenrotaract.org.uk see also http://www.bigstockphoto.com/account...fid=m2URATYch5 http://www.redbubble.com/people/simonsphotography |
|
|
|
|
|
|
(permalink) |
|
The sample rate is 800 Ksps, but see this for the difference between sample rate, analog bandwidth and effective bandwidth:
PC Based Digital Storage Oscilloscope Adaptor Mk3 Also, see this on "real-time equivalent sampling": Real-Time Versus Equivalent-Time Sampling > Application Note : Tektronix |
|
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Latest |
| PC Based Oscilloscope | ml_natasha | Electronic Projects Design/Ideas/Reviews | 7 | 10th September 2006 01:05 PM |
| PC-based oscilloscope | mshemyalnisar | Electronic Projects Design/Ideas/Reviews | 9 | 30th July 2006 07:58 PM |
| PC-based oscilloscope | Natasha125 | Electronic Projects Design/Ideas/Reviews | 2 | 27th March 2004 04:00 AM |
| PC-based oscilloscope | Natasha125 | General Electronics Chat | 2 | 26th March 2004 06:04 PM |
| PC-based oscilloscope | Natasha125 | General Electronics Chat | 3 | 2nd March 2004 03:39 PM |