Logic Probe - Homebrew. ( What do you think ? :P ) - Page 1
Forum section: electronics / projects

author: Madsaaby
author_rank: Regular Contributor
timestamp: May 30, 2012, 11:11:21 pm
content: Hi guys..Designed this logic probe, and since I have no experience in these, I thought about posting it here for you guys to comment on, and maybe give advice, if you want..Or, if anybody could use it for anything (I doubt they can ;]), feel free to do so..So, I wanted it to be very simple and relatively small (ended up twice the size of a 9v block). It should at least have a range from 3,3 to 8 volts, and be able to measure HIGH, LOW and FLOATING pins. I'm not the most experienced in electronics, and ended up using a PIC micro I had laying around, as I thought that would be the simplest.I use the ADC to measure the voltage on the "test pin" and compare it against a "reference" set earlier (the test-circuit HIGH, made it so you put the tip on the positive rail and press a button, it then stores the value for future reference, until a new is set). The input is divided by 2, so the range is 10v Max (Uc @ 5v). I inject a high impedance voltage on the input with the PWM (filtered) that's half the "reference", so if this voltage is not pulled up or down, It knows the pin is floating (I realize there could be a problem here). Anyway if the measured voltage is "near enough" HIGH or LOW the corresponding LED will light up, else the FLOATING LED will.I know the whole concept of using the ADC makes things a little slow, but I think its fine for what I need it to measure. Tested it to work up to 70 Khz, depending on the signal 115 Khz was kind of reliable, but with a few dead-spot frequencies, where it didn't pick up the HIGH's.The worst problem I see is with my PWM "Float test", as it will not work if the testpin is actually fixed at half the operating voltage.. (I guess real logic probes will be able to tell the difference?)So, what do you think.. Should I "toss it in da bin" ?-Mads

author: hlavac
author_rank: Frequent Contributor
timestamp: May 31, 2012, 01:55:49 am
content: A good logic probe should catch short pulses that are not visible to human eyeI just recently designed a nice simple probe that is usable over more than 100MHz signals (well 100MHz is the fastest I could test and it worked nicely) and catches pulses only a few nanoseconds wide (tested with 15ns pulses which is the shortest I could generate with ATtiny25 and its 64MHz PLL clock).It is a simple window comparator, one side detects voltage above VIH and other side below VIL, and each of them triggers a pulse widening circuit made of two NAND gates that drives a LED. These make sure that the pulse is never shorter than at least around 10 ms so it can be seen. Tip is floated to something in between to detect floating inputs (neither of the LEDS is lit = it floats).First I used a nice high speed comparator but it looked too expensive and had big bias currents I did not like.So I made a discrete jelly bean design that I later realized to be basically two open loop op-ampsIt has a 1M input impedance at DC which goes down at high frequencies due to the cap across the input 1M resistor (which is needed to catch fast edges).Left side power rail up to the transistors triggering the pulse stretchers could be separated and connected to the measured device's power, making correct CMOS logic level thresholds automatically. I didnt's bother, as I only use 74HC at 5V.It looks like the circit will fit into a gutted board marker pen case but I haven't finished that yet (tricky 3D soldering and shaky hands...)

author: hlavac
author_rank: Frequent Contributor
timestamp: May 31, 2012, 02:27:01 am
content: As I said above, I'm missing a pulse detector, which is understandable given the usage of very slow crappy ADC to read the tip voltage.I would not worry about the voltage at middle not being discerned from floating input, this is a logic probe, so this is unlikely.You could in fact wiggle the midpoint a bit with the PWM and see if the tip follows or is pinned, but that could turn into a signal injector real fastI'm missing loading caps on the crystal (18-22pF from each end to ground, see datasheet of the PIC for high speed crystal oscillator setup).I would consider using the internal RC oscillator and losing the crystal, I think it is not necessary (ADC is slow anyway, like 15kHz max sampling frequency if I remember correctly, any faster and you lose precision/bits of result) and takes up space unnecessarily.The method of remebering the voltage levels is interesting, usually you simply connect to the supply voltage of the device and use voltage dividers to get correct thresholds, but this works too.I think the Floating LED is redundant, no LED lit works equally as well and is smaller.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 31, 2012, 04:50:50 am
content: adc? for digital logic? why? (i dont think its a good idea)

author: Madsaaby
author_rank: Regular Contributor
timestamp: June 01, 2012, 07:37:47 pm
content: Thank you very much for your replies.. Both of your schematic look very nice.. I will definitely scrap the MCU, and use discrete logic instead.. I will try breadboard some and do a little "testing", to get to know this better

author: hlavac
author_rank: Frequent Contributor
timestamp: June 01, 2012, 08:17:43 pm
content: If you want to test a logic probe, I have written a small program for ATtiny25 that makes short 15ns and 30ns pulses of both polarities every second (and flashes LED on fifth pin with a 50ms pulse so you know when to expect the pulse to be detected by the probe).I could post the source here.

author: hlavac
author_rank: Frequent Contributor
timestamp: June 01, 2012, 09:04:16 pm
content: Here is the probe test rig. Burn into ATtiny25/45/85. Set clock source for high speed 64MHz PLL in fuses. See picture for test signal pinout.