Seriously – don’t buy a cheap plugpack…
Hello readers
Instead of a normal day involving fun and learning with electronics, I got the scare of my life and a very sore back. You’re probably thinking it was something to do with the bedroom, but (un)fortunately no. It was revenge of the cheap plug pack. (In Australia we call wall warts plug packs).
In the recent past I wrote about a couple of cheap plug packs from eBay – here. Foolishly I kept using the other working plug pack. Not any more!
Consider this photo:
Notice how there is the adaptor with the Australia pins – this slides on and off relatively easily. Today I went to unplug the whole thing, by gripping the small adaptor which would pull the lot out at once. However my grip was not strong enough and my fingers slipped, pushed down and pulled at the plugpack itself – just enough to leave a gap and the pins exposed. (see below) At which point my fingers slipped and grabbed the live pins.
Although I consider myself to be a large physical specimen (185cm tall, 120kg) the shock was amazing (in a bad way). I fell arse over and ended up flat on the floor, and some strange feelings in my chest. After a few moments I sat up and had a walk around. Luckily my doctor is only ten minutes walk away so she gave me a once-over and told me to relax for the rest of the day.
So – the morals of today’s story:
One – don’t cut corners on safety by using substandard equipment
Two – no matter how familiar you are with electronics or electrical work – ELECTRICITY CAN KILL YOU!
Three – always see a doctor, even for the slightest shock.
If you have a tale of woe to share, please leave a comment below or in our Google Group.
As always, thank you for reading and I look forward to your comments and so on. Please subscribe using one of the methods at the top-right of this web page to receive updates on new posts.
Otherwise, have fun, be good to each other, stay safe – and make something!
Let’s make a cheap +5V power supply
In this tutorial we make a simple 5V DC power supply from initial idea to finished product. This is not an exercise in making a flash power supply, just solving a problem with the parts at hand.
Updated 18/03/2013
When writing my Arduino tutorials, or generally experimenting with the breadboards – and more often both – I have needed 5V DC to power something, or in the case of working with two Arduinos at once, having to run USB cables all around the place just to power them. Some may say “Oh, just get another couple of wall warts/plug packs”. True, but good ones are over Au$20 here… and buying cheap ones have not been so successful in the past. However, I do have a collection of odd-voltage plug packs from old cordless phones and so on.. 12V AC, 15V DC etc.
So while at my desk I thought “How can I combine my need for 5V, my cheapness and use one of these plugpacks?”. Easy!
After perusing my stock database it turned out that all the parts were already around me to make a simple 5V supply using an LM7805 voltage regulator. It is quite versatile, can accept voltages up to 35V, and I have some in the drawer. Here is the data sheet: LM7805.pdf.
One should keep in mind the possible current draw from the device this is powering. The LM7805 is good for one amp, so if you’re going to milk it to the limit, your power supply should be good for around 1.5A.
Following this it occurred to me that it would be nice to not have to worry about the type of current from the plug pack – AC or DC. So my circuit needs a bridge rectifier. That can be made with four 1N4004 diodes. And it would be nice to have a power-on indicator that isn’t a tiny speck of light. Thankfully I bought some 20 mm red LEDs when element14 had a crazy sale. Perfect.
And finally, a nice enclosure. Or anything really, to hold it all together. A small semi-opaque jiffy box was hiding in the cupboard with some veroboard, so they will be used. How? Here is my schematic: (click to enlarge)
Oh – the resistor is 560 ohms. And here are the participants in this project:
The black stuff at the top-right is heatshrink. The next though was how to mount the board in the box – I don’t have any standoffs, but the box does have some slots to hold the board. So this tells me how much space there is to use on the board, as I will trim it down to fit the space available:
But before hacking things up with the tinsnips, it pays to see if your circuit will actually fit in the board space available. (However my circuit was quite small, so I knew it would fit). This can be done by laying out your parts on a sheet of paper that has a grid of dots at 2.54mm intervals. Next was to measure the internal dimensions of the box in order to cut the veroboard. Then out with the tinsnips and chop chop chop. When using tinsnips or a saw of some sort, try and cut a little outside of the line – as the PCB material does flex a little .This means that you may lose 2~3 mm at the edges, so make allowances for that.
Moving on, I now have the board sized for the box and can start component placement:
The parts just fit in together nicely. I will have to drill the holes for the 7805 regulator so it can fit, however it doesn’t really leave room for the 0.1uF capacitor. However it is not really necessary, the output will be ok without it. The leads from the power socket, and to the switch and output lead will feed from the bottom of the PCB.
Now for one final visual check, and then to solder in the components.
After doing so, then it was time to put the link in and cut the tracks. I use a sanding bit on the drill to cut the tracks, completely removing the copper.
After cutting the tracks on the solder side, it was a good time to use the continuity function of the multimeter to check for shorts between tracks and other errors. The soldering proved to be fine, and the track cuts worked. Now it was time to position the DC socket and switch in order to wire them in, then drill their holes. The output wire is to come out of the top:
Now all there is to do is solder the connecting wires from the DC socket to the rear of the circuit board, and the output wire via the switch. At this point the unit was also tested. Naturally my eyesight had failed me and a short had appeared. However it was sorted out with the solder sucker:
Notice how I tied a knot in the output lead before it passes through the lid – this is to stop accidental damage to the board caused by someone pulling the wire out. Here is the finished product, with a nice red glow for a power-available indicator:
Hooray – finished. What else was there to do on a Tuesday night? The LED indicates power is supplied to the box, and the switch just controls the load. Not too happy about that 5.05V reading… but then again, that meter was somewhat inexpensive. Now let’s have a look at the CRO and look for any ripple from the supply:
The display was set to 50 millivolts per vertical division – and still a nice solid line. Considering the cost of the power supply, that’s not too bad. And we didn’t need the extra smoothing capacitor after all.
In the meanwhile have fun and keep checking into tronixstuff.com. Why not follow things on twitter, Google+, subscribe for email updates or RSS using the links on the right-hand column? And join our friendly Google Group – dedicated to the projects and related items on this website. Sign up – it’s free, helpful to each other – and we can all learn something.
Let’s make an Arduino real time clock shield
[Updated 15/03/2013]
Today we are going to make a real time clock Arduino shield. Doing so will give you a simple way of adding … real time capability to your projects such as time, date, alarms and so on. We will use the inexpensive Maxim DS1307 real-time clock IC.
First of all, we need create our circuit diagram. Thankfully the Maxim DS1307 data sheet [pdf] has this basics laid out on page one. From examining a DS1307 board used in the past, the pull-up resistors used were 10k ohm metal films, so I’m sticking with that value. The crystal to use is 32.768 kHz, and thankfully Maxim have written about that as well in their application notes [pdf], even specifying which model to use. Phew!
So here is the circuit diagram we will follow (click on it to enlarge):
Which gives us the following shopping list:
- One arduino protoshield pack. I like the yellow ones from Freetronics
- X1 – 32.768 kHz crystal – Citizen America part CFS206. You should probably order a few of these, I broke my first one very quickly…
- IC1 – Maxim DS1307 real time clock IC
- 8-pin IC socket
- CR2032 3v battery
- CR2032 PCB mount socket
- R1~R3 – 10k ohm metal film resistors
- C1 – 0.1 uF ceramic capacitor
And here are our parts, ready for action:
The first thing to do is create the circuit on a solderless breadboard. It is much easier to troubleshoot possible issues before soldering the circuit together. Here is the messy test:
Messy or not, it worked. You can use the following sketch to test the circuit is working.
The next step is to consider the component placement and wiring for the protoshield. Please note that my board will most likely be different to yours, so please follow the schematic and not my board positioning. Try not to rush this step, and triple-check your layout against the schematic. As my protoshield has a green and red LED as well, I have wired the square-wave output to the green LED. You can never have too many blinking lights…
At this point I celebrated the union of tea and a biscuit. After returning to the desk, I checked the layout once more, and planned the solder bridges. All set – it was time to solder up. If you have the battery in the holder for some reason, you should remove it now, as they do not like getting warm. Furthermore, that crystal is very fragile, so please solder it in quickly.
And here we are – all soldering done except for the header sockets. At this point I used the continuity function of the multimeter to check the solder joints and make sure nothing was wrong with the circuit.
Final checks passed, so on with the headers. To make this easier, I stick some header pins in the sockets, then place the whole lot in a solderless breadboard to keep it straight. Well, it works for me:
Just a side note – always make sure you have enough consumables, the right tools, etc., before you start a project. This is how much solder I had left afterwards…
Moving on … in with the battery and the DS1307 – we’re done!
It is now time for the moment of truth – to insert the USB cable and re-run the sketch… and it worked! The blinking LED was too bright for me, so I de-soldered the wire. If you are making a shield, congratulations to you if yours worked as well. Note that if you are using this shield, you cannot use analog pins 4 and 5 – they are being used as the I2C bus.
So there we have it. Another useful shield, and proof that the Arduino system makes learning easy and fun. High resolution photos are available on flickr.
In the meanwhile have fun and keep checking into tronixstuff.com. Why not follow things on twitter, Google+, subscribe for email updates or RSS using the links on the right-hand column? And join our friendly Google Group – dedicated to the projects and related items on this website. Sign up – it’s free, helpful to each other – and we can all learn something.
Let’s make an Arduino LCD shield
In this short tutorial we make an Arduino LCD shield.
Updated 18/03/2013
Today we are going to make an Arduino shield with an LCD module. More often than not I have needed to use an LCD shield in one of my projects, or with the Arduino tutorials. Naturally you can buy a pre-made one, however doing your own is always fun and nice way to pass an afternoon. Before we start, let me say this: “to fail to plan is to plan to fail”. That saying is very appropriate when it comes to making your own shields.
The first step is to gather all of the parts you will need. In this case:
- an LCD module (backlit if possible, but I’m being cheap and using a non-backlit module) that is HD44780-compatible
- a 10k linear trimpot, used to adjust the LCD contrast
- a blank protoshield that matches your Arduino board
- various header pins required to solder into the shield (they should be included with your protoshield)
- plenty of paper to draw on
For example:
Next, test your parts to ensure everything works. So, draw a schematic so you have something to follow:
And then build the circuit on a solderless breadboard, so you can iron out all the hardware bugs before permanently soldering into the shield. If you have a backlit LCD, pins 15 and 16 are also used, 15 for backlight supply voltage (check your data sheet!) and 16 for backlight ground:
Once connected, test the shield with a simple sketch – for example the “HelloWorld” example in the Arduino IDE. Make sure you have the library initialization line:
LiquidCrystal lcd();
filled with the appropriate parameters. If you’re not sure about this, visit the LCD display tutorial in my Arduino tutorials.
Now to make the transition from temporary to permanent. Place your components onto the protoshield, and get a feel for how they can sit together. Whilst doing this, take into account that you will have to solder some jumper wires between the various pads and the digital pin contacts and the 5V strip at the top row, as well as the GND strip on the bottom row. You may find that you have to solder jumper wires on the bottom of the shield – that’s fine, but you need to ensure that they won’t interfere with the surface of your Arduino board as well.
Furthermore, some protoshields have extra functions already added to the board. For example, the shield I am using has two LEDs and a switch, so I will need to consider wiring them up as well – if something is there, you shouldn’t waste the opportunity to not use them.
If your shield has a solder mask on the rear, a great way to plan your wiring is to just draw them out with a whiteboard marker:
Remember to solder these wires in *before* the LCD … otherwise you will be in a whole world of pain. The LCD should be soldered in second-last, as it is the most difficult thing to desolder if you have made any mistakes. The last items to solder will be the header pins. So let’s get soldering…
After every solder joint, I pushed in the LCD module – in order to check my placement. You can never check too many times, even doing so I made a small mistake. Having a magnifying glass handy is also a great idea:
Now just to soldier on, soldering one pad at a time, then checking the joint and its relationship with where it should be on the board. Be very careful when applying solder to the pads, they can act as a “drain” and let lots of solder flow into the other side. If this happens you will spend some time trying to remove that excess solder – a solder sucker and some solder wick is useful for this.
Finally all the wires and pads were connected, and I checked the map once more. Soldering in the LCD was the easiest part – but it is always the most difficult to remove – so triple check your work before installing the display. Now it was time to sit in the header sockets, and test fit the shield into my arduino board. This is done to make sure there is sufficient space between the wires on the bottom of our shield and the top of the arduino:
Even though you wouldn’t normally put a shield on top of this shield, I used the header sockets to allow access to all of the arduino pins just in case. Soldering the sockets was easy, I used blu-tack to hold them into place. Crude but effective.
And we’re finished. Soldering is not the best of my skills, so I checked continuity between the pins on the LCD and where they were supposed to go, and also electrically checked for bridges between all the soldered pins to check for shorts. A multimeter with a continuity buzzer makes this easy. Naturally I had a short between LCD pin 14 and 13, but some solder wick helped me fix that.
So electrically it was correct… time to see if it actually worked! At this point it is a good idea to clear up the workspace, switch off the soldering iron, put it somewhere safe to cool down, then wash your hands thoroughly.
Here are some photos of the finished product on my arduino board:
As we’re using a Freetronics protoshield with onboard LEDs, the only thing to do was alter the demonstration sketch to take account for the pin placements, and insert some code to blink the LEDs. I never need an excuse to make a video clip, so here is the result:
So there you have it. With a little planning and care, you too can make your own Arduino shield. An LCD shield would be useful for everyone, as they are great for displaying data and requesting input, yet quite fiddly to use with a solderless breadboard. High resolution photos are available on flickr.
In the meanwhile have fun and keep checking into tronixstuff.com. Why not follow things on twitter, Google+, subscribe for email updates or RSS using the links on the right-hand column? And join our friendly Google Group – dedicated to the projects and related items on this website. Sign up – it’s free, helpful to each other – and we can all learn something.
Kit Review – JYE Tech Oscilloscope
Stop! Please read the post in entirety before making the kit.
[Updated 17/01/2013 - This is really not much use apart from basic waveforms]
Since returning to the world of electronics and general gadgetry, an oscilloscope has always been on my shopping list. However, they are not cheap. Sure, I could get a second-hand one from eBay, but here in Australia there are not that many floating around; the used ‘scopes are generally ex-defence or education and looked pretty whipped. However, being an impatient person a kit from JYETech (the same people who make the capacitance meter kit I previously reviewed) really grabbed my imagination – a kit digital oscilloscope! Cheap, low specification, but interesting nevertheless. After thinking about it too much, and after watching all the YouTube videos about it… I ordered one.
Let’s see what happens…
After a week my parcel arrived. Once again JYE Tech have not spared any expense on the packaging for the actual kit, just enough for everything to be safe.
The kit has some nice panels, front and rear, and a great solder-masked, silkscreened PCB. Thankfully I ordered the version that had the SMD components already soldered. (This kit is available in three versions: full kit, SMD soldered, and totally assembled [not really a kit...!]).
And time to check all the pieces have been included. There is no list inclued, so you have to check off against the BOM from the JYE Tech website for your particular version of the kit. This is not a kit you can just jump into and solder…
The instructions are very… sparse, confusing and time-consuming. One double-sided A4 piece of paper, one side with the schematic, and the other with a “quick reference”, internet links to support and a photo of the populated PCB. Thankfully, the JYETech website has all the documentation ready for download, and they also run a very well supported Google Group. Phew. They even publish the .dxf CAD files. So after downloading and printing off all of the documentation, it was time to review it and have lunch.
There is an amusing line in the instructions – “you will probably need to make a simple probe”. Yes, indeed. Included are enough parts to make a simple probe – with alligator clips at the end. Let’s call them semi-useful. They will do for the meanwhile.
Anyhow, enough preparation and reading. Time to build. NOTE: There are several versions of this kit – please double-check you have the correct assembly instructions. Look at your PCB – there is a white sticker on the edge with a code such as “06202KP…” - make sure that you have the correct sheet for your kit. There is no guarantee the correct sheet will ship with the meter!
Thankfully due to the SMD nature of most of the parts, there isn’t that much to solder. Firstly, I wanted to get the 7805 regulator and heatsink in:
… and the rest of the parts – 7 capacitors, a diode and an inductor. You really need to have your wits about you – there are places on the PCB and parts in the schematic for which you are not to use – it is easy to get lost if you don’t concentrate. Just remember to match the physical components supplied against the BOM from the website, and only install those – after considering the assembly instructions. Another caveat is that you need to check you have the correct documentation for your PCB. For example, mine was a 06202KP, whereas the website had something different. Thankfully the Google Group had the correct .pdf file.
Remember that positive pins of capacitors into square pads. There seems to be an ambiguity in the instructions regarding C14 – for the 06202 model, C14 positive is on the right hand side.
Next, the sockets for signal and DC, switches and push buttons. You need to get the switches and buttons flush with the PCB, otherwise you will have issues with the top panel and button caps.
Don’t forget the 2×4 pin header – solder it in before the LCD! Now for the LCD.
Stop now. Make sure you run the power tests as per the assembly instructions. Once that LCD is soldered in, having to take it out again will be a huge PITA.
When you look at the rear of the LCD module, there are two rows of 20 holes – solder the row of pins into the row with markings (GND~NC). I found the easiest way to do this was to sit the row of pins into the main PCB, sit the LCD on top and solder the pins into the LCD module. The solder in the 2 pairs of pins that support the LCD. You may find the heatsink blocks one of the pins – just cut one pin off and use that then.
Now it is seven hours later. To cut a long story short – be very careful when soldering the LCD pins. It is very easy to cause a bridge which will wreak havoc and short out something, which cooks the LCD, 7805 and the microprocessor. If your unit heats up like a stove, unplug it and triple check your soldering under a magnifying glass. Run continuity tests to be sure you haven’t shorted out anything.
But thankfully – after all my time working on it, hunched over a hot iron in a dark room, and staring through a magnifying glass:
Woohoo! We have life!
I had that heatsink on just in case - didn’t take it off for the photo. Now it is time to assemble the body and make it look presentable:
And of course … I’ll need a set of probes. So I assembled them using the parts included in the kit.
Finally – I can clean up the desk and wash my hands. Originally I was going to write a whole section explaining how oscilloscopes work and the terminology. But thankfully the good people at Tektronix have done this already and made a nice little e-book for us. So here it is: XYZs of Oscilloscopes (Tektronix) PDF.
Now, let’s spend some time examining what this baby can do. Just a note at this point, if you didn’t install the heatsink, you should install a clip-on heatsink over the 7805. After sitting on my desk for around 30 minutes the 7805 does get warm. Here are some photos of the scope in use:
14.2 volts AC. The scope should have displayed the minimum and maximum, but for some reason has clipped them.
In order to see half of the full wave, the V.POS was lowered to the minimum. This is indicated by the tiny marker at the bottom left of the LCD
Again with V.POS at the minimum, the time period was altered, and the display frozen to see the maximum.
5 volts DC at 5 volts per division
5 volts DC at 2 volts per division
By dropping V.POS to the minimum, you can increase the maximum amplitude possible. Note the tiny marker at the bottom-left of the screen, indicating the new 0V line.
5 volts DC using 1 volt per division.
2 volts DC at 0.5 volts per division (using x5 and 0.1 settings)
1.25 volts DC at 0.5 volts per division
By default it shows 50Hz as that is the frequency of mains voltage in Australia (probes not connected, it gets the default frequency through the power supply [Australia is 240V 50 Hz]). And now for a video, a short compilation of various measurements: DC voltage, frequency, FFT and pulse-width modulation.
You can also upgrade the firmware and save screen shots if you attach a cable to the jumpers on the rear of the main PCB. If you were to do this often enough, it would be wise to cut a rectangle out of the back panel.
Conclusion.
To be honest, I found this kit very challenging to assemble, finding the correct instructions the second time around was very frustrating, and the documentation is very poor. This is not a kit for beginners, more of a curiosity for those experienced in electronics work and fault-finding. In saying that, I’m glad I had a go – assembling and getting it to work taught me a lot about my own abilities, fault-finding, and tested my patience. But it gave me a real buzz once I got it working.
It was rather annoying to use such a low screen resolution, you won’t be detecting too much ripple on your DC power supplies with this one. But for the price, it is an interesting piece of gear. I will probably end up giving it away as a prize or something. It has a maximum of 50 volts peak to peak input amplitude, but I couldn’t for the life of me hone the display down to show 12 volts AC without cutting off the minimum and maximum. Will persevere and spend more time with it.
Furthermore, it is a good stepping stone to acquiring a full oscilloscope – if you find yourself using this one and getting frustrated with the limitations, it’s time you bought a full ‘scope!
Thank you for reading and I look forward to your comments and so on. High resolution photos are available on flickr.
bbboost chapter five – the power supply module
[3 July 2010 - this project has been retired, but the posts left for reference]
Greeting again to followers of the bbboost journey. It has been a month since the last instalment, however the 20V DC plug pack took a long time to arrive from the land of China. Nevertheless, the project is moving forward. For my new readers, the bbboost is a power supply that can be assembled by a beginner, and can offer a smooth variable DC output voltage of between ~1.8 and ~20 volts – perfect for experimenting, breadboard, and generally saving money by not buying batteries. You can just make a PCB version, or mount it in an enclosure like a professional desktop unit. No mains voltage wiring is required, so it will fine for the younger enthusiasts. Follow the project from here.
This time I have breadboarded the power supply module, using the circuit described in chapter two. Let’s have a bit of a look:
These trimpots were ok, but it would be preferable to use the fully enclosed dustproof versions. Will order some and try ‘em out.
One trimpot (the blue and white one) is 5k ohm, – to adjust between the full range, so this is the ‘coarse’ adjuster; the other trimpot is only 500 ohms and changes the voltage selected by the coarse pot by around +/- 1.2 volts. The purpose of having two controls is to make it very easy to select your required voltage down to one-hundredth of a volt. The following video clip is a rough example of this type of adjustment in action:
This power supply will also be designed for installation into a nice enclosure, so in that case one would use normal-sized potentiometers for the coarse and fine voltage adjustment. Will try that for the next instalment.
So, thank you once more for reading. Please leave feedback and constructive criticism or comments at your leisure… and to keep track, subscribe using the services at the top right of this page!
bbboost chapter four – the digital ammeter
[3 July 2010 - this project has been retired, but the posts left for reference]
Greeting again to followers of the bbboost journey. Finally the required parts arrived today so now the project can move forward. (Living in a country of 22 million people, you would think 5W resistors would be easy to come by. Think again). If this is your first brush with the bbboost project, please visit here to see what it is all about!
So today we are going to modify the voltmeter module to convert it to an ammeter (current meter) and therefore a very useful thing to have on a desktop power supply. By having an ammeter, once your project or prototype is running you can use the current readout to determine the power supply or battery requirements for your project, or dance dangerously close to the limits of the circuitry. Careful!
However converting the voltmeter is a simple process. Using Ohm’s law, we know that current = voltage over resistance. So our problem requires us to determine the current. If we measure the voltage potential across something of a known resistance (say, a resistor), and divide the voltage by the resistance, we have the current flowing through the resistor.
I = current in Amps; V = Volts; R = resistance in Ohms.
So for example, if we have the current of our supply circuit running through a 1 ohm (5 watt – as the wattage will increase at full load) resistor, and the voltage potential across the resistor is 0.0084 volts (8.4 millivolts), the current will be 8.4 milliamps (or 0.0084 A).
Now that we already have a voltmeter, a simple removal of the 1M ohm resistor from the terminals and replacing it with a 10k ohm resistor allows the meter to measure much smaller voltages. Therefore the maximum is will measure is 999.9 mV (which we will note as mA when being used in ammeter mode). Here is the circuit diagram for the ammeter. Note the only change from the voltmeter is below the 10 nF capacitor at the bottom-left of IC1. The supply current will be running through the 1 ohm 5 watt resistor. In the next chapters we will discuss a switching solution to flip between voltmeter and ammeter without any rewiring by the end user.
(Yes, I am learning how to use Eagle)
Also note the change of wiring on our breadboard, it is much neater and easier to follow. The solid wires are much more reliable than the looser ones used previously. Although they can be more difficult to route around a breadboard, they will be more reliable – especially if you move the board around a lot.
There we have it! A simple conversion has made our voltmeter an ammeter with a range of 0~999.9 milliamps (basically 1 amp). Which matches nicely with the original specification of the bbboost power supply of 1 Amp. But now for the action test: measure some current! Our test subject is an LED in series with a 10k variable resistor and a 6v battery. In the video clip (no audio) we will measure the current through the circuit at three different rates, changing the resistance to alter the current three times, then comparing the readout on the bbboost and a multimeter set to mA scale. The test current values are: 0.8 mA; 12.4~5 mA (third time lucky) and 118.5 mA (bbboost) vs. 114.8 mA (multimeter). That’s a difference of 3.7 mA – for the purpose of this project, quite negligible. There is always Fluke!
The extra parts required for this section are a 10k ohm 0.25 W resistor and a 1 ohm 5W resistor.
Well that was nicely successful – except for that pesky decimal point – we didn’t do anything about it in the change from a voltmeter to an ammeter. That, my friends, is for the next instalments.
So, thank you once more for reading. Please leave feedback and constructive criticism or comments at your leisure… and to keep track, subscribe using the services at the top right of this page!
bbboost chapter three – the digital voltmeter
[3 July 2010 - this project has been retired, but the posts left for reference]
Our bbboost journey continues today with the prototype voltmeter module. Once complete, the bbboost will have a digital voltmeter to accurately measure the output voltage. (And maybe… an ammeter… stay tuned). Over the last week I have been pondering and experimenting on what sort of voltmeter to have. Of course it had to be digital, but what to drive it? First there was a PICAXE microcontroller using a voltage divider and the PICAXE’s analogue to digital converter. Great… except that chip can only use integers. Next…
There seem to be many cheap digital LED voltmeter modules on eBay at the moment, but where’s the fun in that?
Around six months ago I stumbled upon an interesting IC when wasting time browsing through the Farnell website, so I ordered two of them planning to do something with them later on. And promptly forgot about them. However research for the voltmeter showed this chip as ideal – the Intersil ICL7107. An analogue to digital converter and 3.5-digit LED driver all in one. Woohoo!
Data sheet is here… ICL7107 datasheet
Furthermore, this seemed like an inexpensive solution, volumes of this IC can be had for ~$2. Good so far, but after studying the data sheet – there was a catch.
It needs positive and negative five volts DC… ah fudge. The ICL7107 data sheet suggests using a CD4009 hex buffer/converter, with some diodes and capacitors. Nope, too hard and messy. However, thanks to the internet a solution was found – the ICL7660 CMOS voltage inverter!
Check it out – ICL7660 Voltage converter
So now the theoretical solution had been found, it was time to move from thinking to doing. Originally I used the circuit diagram from the Intersil web site, however calibration was a problem due to only having a single-turn potentiometer (see parts list below). So for the real unit, a multi-turn potentiometer will be used for R7.
Just a side note… breadboarding circuits can be a joy or a pain. If you use those cheap-ass breadboards from China via eBay, you will suffer. Take my word for it.
Anyhoo, before getting the circuit together, I like to line up all measure all the components – note my trusty capacitance meter …
Then put them in order according to the parts list. This will save confusion and time later on, as you have checked all the values and ensured they are correct before installation!
Here is my lovingly-crafted schematic for the voltmeter module. Note that this could be made as a standalone voltmeter, it will measure up to 20v DC. In our finished product, the +5V will be sourced from an LM78L05 voltage regulator.
And the parts list:
- IC1 – Intersil ICL7107CPLZ
- IC2 – Intersil ICL7660
- D1~D3 – 1N4148 diodes
- LED displays – Agilent HDSP521G 2 x 7-segment green displays (common anode). You can use anything really, as long as it is common anode, and each segment is ~8mA
- R1 – 220 ohm – all resistors 0.25W
- R2 – 10k ohm
- R3 – 1M ohm
- R4 – 47k ohm
- R5 – 15k ohm
- R6 – 100k ohm
- R7 – 1k ohm multiturn potentiometer/trimpot (for calibration)
- C1 – 10nF – all capacitors must be rated for at least 25V
- C2 – 20nF
- C3 – 470 nF
- C4 – 100 nF
- C5 – 100 pF
- C6,7 – 10 uF electrolytic
Please note that this is a work in progress and errors may have been made, or values altered at any time after publication.
And now for the finished mess:
Wow – what a mess. If you are going to use a breadboard – take care with the very low value capacitors. Try to keep the legs as short as possible to improve the meter stability. When you turn it on, the display will flick a few numbers around until settling on zero. You will need to calibrate it, so just measure a solid, reliable power source (such as the output from an LM7812 and LM7805 (12V and 5V DC) in turn. So when you are measuring the (for example) 5V output from the 7805, adjust the trimpot until the display says 5.00. Try this if you can with a few different reliable voltage sources, to check your new meter’s accuracy.
Finally, this wouldn’t be complete without one of my soundless videos. In this clip, I measure a 9v battery, then an alkaline AA cell, then the same again but with reverse polarity.
So thanks once more for reading. Please leave feedback and constructive criticism or comments at your leisure… and to keep track, subscribe using the services at the top right of this page!
bbboost chapter two – which regulator?
[3 July 2010 - this project has been retired, but the posts left for reference]
In the journey to create the bbboost, first we need to start at the core – that is, the voltate regulator itself. Searching for one that meets our specification was easier than expected, I just searched for “adjustable linear voltage regulator IC” in the Farnell website and listed the results by price. The likely candidate was the National Semiconductor LM317T. Hopefully most of you would realise that this was not a surprise, the LM317 is very popular. Limor over at adafruit industries uses a Micrel MIC2941, which is also an excellent regulator, due to the low dropout voltage, which means you can create 3.3V from 3.7v (for example).
However it is just too expensive, at $1.51 each for lots of 50. The LM317T is available individually for ~78 cents, or 58 cents in amounts greater than 100. Furthermore, the LM317 can provide up to 1.5 amps of current, greater than our intial spec for the bbboost. However to keep costs down, we will stick with the assumption of one amp, unless you choose to find a 1.5A plugpack. It also has short-circuit protection on the output, and thermal shutdown. This means if it overheats, it will turn off instead of becoming damaged. However, the maximum current available will decrease if the regulator becomes hot. Now there’s an interesting experiment!
Lots of interesting information can be found on the data sheet below:
One of the good things about data sheets are the example circuits, of which we can make use of for the basis of our bbboost. So thanks to National Semiconductor, here is the hand-drawn base for our bbboost, with one difference – there will be two voltage adjustment potentiometers (variable resistors). The 5k (R1) will control the voltage, however R2 will be used as a fine adjustment control. Handy if you really need 8.45V and not 8.49V…
(Sorry for the hand-written schematic. I’m still working on using the software I have. Next time…)
We will decide on a value for R2 later on, after experimenting with the voltage display. So far, our list of materials is:
- C1 – 0.1 uF 50V greencap capacitor
- C2 – 1.0 uF 50V electrolytic capacitor
- IC1 – LM317T linear voltage regulator
- R1 – 5k potentiometer
- R2 – very low value potentiometer
- R3 – 240 ohm 1/2 watt resistor
C1 is used to smooth any ripples in the input voltage that can be created during the AC to DC conversion in the plug pack. C2 is used to improve the transient response (i.e. keep the output voltage nice and smooth).
So at this point we will put the project to one side – I’m waiting for the parts to arrive! Be sure to subscribe for updates (see the top-right) and explore the other posts on the blog. Bye for now!
The better world of books
Learning about anything can be an expensive exercise. Textbooks, materials, lessons, time, patience, and the time and patience of those around you. Naturally it is desirable to save some expenditure. My greatest expense has usually been books, as I love to read. Some people will say that the e-book is taking over – true, but very slowly. The kindle, ipad, ereaders, joojoos, etc are coming. But frankly there is nothing like the smell, feel and ease of use that only a real book can offer.
Which brings me to the point of this post (“finally” you think…) I have found a source of cheap, interesting used (and new) books!
BetterWorldBooks.com – “The online bookstore with a soul”
Their operation revolves aruond gathering library discards, retired books and so on, rounds them all up, indexes them into a warehouse and sells them very cheaply. For those living in the US, postage is free, and those further out – postage is only US$3.97 per book.
From their site’s about page:
Better World Books collects and sells books online to fund literacy initiatives worldwide. With more than six million new and used titles in stock, we’re a self-sustaining, triple-bottom-line company that creates social, economic and environmental value for all our stakeholders.
We were founded in 2002 by three friends from the University of Notre Dame who started selling textbooks online to earn some money, and ended up forming a pioneering social enterprise — a business with a mission to promote literacy.
We’re not a traditional company with an add-on “cause” component. Social and environmental responsibility is at thecore of our business. You could say it’s in our DNA.
We’re breaking new ground in online bookselling. We believe that education and access to books are basic human rights. That’s why books sold on BetterWorldBooks.com help fund high-impact literacy projects in the United States and around the world.
All books are available with free shipping to any location within the United States (or $3.97 worldwide). And in case you’re concerned about your eco-footprint, every order is shipped carbon neutral with offsets from Carbonfund.org.
Here’s the best part: In addition to selling new titles, Better World Books supports book drives and collects used books and textbooks through a network of over 1,800 college campuses and partnerships with over 2,000 libraries nationwide. So far, the company has converted more than 25 million donated books into $7.3 million in funding for literacy and education. In the process, we’ve also diverted more than 13,000 tons of books from landfills.
Because we believe that most every book has lasting value and the potential to help change the world, we see our job as helping to find new homes for unwanted books. Thus far, we’ve donated 1.5 million books to partner programs around the world. Our five primary literacy partners are Books for Africa, Room to Read, Worldfund, the National Center for Family Literacy, and Invisible Children. Good company, no doubt.
Every book purchased from Better World Books contributes to individual literacy throughout the world and the promise of a better life. Clearly, we can’t do this work without our customers. That’s why we’re so passionate about trying to offer the best price, selection, customer service, and overall shopping experience.
Although that does sound all ‘warm and fuzzy’ – they deliver on their promise. My last order was for “Digital Electronics – A Practical Approach” by Kleitz, 5th edition. US$10 delivered to Australia. I even found a copy of Don Lancaster’s “CMOS Cookbook” [a classic] for US$4, or “Calculus” by Anton for the same price. The selection below in total was less than US$70 – a bargain.
So before you hit Amazon or eBay, give this operation a try, I think you will be pleasantly surprised!
[Note - this article was initiated by myself personally without the aid or knowledge of the company in mention]








































































