View Full Version : DIY Logic Analyzer

June 29th, 2011, 06:49 PM
I ran across a site where a guy had designed an USB 26 channel logic analyzer around Amtel Maga(something) and has the schematics, board layout, solder mask, software etc.

Is there any interest in something like this?

If so, I'll gather up the info and present it here.

June 29th, 2011, 07:35 PM
I'd like to know more about it.

June 29th, 2011, 09:57 PM
If it's around an Atmel ATMega C, it's going to be speed- and memory-challenged, from the ones I've seen.

June 30th, 2011, 12:24 PM
FYI - If you can find an HP LA on Ebay w/ PODs, you may get a good deal. Some of the older models are good enough for 70s/80s era vintage. I did the research and determined spending ~$100 on a HP LA was worth it vs the USB route. It works too!

June 30th, 2011, 01:57 PM
I have and use an older HP, but there is something to be said for a logic analyzer that doesn't take up half the bench.

June 30th, 2011, 07:46 PM
I'd like to know more about it.

OK, here's the link to the info http://lekernel.net/blog/2009/01/usb-logic-analyzer/

Downside is that it requires some large SMT chips soldered and, although the guy gives some tips for doing it, it's not the world's best advice. I could solder the chips on with no problem, but, someone without a lot of soldering experience would probably ruin the chip, the board or both.

In the meantime, I found an Asian company (which I am applying to for the Canadian distributorship) where you can get an assembled 16 buffered channel board, a 16 channel buffered wing board and 4 sets of 8 clips for under $100.

Looks like good construction, and a sound design, updated software flashable through the USB (2.0) port and a support community. They have lots of other stuff too from kits to robotics to gizmos to pcb design. Looks good.

Of course I'd buy one of the logic analyzers and test it out thoroughly first, but, basically, if you wanted to, you could drop it into a project box and have a nice little 32 channel LA.

•Capture 50MHz+ waveforms on 32 channels

◦200Msps captures up to 100MHz waveforms on 16 channels
◦100Msps captures up to 50MHz waveforms on 32 channels

•16 buffered channels, 5volt tolerant
◦M74LCX16245DTR2G transceiver tolerates voltages from -0.5V to +7V.

•216K Block RAM supports following memory configurations*
◦8 channels with 24K sample depth
◦16 channels with 12K sample depth
◦32 channels with 6K sample depth

•External clock and trigger input
◦Allows interfacing with external test equipment and daisy chaining OLS's for additional channels.

•Internal clock and trigger output
•16bit wing expansion header
•USB interface, USB powered
•USB upgradable everything
•Designed for the SUMP logic analyzer client
•Open source
•Low price
*Memory depth is the maximum supported by the hardware, the current firmware implements the following memory depths:

•8 channels with 16K sample depth
•16 channels with 8K sample depth
•32 channels with 4K sample depth

Future firmware upgrades will support the maximum memory configurations.


•Latest project downloads, project page
•Design overview and links
•Issue tracker

June 30th, 2011, 08:58 PM
If you advertise 200Msps, make sure that the device can in fact handle that frequency without loading the line being tested excessively. Professional logic analyzers go for the big bucks because they don't affect (much) the circuit being examined. There's a lot of engineering in those input circuits.

Speaking from experience, there's nothing more frustrating that having your design fail or succeed with a logic analyzer attached, only to have the reverse happen with the analyzer removed.

June 30th, 2011, 09:04 PM
That link is broken for me, but from the description it sounds like the OpenBench Logic Sniffer (http://www.gadgetfactory.net/index.php?main_page=product_info&cPath=10&products_id=30&zenid=b7f0b9374300cb36a967dca125a66619). If so, it uses a Spartan 3E and a PIC, not an AVR. I have one. It works pretty well for $50 assembled.

June 30th, 2011, 09:22 PM
That link is broken for me, but from the description it sounds like the Openbench Logic Sniffer. If so, it uses a Spartan 3E and a PIC, not an AVR. I have one. It works pretty well for $50 assembled.

My thought was that it might use a FPGA, but Dru had said Atmel "Maga". So I was trying to fill in the blanks. There's some VHDL on opencores for an LA also and I think a design using a C and a largish CPLD (at least you don't have to load the configuration RAM up on that).

Edit Da*n!--now you've got me thinking about this.

First off, the idea's not new. I've got a PCB here that's perhaps 20 years old and uses an 8048 C and a whole bunch of FIFOs. It could do 16 channels, but wasn't fast--I suspect it couldn't sample at more than 1 MHz--I'd have to go back and look. Communication back to the PC was over RS232 at 9600bps.

The weakest part was the PC software. There was no way to say "Trigger, immediately, look for pattern XXXX and show me what happened 200 samples prior to that". Triggering was very simple and it simply filled the FIFO, displayed the result and stopped.

But what bothered me was that there was no isolation of ground lines--if the piece of gear you were working on had a leaky cap in the line filter, you could be in for trouble. Sometimes logic ground was not the same as chassis ground.

If you clipped the test lead to an RS232 line by accident, you could blow the TTL input buffer (fortunately, they were cheap and in sockets). Since it was LSTTL, you had a loading issue to deal with.

In short, it was a useful toy.

Another useful item on an LA is a glitch detector; i.e. a detector that indicates when a line changes state faster than your sampling rate.

I would not put the PCB in an aluminum enclosure with short probe leads, cool as it might seem. On a large board, the enclosure is going to be resting on the PCB being probed. Sounds like trouble to me.

July 1st, 2011, 07:33 PM
OK, in my last post, there were two separate items. The first two paragraphs and link were one item (link works now) but I rejected that one because very few people would have been able to assemble it. I just linked it because I said I would. It does NOT run a MEGA(something). I had looked at about a dozen LAs by that time and, although I should have went back and checked what chip it used, I didn't.

The rest of the post concerned an assembled unit (yes, it's the Open-Bench Logic Sniffer) which seemed much more robust and seems to have been developed in the same manner as Hargle's (et al) 8 bit IDE controller.

In actual fact, I'm not "advertising" anything. I just copied the features for interest's sake.

I read up on the unit and it seems to be a cost-effective unit that, unless you are doing "mission-critical" work would be more than adequate for working on vintage machines. I don't need a 1 GHz scope to work on an Atari 400.

As for a metal enclosure, I would have no intention of putting the board(s) in one. I would use a good static-resistant plastic case for just the reason you mentioned, Chuck.

If I do get the distributorship, which seems likely, and I do decide to invest an initial $500 in various test equipment items (4 channel LA, 16 channel LA, 16 channel upgrade boards, single and quad digital storage scopes, capacitor testers et c.), and, since, as a distributor, I will be able to sell them for less, I'll avoid making them available here since it seems that the consensus is that they are inferior items.

July 1st, 2011, 07:41 PM
It's not that they're inferior, Dru--you just have to represent them for what they are--casual, limited-use devices, not intended to compete with professional-grade instruments.

I tend to think of a logic analyzer as a design tool, rather than a diagnostic tool, but that's just me, I suppose.

The other problem I see is that it's already available for $50 south of the border, so your customer base may be somewhat limited to northern environs. And then there's the problem that some guy in Shenzhen may decide to start turning these out and undercut you completely.

July 1st, 2011, 09:24 PM
The Openbench Logic Sniffer is already being assembled in Shenzhen. Mine shipped direct from there.

July 2nd, 2011, 07:21 PM
Oh course they are limited, there are, like, again, the XT-IDE, the most features you can squeeze in for X amount of dollars.

The point is, how many people really need a professional level LA? I certainly don't and I certainly don't want to pay the kind of money that one costs.

Before anyone says "hey, they are dirt cheap on Ebay", I went on FeeBay today and did a search on logic analyzers (professional quality) and here's what I found;

The criteria I used was as follows;

1) Has to have been tested (I would have been satisfied with tested as opposed to calibrated) by showing it acquiring a signal or two.
2) Had to have pods/probes (kinda useless without them)
3) had to be shown powered up

I don't think that was asking too much, but, after 600 listings and the price up to almost 5 grand (plus shipping), not a single unit passed all three criteria. Most were listed as untested or As-Is.

Kind of a crap shoot.

Now, as a distributor, I would be getting any item I order at a good discount, enough to sell it for less than the manufacturer sells it for. The only one of 3 North American distributors they have listed that actually lists any of the products sells the LA for $70 US.

Being in Canada, as opposed to China, has certain "value-added" advantages such as a couple of days for shipping a unit to someone in NA as opposed to 3 weeks. Another is replacement units for any defective items in a week as opposed to 6 weeks.

In the case of kit only items, like the capacitor tester or adding the 16 channel buffered wing module to the LA I gave the features for, I'm more than qualified to either assemble the kit or do the pinning and soldering for the wing. At extra cost, of course.

I can also source cases for individual equipment or system integrate several devices in one case (since a number of the test equipment items are designed to link to each other). Again, at extra cost.

So, just as in selling clone boxes, it's not the item itself, it's the services that you can add to them that makes the difference.

I wouldn't list any item, test equipment or other (and they have over 350 different items) until I was an expert at it and could answer any question or solve any problem which, as a technician, is what I do. Sort of a liaison between the engineering team and the layman.

July 2nd, 2011, 07:30 PM
Of course, I see your point. What might make more sense to the denizens of this forum is an inexpensive USB oscilloscope that can run with a decent (e.g. 10MHz) sampling rate. Only one probe at that. Could also be used as a voltmeter.

On the shipping from China--most of the time, the stuff from Hong Kong or Bangkok beats stuff sent First Class USPS or UPS Ground domestically. I've even had Chinese shipments beat USPS Priority Mail--and these were all ber-cheap "Free Shipping" items. Probably being on the West Coast helps, but still. Average for a shipment from Hong Kong seems to be running a day or two less than a week. I wonder if US taxpayers are subsidizing the shipment cost.

July 2nd, 2011, 07:52 PM
The best I could do in a single channel scope is a 5MHz sampling rate at 54 bucks (retail) but they have a nice quad channel number for 199 (retail) with the following specs;

•Pocket size and light weight
•Two 72MS/s analog channels, plus two digital channels
•Signal Generator
•Auto Measurement
•Various Triggering Option
•Easy waveform storage
•Firmware upgrade
•User applications
•Open source

•Analog channel * 2 : [CH_A] [CH_B];
•Digital channel * 2 : [CH_C] [CH_D];
•Vertical Scale: 20mV-10V/div (x1 probe);
•Vertical solution: 8 bit ;
•Input coupling: AC/DC ;
•Max input voltage: 80Vpp (x1 probe);
•Storage: 4K per channel
•Software trigger type: edge, pulse, level (to be added)
•Hardware trigger type: edge
•Trigger source: CH1/CH2/EXT
•Test Signal generater: 10Hz to 1Mhz
•Storage: internal 2MB USB disk
•Auto measure: Vmax, Vmin, Vpp, Vavr, Vrms, Freq, Period, Pulse, Duty
•Cursor measurement: Level, Voltage
•Display mode: CH1, CH2, EXT, CH1+CH2, CH1-CH2, CH1*CH2
•Sampling mode: real time
•Sampling rate: 1kSa/s - 72MSa/S
•Power: Lipo battery
•Dimension: 98 * 60 * 14.5
•Weight: 80g (without battery)
•Accesories within Pack: 2 mueller mcx osilloscope probe, 2 digital probe,
Pack list:

•DSO Quad X1
•Operation manual X1
•Battery X1
•Mueller mcx osilloscope probe X2
•Digital probe X2

As for shipping, being on the west coast must help because I've been waiting 2 weeks for something shipped from China while two items, one from Utah and one from California, all shipped on the same day are already here by USPS International.

July 5th, 2011, 07:32 PM
OK, I've been offered the distributorship (they've change the terms a bit, so I have to rethink it a bit), but, I have to gauge the market and, since the market, for the most part, because of the nature of my website, is you people, I'd like to know if there would be any interest at all in this equiment.

The initial purchase ($1,000 now instead of the $500 listed on their distributor page) would be test equipment but they also have robotic items, prototyping, and a number of other electronic items.

Most of this stuff is open source and updates are regular as are add-ons to existing items.

So, what do you think?

July 5th, 2011, 09:47 PM
Can you elaborate on the offerings a bit?

July 6th, 2011, 07:35 PM
Can you elaborate on the offerings a bit?

Yes, I can, and I will, if I get the right answers back from them.

It seems that not all the items they sell are available to a distributor because some of the items are a co-operative effort between SEEED and members of the forum. The designer sets the price and most of them (foolishly) don't offer discounts to the distributor. They seem to not realize that 20% profit on 10 units isn't as good as 10% profit on a thousand units.

Of the 27 items in just the test equipment section, only 6 of them are available at a discount and none of the LAs are among them. I haven't checked out any of the other sections (I told them I wasn't ordering anything until I saw what my discounted prices were going to be) so they let me see the distributors pricing (who the hell runs a distribution model like that?). It's decent, but, nothing to write home about and without access to ALL the items at a discount, it would be a waste of my time.

July 10th, 2011, 07:14 PM
Having made some progress with this on the discount front, I cobbled together this file


which shows some prototyping and test equipment that I would be carrying. Mind you, this is only 31 of almost 400 items in several categories (Microcontrollers, Bundled Sets, Wireless, Sensors, Power Supply, Components, Display & Touch, Robotics, Hacking & Measurement, Prototyping, Accessories, et c.)

I hope to be able to sell the items at, or below, the price listed in the PDF.