Showing posts with label LED. Show all posts
Showing posts with label LED. Show all posts

Wednesday, October 4, 2017

LCR-T4 Mega328 Component Tester



LCR-T4 Component Tester


I recently picked up an LCR-T4 Component Tester from E-Bay. I've had my eye on these for a while and for AUD12 (including the acrylic case), I thought it was worth giving one a try. There are LOTS of different versions out there.



So what does it do?

Well it measures components, including resistors (and potentiometers), inductors, capacitors, diodes, dual diodes , transistors (including MOS), SCR's, regulators, LED's, and even ESR.

Photo Credit: EEVBlog


The claimed accuracy is:

Resistance: 0.1 ohm resolution, maximum 50M ohm
Capacitor: 25pf -100,000 uf
Inductors: 0.01mh-20H

These are probably a touch optimistic but for picking out components, the accuracy is adequate.

Photo Credit: EEVBlog

This unit apparently comes with the 2013 M328 version of the software and includes a 128*64 backlit LCD display, which uses about 2mA in stand by. As you can see in the image above, the unit will automatically identify and tell you which pin is the BCE for a transistor, not to mention the gain and forward voltage - nice! One of the features is automated detection of pin assignment, which means the device can be connected to the tester in any order. You can only use pins 1,2,3 of the DIL socket.

The open source firmware and hardware design is based on the work of a couple of German dudes. If you were brave you could flash the firmware to the latest version.

Case Construction





Building the case is fairly simple. What takes the longest is peeling the paper from the laser cut acrylic sheets! Proceed as follows:

  1. Peel the paper from the acrylic (both sides).
  2. Mount the PCB on the base plate using the four smaller bolts and the spacers (see photos below). You may want to pass the battery cable under the PCB, but it isn't compulsory.
  3. Insert the side panels into the base, starting with the top one as it has the tightest fit against the screen ribbon cable.
  4. Snap the top plate in place, it will only fit one way. This should hold things in place while inserting the 4 long bolts and nuts which hold everything together. Done!






What Manual?


The first trick is to make sure that you use a fresh 9V battery, if you don't then the display will be unreadable.

Operation is pretty straight forward. Just plug the component that you want to test into pins 1, 2 or 3 on either side of the DIL socket, then press the blue test button. The unit turns itself off after displaying the results for 10 seconds. If you have surface mount components, you can use the pads on the PCB labelled 1, 2 and 3 instead of the DIL socket.

The unit will automatically detect NPN & PNP transistors, N- and P-channel MOSFETs, JFETs, diodes, small thyristors, and TRIACs. It will measure hFE and base-emitter-voltage for bipolar junction transistors (e.g. Darlingtons).

Up to two resistors can be measured with a resolution down to 0.1 ohm. The measurement range is up to 50 Mohm (Megaohm). Resistors below 10 ohms will be measured with the ESR and a resolution of 0.01 ohm. Note that resolution is not equivalent to accuracy.

Capacitors in the range 35pF (picofarad) to 100mF (millifarad) can be measured with a resolution down to 1 pF. Inductances of 0.01 mH to 20 H can be detected and measured.

The short video below shows an LED being tested.




Friday, December 25, 2015

Robot Christmas

AVA Disco Mode


The robot received a set of Ikea Dioder LED strips for Christmas. Below is a quick video of AVA in disco mode. There will be a separate post on controlling these strips using an Arduino at some stage.




AVA Christmas


In keeping with the Christmas theme here is AVA singing a Christmas Carol using the EMIC 2 Speech Synthesizer. The Emic 2 Text-to-Speech Module is a multi-language voice synthesizer that converts a stream of digital text into speech. You can select either the Epson (default) or DECtalk parsers.


Note that the Emic 2 uses DECtalk version 5.0.E1. The Flame of Hope web site has a heap of DECtalk songs but they are for earlier versions of the DECtalk parser and require tweaking to work with the EMIC 2. Thanks to Ron on the Parallax forum for these tips on converting the text files:

  • you often have to change an "L" to "LL"
  • sometimes you need a space between any character preceding the "ey" phonetic symbol.

The following is the string used to produce the song in the video above, should you wish to try out your EMIC 2's singing ability.


"[:phone arpa speak on][:rate 190][:n2][:dv ap 200 sm 100 ri 100][R EY<200,17>N<100>DRAO<200,24>PS<100>AO<200>N<100>ROW<300,19>ZIX<200,17>Z<100>AE<150>N<100>D<50>WIH<300,12>SKRR<200,17>Z<100>AO<200>N<100>KIH<300,19>TAH<150,17>N<100>Z<50>_<300>BRAY<200>T<100>KAO<300,24>PRR<300>K EH<300,19>TEL<200,17>Z<100>AE<150>N<100>D<50>War<200,12>M<100>WUH<300,17>LL EH<200>N<100>MIH<300,19>TAH<150,17>N<100>Z<50>_<300>BRAW<200>N<100>PEY<300,24>PRR<300,22>PAE<300,17>KIH<300,19>JHIX<200,15>Z<100>TAY<200>D<100>AH<200,22>P<100>WIH<200,20>TH<100>STRIH<300,13>NX<200>Z<100>_<300>DHIY<200,12>Z<100>AR<300,13>AX<300,15>FYU<300,17>AH<200,18>V<100>MAY<300,20>FEY<300,22>VRR<300,24>EH<200,22>T<100>THIH<500,16>NX<300>Z<100>][:n0]"


Arduino Code



To make it easy for our Arduino Mega 2650 to communicate with the EMIC2 we created a library called synthesizer.h. As you can see the Arduino connects to the EMIC 2 via one of its serial ports.



To use this class, I have created a robot class which looks like:



Then in the main.ino file all you need to do is:



You don't have to use C++ classes like I did but it makes it easier to maintain your code. You can also ignore the bits which refer to the motors and other sensors, I just leave it in here for completeness.


Tuesday, November 24, 2015

Voice Display Board Completed

1.0 Recap


In a couple of earlier posts we described the design and construction of a voice display and driver board which would emulate that used by Kitt in the Knight Rider TV show. This has now been completed and mounted on AVA.



When we connected the voice display unit to the EMIC 2 Speech Synthesizer which AVA uses to talk, we discovered a problem. The display was driven hard on, even when AVA was silent. A quick measure with the multimeter showed that the EMIC 2 has a constant 2.4 VDC offset. As discussed in the earlier post, the LM3915 displays full scale at 1.25 V, so that was why all the LED's were on.

This is not unusual and a lot of the Arduino MP3 shields do the same thing. Unfortunately when we were testing the prototype, the EMIC 2 hadn't arrived from the USA so I tested using the piezo analog output on the Arduino (which doesn't have a DC offset).

2.0 High Pass Filter


There are a number of ways that you can remove the DC component of a signal, so that you are just left with the AC component. You could use an isolation transformer, but we didn't have one in the spare parts bucket. We did have a heap of resistors and capacitors so we decided to try a high pass filter.

A high pass filter, as the name suggests, passes signals above a selected cut-off point, ƒc eliminating any low frequency signals from the waveform. The circuit for a first order high pass filter looks like the following.

It delivers a response curve (courtesy of http://www.electronics-tutorials.ws/filter/filter_3.html):


It is generally accepted that the range of frequencies audible to humans is 20Hz to 20kHz. Consequently we will design our HP filter with an fc of 20Hz. The formula to calculate fc for a first order high pass filter is:


You can pick two variables and solve for the third, or you can go to an online filter design calculator, and let it do the hard work for you.

We selected an fc of 20Hz and a capacitor of 0.01uF (because we had one of this value), and the design site spat out a resistor value of 820k. If you plug in these values into the formula above you will get an fc of 19.4 Hz which is fine. The filter design site will even plot frequency and transient analysis graphs for you.



3.0 Conclusion


Adding the high pass filter between the EMIC 2 Speech Synthesizer and the voice display module did the trick. It removed the DC bias and allowed the speech signal to pass through. Here is a video of AVA speaking with the voice display module installed.