Author Topic: DIY through-hole multimeter project  (Read 21588 times)

0 Members and 2 Guests are viewing this topic.

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #25 on: November 15, 2016, 03:40:33 pm »
The PSU and Reference design is updated. I wonder if the split supply for digital and analog sections are necessary though, and I am not sure if it is necessary to heatsink the regulators.
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #26 on: November 15, 2016, 05:08:24 pm »
With the ICL7135 there is no need for isolated analog and digital part. The digital part is just slow clocked, maybe even static logic to do range selection. Even if using a µC, this could be low noise, e.g. sleep mode most of the time. Isolating the LEDs would be rather high effort. So it is more about making the digital part low noise.

However if an external supply like USB or a wall-wart is used, there needs to be an insulation, so that the supply has no direct connection to meter inputs. The obvious way would be something like a Royer-converter (especially if you want it old style).

Whether the regulators need heat-sinks is one of the last points to look at. First one needs the general design. The regulator for the LED current might need a heat sink - the other regulators likely not, but it depends. Usually the only part that really needs significant power should be the LEDs.

The simple version would use something like the +-5 volts supply of the ICL7135 for everything. So the input range in limited to about +-4.5 V or so, which is just good enough for a 2 V AC range (which has about 2.8 V peak with sine). With just a 2 V input range one might need more than just a 1:100 divider. In this case the CD405x could be used for gain switching, and an AZ OP like ICL7650 could be used for the (DC voltage) input amplifier. With limited bandwidth it could even work for AC too.
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 17214
  • Country: us
  • DavidH
Re: DIY through-hole multimeter project
« Reply #27 on: November 15, 2016, 05:52:22 pm »
With the ICL7135 there is no need for isolated analog and digital part. The digital part is just slow clocked, maybe even static logic to do range selection. Even if using a µC, this could be low noise, e.g. sleep mode most of the time. Isolating the LEDs would be rather high effort. So it is more about making the digital part low noise.

I have actually had problems with this with certain frequency counters where the spikes in the LED drive current got into the counter chain.

For my own designs, I do not isolate the LED from the microcontroller unless I have to but I have used a separate low voltage floating supply attached to minimize the loop length which in this case is between the external anode drivers and 7-segment decoder/driver so modulation of the power supply does not get into sensitive circuitry.
 

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #28 on: November 15, 2016, 06:36:14 pm »
With the ICL7135 there is no need for isolated analog and digital part. The digital part is just slow clocked, maybe even static logic to do range selection. Even if using a µC, this could be low noise, e.g. sleep mode most of the time. Isolating the LEDs would be rather high effort. So it is more about making the digital part low noise.

However if an external supply like USB or a wall-wart is used, there needs to be an insulation, so that the supply has no direct connection to meter inputs. The obvious way would be something like a Royer-converter (especially if you want it old style).

Whether the regulators need heat-sinks is one of the last points to look at. First one needs the general design. The regulator for the LED current might need a heat sink - the other regulators likely not, but it depends. Usually the only part that really needs significant power should be the LEDs.

The simple version would use something like the +-5 volts supply of the ICL7135 for everything. So the input range in limited to about +-4.5 V or so, which is just good enough for a 2 V AC range (which has about 2.8 V peak with sine). With just a 2 V input range one might need more than just a 1:100 divider. In this case the CD405x could be used for gain switching, and an AZ OP like ICL7650 could be used for the (DC voltage) input amplifier. With limited bandwidth it could even work for AC too.

I do anticipate high current draw from the LEDs and the CD4060 clock generator, the multitude of ATF16V8 (as I implemented most of the glue logic, as well as the entire autoranging mechanism using those) also hogs current, so I gave digital circuitry a standalone power rail from a switch-mode power supply. I just plan to heatsink all five power components just to avoid potential accidents.

The +/- 12V is pretty much used only by the LM399 reference and the ohms range constant current generator though.
 

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #29 on: November 15, 2016, 06:44:48 pm »
I was looking around for a possible range switching mechanism but I found none. However this idea caught my eye:

There are push buttons with built-in LEDs and panel-mount LEDs, and maybe I can implement the range switching using those backlit buttons, LEDs and a few GALs. How do you think about this layout:

micro-voltLow impedence volts
milli-ampDiode drop
kilo-ohmESR
mega-OverloadHold

The prefixes and Overload are LEDs, while the remaining are backlit buttons.
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #30 on: November 15, 2016, 07:30:14 pm »
If the higher supply voltage is needed only for low currents (like the lm399 and ohms source), one could use a lower voltage transformer (e.g. 8 V) suitable for the 5 V supply and create the +12 V or maybe +20 V with a charge pump. This way one should get away without a switched mode regulator.
My guess is a +15 V and +-5 V supply could be enough. Separate linear regulators for the 5 V LEDs and logic and the ADC/amps are still possible.

For more functions, I would prefer an µC over several GALs. At something like 50 mA per chip they are just to power hungry to use more than one or maybe two.
 

Offline AlxDroidDev

  • Frequent Contributor
  • **
  • Posts: 471
  • Country: br
    • Arduino Web Brasil
Re: DIY through-hole multimeter project
« Reply #31 on: November 16, 2016, 12:03:43 am »
I like this project and I have one ICL7135 on hand.


For reference voltage, I don't have a LM399, but I do have a MAX6126 (SOT-8), which might fit the bill. For uC I have a few Atmega168, 328 and 1284 and one DS89C450, all of them PDIP.

"The nice thing about standards is that you have so many to choose from." (Andrew S. Tanenbaum)
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #32 on: November 18, 2016, 10:01:19 pm »
For the usual +-2 V range the ICL7135 needs a 1 V reference. No real need for an LM399. The MAX6126 is definitely good enough. One could even go for something simpler, like LT1009.

For controlling automatic range switching a simple µC should be good enough, no need for something fancy. The ADC in the µC could be very handy to do range selection based on peak values. So the AVR Mega168 is well good enough. With a display oriented ADC and thus analog trimming one might not want that many ranges / functions anyway, as one would need a multi turn trimmer for essentially every range. Adjustment thus takes quite some time and a suitable calibration source. To ease this a little one might use each shunt for a 1:100 range and use switchable amplification of 1/10 (used for the voltage anyway). This would half the number of shunts to adjust, which is a little difficult anyway. With a good (AZ) amplifier a 20 mV burden could be enough. This would require 1 µV resolution for the shunts - not easy but possible.

One should be able to separate the project in the ADC + display part and the input stages and µC. Not many lines between those two and the ADC has differential inputs - thus no need for a common GND level separate GND lines.
 

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #33 on: November 19, 2016, 05:43:50 am »
For the usual +-2 V range the ICL7135 needs a 1 V reference. No real need for an LM399. The MAX6126 is definitely good enough. One could even go for something simpler, like LT1009.

For controlling automatic range switching a simple µC should be good enough, no need for something fancy. The ADC in the µC could be very handy to do range selection based on peak values. So the AVR Mega168 is well good enough. With a display oriented ADC and thus analog trimming one might not want that many ranges / functions anyway, as one would need a multi turn trimmer for essentially every range. Adjustment thus takes quite some time and a suitable calibration source. To ease this a little one might use each shunt for a 1:100 range and use switchable amplification of 1/10 (used for the voltage anyway). This would half the number of shunts to adjust, which is a little difficult anyway. With a good (AZ) amplifier a 20 mV burden could be enough. This would require 1 µV resolution for the shunts - not easy but possible.

One should be able to separate the project in the ADC + display part and the input stages and µC. Not many lines between those two and the ADC has differential inputs - thus no need for a common GND level separate GND lines.

I am just wondering, if I am using the uC-driven form (I will probably use something like ATmega328P or even ATmega32) can I put a MCP41010 somewhere in the chain, use this d-pot as the tuning pot, and store tuning factors in the uC?
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #34 on: November 19, 2016, 08:06:35 am »
One could use a µC and digital pot / DAC to do calibration in software. Doing a small adjustment of the reference voltage divider would be the obvious point, especially if the ref chip is 5 V or less. The ref input is high impedance and the reference is needed only relatively late in the process, so there would not be much delay on range switching.
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 17214
  • Country: us
  • DavidH
Re: DIY through-hole multimeter project
« Reply #35 on: November 19, 2016, 08:45:28 am »
With a display oriented ADC and thus analog trimming one might not want that many ranges / functions anyway, as one would need a multi turn trimmer for essentially every range.

None of my display oriented DMMs have a trimmer for each range.  For DC volts, at most they have an adjustment for the 2VDC range and the 200mVDC range if that is done by reducing the reference voltage to 1/10th.  A set of precision resistors is used to make the 10M decade divider which is one of the few specialty parts you can actually buy:

http://www.mouser.com/Passive-Components/Resistors/Resistor-Networks-Arrays/_/N-e89lZscv7?Keyword=decade&Ns=Pricing%7c0&FS=True

Through clever switching, the same decade resistor network can be used by the current source for the ohms converter so there is only one adjustment there.
« Last Edit: November 19, 2016, 08:54:02 am by David Hess »
 

Offline dardosordi

  • Regular Contributor
  • *
  • Posts: 85
  • Country: ar
Re: DIY through-hole multimeter project
« Reply #36 on: November 19, 2016, 04:25:46 pm »
I like this proyect. I once started doing a similar design trying to use only the parts in my drawer.

A very good source of inspiration is the service manual for the Hameg 8012 http://frankshospitalworkshop.com/equipment/documents/workshop_equipment/manuals/Hameg%20HM8012%20Multimeter%20-%20Service%20manual.pdf
 

Offline dardosordi

  • Regular Contributor
  • *
  • Posts: 85
  • Country: ar
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 17214
  • Country: us
  • DavidH
Re: DIY through-hole multimeter project
« Reply #38 on: November 20, 2016, 12:56:35 am »
There are lots of old and fully documented digital multimeter designs.  The Tektronix DM501, DM501A, DM502, DM502A, and 7D13 come to mind and I suspect HP has a bunch from the 1970 to 1990 as well.  The Tektronix ones have great theory sections explaining their operation at the circuit level but the designs include a massive number of mechanical switches except for maybe the DM502A which has automatic ranging.
 

Offline dardosordi

  • Regular Contributor
  • *
  • Posts: 85
  • Country: ar
Re: DIY through-hole multimeter project
« Reply #39 on: November 20, 2016, 03:24:06 am »
Are those Tek DMM based on ICL7135 ? The hamegs are, so thats why I like them.
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 17214
  • Country: us
  • DavidH
Re: DIY through-hole multimeter project
« Reply #40 on: November 20, 2016, 07:24:45 am »
Are those Tek DMM based on ICL7135 ? The hamegs are, so thats why I like them.

I think the ICL7000 series came later.  The DM501 uses the Fairchild 3814 and a discrete integrator, the 7D13 is a fully custom design, and the others use the Siliconix LD120/LD121A and LD111A/LD110 which might be considered more advanced than the ICL7000 series.

None of these ADCs have been in production for a long time so I do not recommend building anything based on them.  However the input signal conditioning circuits for current and ohms and AC measurements apply to an ICL7135 based design.
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #41 on: November 20, 2016, 09:52:23 am »
The Hameg 8012 is also not based on the ICL7135, but uses an sigma-delta ADC (LTC2400) and µC. So not more analog calibration and direct ADC step to display step connection. The input stage is still similar, but with one important difference so it can not be directly copied as it includes an auto zero step. But one could still use the concept of using only one divider for higher voltages and variable amplification and attenuation behind the input amplifier.

Those meters use very low tolerance resistors instead of adjustment. Depending on the circuit they can use the 1:10 amplification step for more than one range. So the number of critical resistors / adjustments can be reduced a little.


 

Offline dardosordi

  • Regular Contributor
  • *
  • Posts: 85
  • Country: ar
Re: DIY through-hole multimeter project
« Reply #42 on: November 21, 2016, 03:11:27 am »
You are right, HM8012 deos not use the ICL7135 is the HM3011. I have both manuals printed and got them mixed  |O
 

Offline dardosordi

  • Regular Contributor
  • *
  • Posts: 85
  • Country: ar
Re: DIY through-hole multimeter project
« Reply #43 on: November 21, 2016, 03:15:19 am »
 Technix keep us posted, looking forward to see your progress. Thanks for sharing!
 

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #44 on: November 21, 2016, 09:20:39 am »
Since it is a common suggestion to use some microcontroller involvement, how about this idea:

* Emit the 100kHz reference clock from the microcontroller
* Use the microcontroller to switch ranges
* Use DACs and digital pots to calibrate the circuit digitally

Delta-Sigma ADC is still out of the scope as I still don't want to touch SMT on this design.

About the choice of the microcontroller, which one seemed better? I am relaxing the MCU selection from AT89C2051-only:

* AT89C2051-24PI @ 24MHz (12T 8051 architecture)
* IAP15F2K61S2-35I-SKDIP28 @ 30MHz (1T 8051 architecture, built-in SPI master hardware for DAC)
* IAP15W4K61S4-30I-PDIP40 @ 30MHz
* ATmega328P-20PU @ 16MHz (AVR - Arduino, we all know it)
* PIC18F45K20-I/P @ 64MHz (3.3V PIC)
* PIC18F4550-I/P @ 64MHz (3.3V PIC with USB)

If a 40-pin MCU is used, maybe I will also move the display decoding and driving into the MCU, and simplify the display board into a MAX7219-driven one, or a HD44780-based display module.
« Last Edit: November 21, 2016, 09:31:44 am by technix »
 

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #45 on: November 21, 2016, 11:25:54 am »
I am currently working with the IAP15F2K61S2-35I-SKDIP28 as the MCU. Made in China chip and super cheap.

Here is the timing code. I am using a 30MHz crystal on the 8051-based processor. This timing code uses Timer 0 for both millis() and emitting the 100kHz clock to the ADC.

Code: [Select]
void systick_init(void)
{
// To emit a 100kHz clock, the timer should overflow at 200kHz, driving the
// T0CKO (P3.5) pin.

unsigned long count;

// P3.5: push-pull output.
P3M0 |= 0x10;
P3M1 &= ~0x10;

TMOD = TMOD & 0xf0; // Timer 0: 16-bit autoreload timer.
AUXR |= 0x80; // Run the timer at F_CPU

count = 65535 - F_CPU / 2 / 100000UL + 1; // The overflow rate is calculated.
TL0 = count;
TH0 = count >> 8;

TF0 = 0; // Start the counter
TR0 = 1;

INT_CLKO |= 0x01; // Start the clock output

ET0 = 1; // Start interrupts.
}

IAP15F2K61S2 have built in 8-bit ADC, which may be used as internal calibration points?
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #46 on: November 21, 2016, 06:24:17 pm »
The µC does not have to do very much. So anything capable of creating the clock, a better than 5 Bit ADC and some IOs should be fine. Using the µC to do the display decoding is a little strange, but possible. So any of the listed µC should be fine and even simper ones (like Mega88, PIC16, maybe PIC12) should be good enough.  An integrated DAC could be used for fine adjustment, but an external one is possible too. I would somewhat prefer 5 V operation as the ICL7135 usually is 5 V supply.

There is little use for an µC integrated USB interface, as this would not be isolated from the meter circuit. If wanted, a PC interface would be more practical by an UART output from the µc and than via opto-coupler to an UART to USB chip (powered over USB). This could be an later option if the UART pins are left accessible.

The internal ADC would be more for auto-ranging, e.g. measure the approximate positive and negative peak voltages to detect possible clipping. So no high accuracy needed, but 2 or 3 input would be nice. Comparators would also work - but an ADC might be easier.

No need to run the µC fast. Something like a 1 or 4 MHz clock should be OK. One may not even need a crystal, as the power grid frequency is not that stable anymore - at least in Europe.
 

Offline technixTopic starter

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: DIY through-hole multimeter project
« Reply #47 on: November 21, 2016, 07:08:08 pm »
The µC does not have to do very much. So anything capable of creating the clock, a better than 5 Bit ADC and some IOs should be fine. Using the µC to do the display decoding is a little strange, but possible. So any of the listed µC should be fine and even simper ones (like Mega88, PIC16, maybe PIC12) should be good enough.  An integrated DAC could be used for fine adjustment, but an external one is possible too. I would somewhat prefer 5 V operation as the ICL7135 usually is 5 V supply.

There is little use for an µC integrated USB interface, as this would not be isolated from the meter circuit. If wanted, a PC interface would be more practical by an UART output from the µc and than via opto-coupler to an UART to USB chip (powered over USB). This could be an later option if the UART pins are left accessible.

The internal ADC would be more for auto-ranging, e.g. measure the approximate positive and negative peak voltages to detect possible clipping. So no high accuracy needed, but 2 or 3 input would be nice. Comparators would also work - but an ADC might be easier.

No need to run the µC fast. Something like a 1 or 4 MHz clock should be OK. One may not even need a crystal, as the power grid frequency is not that stable anymore - at least in Europe.

I just defaulted to some of my common experimenting clock frequencies there, and some of my existing code assumes that frequency (16MHz on AVR or PIC16, 24MHz on classic 8051, 30MHz on STC15 8051 or 64MHz on PIC18). Since the uC is not doing much, I will probably stick with IAP15F2K61S2-35I-SKDIP28 @ 30MHz. Reusing existing code means I don't have to write everything from scratch.

Using the uC to intercept the display signal is to allow it to be reinterpreted. The intercepted signal can be sent over serial port to a computer for datalogging (and I may just go ahead and implement SCPI) and I don't have to stick to LED as HD44780-based display can also work. Although if there exists a high-precision Delta-Sigma in DIP package I may even scrap ICL7135 in favor of that.

I think I will still tuck a non-isolated serial or USB port on the board somewhere (not accessible from the outside) to function as a program/debug port. STC15 MCU uses serial port for ICSP and for the specific chip I chose, IAP15F2K61S2, it also supports on-chip debugging through the same serial port, independent of the actual serial port hardware.
« Last Edit: November 21, 2016, 07:11:31 pm by technix »
 

Offline Kleinstein

  • Super Contributor
  • ***
  • Posts: 14859
  • Country: de
Re: DIY through-hole multimeter project
« Reply #48 on: November 21, 2016, 09:15:36 pm »
AFAIK there is a way to read the ICL7135 by reading the sign, a sync signal and let the µC count pulses instead of reading the BCD values. This needs less pins on the µC. Still there is not that much room for interpretation for the µC on the ADC data. At most may be scaling with 2 to allow a +-4 V range (last digit always even).

One advantage of using an SD converter and µC for scaling would be that one is not bound to the 19999 count ranges. So one could have ranges to maybe 4 V or so which would be about the limits for an ICL7650 amplifier (one of the few available AZ OPs in DIP) for the input.

I don't know sigma delta converters in THT case. But there are a few in SMT that are still relatively easy to solder. Something like SOT23-6 or SO-8 are still relatively easy and may go to a small adapter board.
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 17214
  • Country: us
  • DavidH
Re: DIY through-hole multimeter project
« Reply #49 on: November 21, 2016, 10:45:40 pm »
Although if there exists a high-precision Delta-Sigma in DIP package I may even scrap ICL7135 in favor of that.

If there were any through hole delta-sigma converters, they are long gone and honestly I do not consider using an SO (small outline) part on a DIP adapter to be cheating as long as it is a unique part; everything except that may be available in DIP packages.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf