Introduction: DigiLogiProbe V1 (updated With V2)

About: Electronics Technologist (44th year)


UPDATE: After four years of using two Tools, I have created an updated Version2 tool.

Jump to last page here. (20 February 2023)


WHY

I have searched around the web, and I could not locate a mash up like this. (Four years after I posted this page, I still cannot find a programmable Logic probe this inexpensive using ATTiny85).

DigiSpark was a crowdfund project to leverage the ATTiny85 chip on a USB board with the bare minimal Interface and power. This very small 2012 developer board has 6 pins. On China built work alike boards, 5 of those pins are useful. Clone boards are less than $3 Cad; original boards are $10 Cad but are sold out temporarily.

I have named my forked mashup design, the DigiLogiProbe V1 or

DIGI (to honor the original Digispark) LOGI (for LOGIC) PROBE.

Concept:

- use DigiSpark or Clone (with PB5 issue Fuse fixed) Dev board

- 9V (common type 6LR61 or 1604A) battery power

- any Logic level from 0 through 5Vdc, programmable thresholds TTL, CMOS, 3.3V

- indicate PULSE activity

- TONE of LOGIC states, so the thing SINGS to ME. Cool.

- a WHITE flashlight that illuminates the PROBE area! when the probe sense OPEN condition.

- Small size fits into pen type probe DIY housings, or DIY 3Dprinter case or aDIY homebuilt case from a highlighter marker pen with contents removed.

Warning

This Instructable Editorial Article is written at the expert career Technician level

and is NOT for intended for learning although it may have useful lesson material.

The use of a Logic Probe, or any Electronics Testing Tools around hazardous voltages

are at the users or readers risk for personal injury.

Acknowledgements

DigiSpark Eric K. at DigiStump

Charlieplexing LEDs , Charlie A.; to use few drive signals to drive more LED indicators

micronucleus bootloader and Arduino OpenSource for their IDE V1.8.8 in which I wrote the code.

DigiSpark AnalogIn issues of pin numbers Digital1 and Analog1 not same pin

Other Authors with deadbug style LM339, Franklin, Volta, Ohm, Faraday, Henry, Kirchhoff, Bell, Edison, Curie, Hertz, Tesla, Braun, Marconi, Fleming, DeForest, Armstrong, but mostly trio Bardeen/Britain/Shockley.

Mom for convincing me that Electronics was a reasonable career choice in 1977, and paid for tuition fees

Step 1: Gather the Components

  • Digispark, Digistump developer board AVR ATTiny85 5Volt, 16MHz , micronucleus bootloader installed,
  • $3 CDN for China 'work-a-likes' (2023 update inflation closer to $5 CDN)
  • four T1-3/4 size LEDs, size & colors are a personal choice
  • three LED drop resistors: 330 Ohms a good compromise on current consumption and brightness
  • angled DuPont header row pins or direct connection with solder, although DuPonts make it easier for replacement. I used five for PB0-PB4 and three angled pin header for +5/G/Vin points.
  • two 1Meg Ohm resistors for the input bias, (~ 2.5 V; ADC read value around 512, to detect OPEN ) in a TEE, the center branch connects to INPUT at PB2, upper branch to +5V, lower branch to GND ground.
  • 100K in series with the input probe wire
  • 1N4007 diode at ground clip input, to prevent 'oops' and 'whoops' damage from probe voltage reversal.
  • optional external power interconnection
  • optional Ground Clip connector, wire , accessory alligator clip
  • case, I used an older tube DIY Oscilloscope probe design from Jameco USA, its about 1" in diameter
  • wires to connect LEDs in charlieplexed connection with enough lead length to stuff 3 LEDs and mounting bezels into the probe tube; creativity is the key,
  • small sounder piezo speaker, passive, and 470 to 2000 Ohm resistor, custom selected for tone volume. 1000 Ohms is ideal and standard value.

Arduino IDE and USB to Micro cable are required for programming , acquired here

Updated in V2: (see last page for details on V2)

  • add 1N5819 Schottky Diode at ATtiny85 pin 2 input to ground in reverse bias for input reverse polarity protection.
  • modify R3, R4, and R5 to 200~220 Ohm for brighter LED's .

Step 2: Connect CharliePlexed LEDS

Here I include a schematic of four LEDS connected to three resistors connected to three Pins of the Digispark at PB1, PB3 and PB4.

I used DuPont prototyping 2.54 connectors and wires, using cut up Female - Female patch cables 10cm long, and soldering, then heat tube shrink insulating the connections. Example of DIY DuPont crimping is here:

https://www.instructables.com/id/Make-a-Good-Dupon...

Update: DuPont connectors are for prototypes; poin to point soldering eliminates the intermittent connections from transport and field use.

I used 330 Ohms in each branch of the CharliePlex method; refer to (https://www.instructables.com/id/Charlieplexing-th... (note: in V2, I changed R3, R4, & R5 to 200~220 Ohms so that I could see the LEDs in bright sunlight)

in those examples, Led2 and Led4 of Tsant's article are not used in my design) for detail.

Refer to this page and the 6LED example

https://electronics.stackexchange.com/questions/75...

and then refer to the modified attached image with four of six LEDs and their orientations.

The second image shows the White TIP flashlight LED in OPEN probe state.

I found that original Digispark with CharliePlex 4 LEDs and Toner draws 50mA in operation ; I performed mods on the board that work, described HERE:

https://digistump.com/wiki/digispark/tricks

Step 3: TESTS

The OPEN state is the quiescent "idle state" of the probe. (no probe connection)

WHITE LED illuminates the probe tip like a flashlight.

Touch the probe to POSITIVE (5V) pin of the Digispark board, and the GREEN LED should illuminate, and sound a 100mS burst of upper tone in the speaker.

Touch the probe to NEGATIVE (GND) and the RED LED should illuminate, and sound a tone in the speaker.

During the transistors from GREEN to RED or vice-versa, the PULSE LED illuminates if the transistion reverses within x time (to be determined, but pulses within 66mS are my objective).

The Image on this page is a standard comparison of Logic family levels.

Step 4: Connect Sounder

The sounder I used was a Piezoelectric passive module better at +2000 Hertz than lower tones.

I also used busted in-ear headphones where one driver is blown out, using the good one.

the reader should hunt around for a sounder or micro speaker that can be heard in close proximity.

The sounder does not have to be too loud; the user is holding the probe in hand, so the users ear is close.

I had to play around with low and high tones, and series resistor value a bit, until I heard the right balance.

I used extra wire length because I know the speaker will have to stuff down far into the probe housing.

Step 5: Internal Probe Circuit Operation, V1 Code

PB2 accepts 0 to 5Vdc from the probe tip through 100K 1/4W 1% metal film resistor in series.

The Digispark converts Analog Voltage to a numerical value ranging from 0 to 1023.

The user can program thresholds with IF statements to perform decisions on which LED to light up, and PULSEIN counting to determine if the signal changes while probing, and signal that condition. I will probably use value of <200 for LOW, 450-550 for OPEN, >800 for HIGH, and 66mS for pulse detection window.

Bonus: Touching PROBE to GND is a nice CONTINUITY DETECTOR, useful for mobile site troubleshooting of cables and wires and cold traces and other tasks where a beeper just injects too much current through the UUT.

The first version of the DigiLogiProbe will only incorporate a fundamental PULSE detect and indicator stretch, old school , like the Global Specialties LP-3 in PULSE mode, for quick one-shot narrow pulse detection, or low rate state changes.

The attached PDF is the schematic for the Probe.

The Arduino IDE "INO" file is pending code updates. [Jan 8]

The following code is for Plain GREEN and RED without PULSE indicator (pending);

//---------------------------------------------------------------------------------------------
// DigiLogiProbe Version 0.1 January 5, 2019 by JRad
// code for Logic Probe on Digispark Micro USB dev board
// 3 state LEDs, High, Pulse, Low, and 4th LED for OPEN
// does not use anyones library nor prior work
// compile & prototype tested on Jan 6, 2019
//----global-variables-------------------------------------------------------------------------
static int probe; //store the ADC value
static int pHL; // store the High to Low value
static int pLH; // store the Low to High value
static int StateChange; // store a flag
//----main-loop--------------------------------------------------------------------------------
void setup()
{
pinMode(0, OUTPUT); //Sounder as output for Tone on PB0
pinMode(1, OUTPUT); //Open LED (onboard as well)
pinMode(2, INPUT); //Probe Input
pinMode(3, OUTPUT); //High LED output
pinMode(4, OUTPUT); //Low LED output
//---------------self-test--------------------
digitalWrite (1,HIGH); // initialize c-plex
digitalWrite (3,HIGH); // "
digitalWrite (4,HIGH); // "
pinMode(3,INPUT);
digitalWrite (4,LOW); // turn on WHITE
tone(0,750,100);
delay(250);
digitalWrite (4,HIGH); // turn OFF WHITE
pinMode(1, INPUT); // I use this method of Hi-Z like a tristate gate output
pinMode(3,OUTPUT);
digitalWrite (3,LOW); // turn ON GREEN
tone(0,900,100);
delay(250);
digitalWrite (3,HIGH); // turn off GREEN
pinMode(1, OUTPUT);
pinMode(3,INPUT);
digitalWrite (1,LOW); // turn on AMBER
tone(0,1200,100);
delay(250);
digitalWrite (3,LOW); // turn off AMBER
pinMode(3,OUTPUT);
pinMode(4,INPUT);
digitalWrite (3,HIGH); // turn ON RED
tone(0,1500,100);
delay(250);
pinMode(4,OUTPUT);
digitalWrite (1,HIGH);

//----------------initialization--------------
noTone(0); // cancel any tone set
// initial output states
digitalWrite(0,LOW);
digitalWrite(1,LOW);
digitalWrite(3,LOW);
digitalWrite(4,LOW);

}

//-----main-loop-------------------------------
void loop()
{
probe = 0; // value reset
probe = analogRead(1); //capture probe reading in 0-1023 value 0~5V
delay(2); // delay because Tone() wont work properly if ADC is still acquiring

if (probe > 650) // detect logic HIGH
// 650= about 3.1V (change it for other threshold)
{
pinMode(1, INPUT);
digitalWrite(3,LOW);
digitalWrite(4,HIGH); // GREEN LED on
pinMode(1, OUTPUT);
tone(0,2800,50);
}

if (probe > 251 && probe < 599) // detect OPEN (White LED)
{
pinMode(3,INPUT);
digitalWrite(1,HIGH);
digitalWrite(4,LOW); // WHITE LED on
pinMode(3,OUTPUT);
}

if (probe < 250) // detect logic LOW
{
pinMode(4, INPUT);
digitalWrite(3,HIGH); // RED LED on
digitalWrite(1,LOW);
pinMode(4, OUTPUT);
tone(0,2200,50);

// eventually, the pulse detector routines go here
// and I will use two void subroutine loops for AMBER with two
// distinct tones for Low-to-high and vice~versa

}
// end loop
}

Step 6: Usage and Test Methods and Safety

  • Do NOT USE THIS PROBE WHILE TETHERED TO USB POWER. The clones have a weak Schottky diode, and the probe potential just a smidge under or over 0-5V creates a differential at the USB. The USB port also interferes with C-plexing. The original boards also see ground and probe tip potentials despite documentation to indicate high-Z (BS.). Using the board with 9V battery is good.
  • Keep your eyes on the board; at lot of errors and tech faults come from dragging a probe across traces that were not meant to be 'bridged'. This is hard to do because you may be looking up at the O'scope, etc
  • Obviously, even if the Power Supply says Digital Switching, obviously, a logic probe is intended for logic tracingand not for tracing or testing Switchmode Power Supplies operating at very high voltages, even on the LV side.
  • remember to wear proper tethered ESD protection at the Bench.
  • The ground may be at a potential, and the probe cannot tell you that; be continually suspicious and question everything about your UUT. and...
  • Remember the words of the wiser Electronics Teacher;if you assume, you are making an ASS out of YOU and ME.

Step 7: Request for Comment

Comments that I seek;

  • methods to economize on current consumption of V-IN pinrunning on 9V: not really an issue if you have a battery power switch
  • CASE DIYPlumbing PVC tube works well
  • any Fork of design you plan that has good idea or method

Note: Negative input warning will be implemented in V3, flashing RED (2Hz) if input is > -0.5V w.r.t. ground return... using PB5 as input for this . uses external Transistor to pull up PB5 from 3.3V to 5 and PB5 as input!

Step 8: 20 February 2023 (Four Year Update)

I attached the Version 2 code on this page. No Libraries needed to install. The code does not alter the Micronucleus Bootloader and avoids PB5 RESET pin. It is simply a self-powered, reprogrammable Logic Probe. *Do*not*use*for*testing*while*tethered_and_powered with*USB*cable* (Ground of USB is directly connected to Ground of Probe and therefore to D.u.T. !). My case allows the microUSB jack to be accessed by a hole in the top of the probe case. Refer to new images attached.

Added PULSE LED function: flash the PULSE AMBER LED if the input transits from High to Low or vice-versa. The delay is about 50mS; useful enough to find a clocking or sync circuit.

Added one reverse polarity protection Schottky Diode from the (Analog, PB2) input to ground return. The reverse biased Schottky in combo with the 100K Ohm series resistor allows the probe to withstand -20 Vdc for brief periods. A version 3 of hardware is planned for the probe to detect >0.5Vdc (the ATtiny85 specification limit) and flash the RED as warning.

Modified three resistor values in the 'charlieplexed LED array) to 200 Ohms (from 330) to enhance the LED brightness so that the tool can be used in bright sunlight under the Hood of my 22yr old Honda Civic. The White LED at the tip of of probe is really helpful while I am under the dashboard.

The V2 code has enhanced commentary to explain the steps.

I have constructed three probes and I have been using them for Four years since the first Version was published. I had modified code in 2020 to detect pulse but neglected to update this instructable.

PENDING: PDF of V2 schematic.

some Specifications

  • Intended measure range: 0 - 15 VDC ( tested at 20VDC w/o defect )
  • Input Z impedance: ~ 1.12 MOhms (tested with Keithley, powered OFF)
  • Input current sourced: ~ 3.0 uA
  • Input Voltage: ~ 1.75-1.85 VDC (tested open, 9V0 battery, ON)
  • operational current: from 15mA open to 40mA (PULSED)
  • (accidental) reverse polarity at input: withstands 2 seconds @ -20 Vdc (Tested in 5 reps)

*notes: Schottky diodes[1N5819] should have a reverse blocking up to 28 VDC. Clones may do not! have this protection; you can see VIN pad goes directly to the 78L05 at its VIN, so *add* another 1N5819 Schottky in series with any external power clips if you do not use a 9V local battery, as in a traditional Logic Probe design. The anode always faces Vin (+). Although Digispark brags that the 78L05 can withstand 35VDC power in, it will get super hot, and the maximum suggested limit should be 28V on power.