Introduction
WARNING: While I've made every effort to ensure that the information presented on this page is error-free, I will NOT be held responsible for any damage caused by use of this information. Electronics should be fun but there is also a very serious side to it, so please take care when using tools and when dealing with high voltage and current circuits.
I have one of my older brothers, Matthew, to thank for helping me and inspiring me to pursue electronics as a hobby, which includes both hardware and software. Over ten years later, electronic technology has changed dramatically, it has improved to save people's lives when used as equipment in hospitals, or to entertain us wherever we are and to provide a wealth of information at our fingertips.
I would like to use this moment to mention a few significant electronics products and related services that were first released within the past ten years or became very popular during that time; yet, today they're so common that we probably couldn't imagine a life without them.
CD Player: They are old news thanks to MP3 players and the like but I remember being at school one day and my friend having a portable CD player, which was probably the first time I had seen one up close at the time. I don't know how much he payed then, or who bought it for him, but they are dirt cheap today yet provide clear, digital sound that was like a revelation for users of the cassette and record player once upon a time.
Multimedia Computers: At school I was introduced to a new way of using a computer that was made possible because of CD-ROM's. They did turn out to be a bit of a novelty these point and click programs where little animations would be played as demonstration of the interactivity, but at the time it was more advanced than the BBC computers they had in addition to the PC's at my school.
DVD: Digital Versatile Disk or Digital Video Disk, compared to videotapes DVD's were amazing but expensive, especially the players, when they first came out. But as with all types of electronics which become popular, DVD players and the actual disks dropped in price and today DVD-ROM drives are a standard that are included with computers, but even without a computer DVD players and recorders are nothing new in the home.
DVD's have evolved, the next generation is all about High Definition (HD), providing even clearer audio and video thanks to the increased storage capacity compared to non-HD DVD's. And thankfully Blu-ray DVD's defeated the other form of HD DVD, meaning that we will get the very best in quality in our games and movies.
Internet: Some people seriously believed that the internet wouldn't last long but it is more popular than ever before and is used by millions of people around the world every day, whether for sending emails, researching, or playing games with someone far away. As the price of PC's and laptops dropped along with the cost of ISP's, more people went online and with broadband so cheap nowadays we can enjoy the networking of computers at speeds that grant a very enjoyable experience.
Of course it's not only consumers who use the internet daily, for many businesses they have managed to sell and advertise their services to a greater range of people; speaking of which, I remember some while a go when businesses first started to have their own website and email but now it's something we expect.
MP3 Palyer: One of the greatest examples of how electronic components have reduced in size over the years and how new technology has made possible portable devices that were unheard of some time in the past. At the time, when me and my family went on holiday, my oldest brother Daniel would take with him his faviourte music to listen to, on cassettes. In later years however, instead of what was now old news, Daniel took with him his CD's but there was still a lot to take. And recently, when Daniel goes on holiday with us he only needs to take with him just one music item: his ipod. All those songs stored inside a device smaller than one of his CD's; it's just another example of the wonders of modern electronics.
Electronics for Sale
Electronic Components Explained
No matter how simple or complex an electronic device is, it is made up of one or more electronic components which work together to control the flow of electricity, know as current. Anything electrical or electronic needs a source of power which may be batteries as is usual with portable equipment, solar energy or the good old mains supply in our houses and other buildings. The difference between the two connections of the supply is the potential difference, measured in volts. Unfortunately, nothing man made is perfect and therefore the flow of electric current is opposed by a force called resistance.
If you think of electricity as water, voltage as the drop between a high and low point where the water flows (like a water dam), and a valve like you'd find in a tap as the resistance, then this should help you understand how electricty works. And it's a good time to note that electricity-as great as it is-is very lazy and will always take the shortest path, which is why shorts are so dangerous; there is little resistance.
The sources of current (batteries, mains, etc) can be split up into two main forms which are Alternating Current (AC) and Direct Current (DC). A common example of AC is the mains supply; the current changes polarity periodically, 50 or 60 times a second depending on factors like where you live. With DC supplied by batteries and other electrical sources, current is very steady and will not change polarity as does AC. Rectification is the process of converting AC to DC so that devices requiring direct current can run of the mains supply, often after the voltage is stepped down first.
(pic to be added)
Above, various batteries. Top left is your average 1.5V (AA), on the right a less common 4.5V, then the largest battery is a 6V used in big torches, and on the far right is a 9V battery (PP3). On the bottom left are two 1.5V pill batteries like you'd find in a watch and two 3V batteries to the right, the one on the far right has small legs so it can be soldered to a circuit board.
An electric cell generates electricity from chemical energy as it discharges, and has limited use; this is a primary cell. Those batteries that can be recharged, however, are secondary cells because they can be charged (electricity is converted to chemical energy) and discharged many times, but a finite number of times. Although the term cell and battery are used by most people interchangeably, they are not the same thing, a battery is two or more cells connected in series (usually, but they can be wired in parallel). Thus, a 'cell phone' is technically incorrect, a mobile phone-as they're called here in the UK-is better since a mobile phone uses a battery, not a single cell. Yes, mobile phone batteries look like a single cell but internally they are made up of many cells.
You know how batteries are marked negative (-) and positive (+) on each end, well, it's actually wrong!. The negative terminal should be marked '0V' but negative and 0V are often used to mean the same thing even though zero is neither positive nor negative. With power supplies that generate only a positive voltage this doesn't matter but those supplies that produce positive and negative voltages will be marked positive (+), 0V, and negative (-).
An electrical circuit is the path through wires and components where electricity flows, from one end to another. Just as a runner makes his or her way from the start to the finish so do the electrons that make up the current, they travel from one end of the power supply to the other so as long as there is no break in the path.
You may wonder which way the electricity travels for a DC circuit (remember that the direction continually changes for AC), and there are two answers. It was originally thought that the electrons travelled from the positive (+) side of the supply and through the circuit to reach the supply's negative (-) connection, this is known as the conventional flow of electricity and even though it's wrong, it's used to describe how a circuit works. But when detailing the workings of an individual component at low level, it is better to use the actual electron flow which is from the (-) terminal to the (+).
***Warning!***
The mains supply can kill. Never use equipment if the power cable is damaged, it must be replaced. DO NOT attempt to build, test or repair mains powered equipment if unsure of what you are doing. It really is better to be safe than sorry.
Since some form of power supply is essential for any electrical circuit to work, and in particular for mains powered devices, a lot of time, effort and money is put in getting it right. The power supply circuit will either be part of the main circuit, on a separate circuit board or will be sealed away inside a metal case that is earthed.
(pic to be added)
Above is an opened power supply from an Epson printer; note the three-pin mains lead socket at the front, the matrix of holes in the case that let the heat out, and the ribbon cable at the right which carries the different voltages to the main circuit board.
Any material which conducts electricity and thus has low resistance is a conductor, whereas the opposite is an insulator which does not conduct electricity very well, though at very high voltages the insulator may break down and allow the current to flow, usually something you would want to avoid!
Think of an average wire; running through the middle is a length of thin metal (of thick if it's to carry high current) which conducts the current to its destination and around that conductor is the insulator (often plastic) that prevents shorting with other wires and contacts.
A word about wires, when they are grouped together they are often coloured coded but be cautious as the most obvious may be wrong. I stick to red for a positive voltage (like the power supply) and black for the negative connection but I've seen the opposite so always check if you are repairing or testing a device you didn't make; don't assume.
Now let's look at some individual components and see how they work:
Switch: Where would we be without switches?! A switch, in its most simplest form, consists of two pieces of metal which the user pushes together to make a connection and thus allow current to flow. There are two main types of switches, those that latch or lock into place, and those which don't. On old computers the CAPS switch was of a locking type as was the power supply switch but modern computers have non-latching switches for the CAPS lock and power supply switch.
Whether the switch locks or not, when you press the switch it may either push the two connections together (said to be normally open or push to make) or the press may push the connections apart (known as normally closed or push to break). Some switches have both normally open and normally closed connections often with a common terminal; you may need to use one or the other, or both. Some switches can have ten connections or more, thus allowing different parts of a circuit to be turned on or off with just the one switch.
Microswitches typically are quite small and require little force to operate and are of the non-locking type usually. Examples of where microswitches are used are in digital joysticks and joypads and as selection buttons on modern radios, CD players and the like.
Resistor: Probably the simplest of components, a resistor restricts the flow of electricity, that is, it opposes the flow of current. Many conductors have some resistance like a wire does, for example, but often its resistance can be ignored as it's so small. Resistors are made to especially limit the flow of current by a certain amount, within a given range called the tolerance. This resistance is measured in ohms (R), kilohms (1,000R or 1KR), and megaohms (1,000,000R or 1MR).
(pic to be added)
Above, you can see a collection of fixed resistors, most of them are quarter watt, a few half a watt. Wattage is a measure of power, these resistors will generate heat (like any other component) as a waste product when used in a circuit and the component must be able to withstand the power. So, components such as resistors are rated as to how much power they can deal with without being damaged; generally the larger it is the more power it can handle.
The type of resistor just described is a fixed resistor, however its resistance will vary slightly with aging and due to the heating of the component as current passes through it. A variation is the variable resistor that was once upon a time used as the volume control for radios, TV's and the like, until they were replaced by digital alternatives. A variable resistor's resistance is changed by turning a dial and some of them include a switch which is handing for turning on or off the power supply. A sub version of the variable resistor is one which is altered not too often as to make fine adjustments and is a preset variable resistor; a screwdriver is needed to change its resistance and the actual component is usually hidden away or only accessible via a small hole in the device's casing.
One mistake made by many is to refer to any form of variable resistor as a potentiometer or pot for short, because this is not necessarily true. When all three connections of the variable resistor are used in a circuit, thus creating a potential divider, it is being used as a potentiometer, not when only two are used.
A thermistor you might find in a digital thermometer, is a type of resistor whose resistance varies with temperature in a non-linear way.
A light dependent resistor or LDR is yet another form of variable resistor, but one whose resistance changes with the light that falls on the device and finds use in night lights.
Capacitor (cap for short; a.k.a condenser): Electricity can be stored briefly in a capacitor, a component made up of two parallel conducting plates separated by an insulator, which can be for example the air, plastic, or paper. Because of the insulator, current can't flow through the capacitor but a charge will accumulate on both plates. Once charged fully, the capacitor will act very much like a very limited battery, able to supply current for a short time before the capacitor has to be charged once more. The capacitor's ability to store a charge is a rating of its capacitance and is measured in farads and until recently, capacitors with a capacitance of a farad or more were not heard of. These 'Super Capacitors' having a capacitance of a farad or more can now rival ordinary batteries but at a high cost.
Capacitors can be divided into two main groups; polarized and non-polarized. Polarized capacitors can be used only with DC as they have to be connected with respect to polarity (- and +), whereas non-polarized capacitors can be connected any way round and can be used with an AC supply as well as a DC one. One common form of polarized capacitor is the electrolytic capacitor, used very much in power supplies as to supply current when the rest of the circuit can't deliver it; used like that it is known as a reservoir or smoothing capacitor.
It's very important that polarized capacitors are connected correctly otherwise they may explode, though this has yet to happen to me as I always check the polarity. Marked on the capacitor's body for a polarizecd capacitor will be some indication to which lead is the negative terminal and once that has been found, we know the other is positive. When capacitors are bought new one lead may be shorter than the other, this is the negative lead while the longer one is, of course, the positive.
Especially electrolytic capacitors can store as much as 100V or more, such as those found in TV's, monitors and cameras (as to deliver the high voltage needed for the flash). These high voltages have the potential to kill and is why you should always wait a few hours at least for them to discharge before servicing something like a TV. The capacitor can be discharged by connecting a fairly low value but high power resistor in parallel with the capacitor or even a lightbulb (provided it can withstand the voltage) and will act as a visual indication as to when the capacitor has discharged.
(pic to be added)
Above, are some electrolytic capacitors of different sizes, the small ones can store only 16V maximum while the larger ones can store 50V or more. But it isn't just the voltage that determines how large the capacitor is, its capacitance does also. That is, a capacitor that has large capacitance and can store a high voltage will be very large, such as those found in mains power supplies. However, even for the same voltage and capacitance the size will vary slightly depending on the manufacturer.
Some capacitors that are of small size can only handle a low voltage so you must make a point of checking that if you use such a capacitor that it will never be exposed to a voltage higher than that it is rated at, as indicated on its body. To be safe it is a good idea to use a capacitor that is rated as able to withstand at least double the voltage available in the circuit.
As seen in the photo above, capacitors come in different shapes, know as the type of package. The radial capacitors have both their leads originating from the bottom while the axial capacitors have a lead jutting out either side. The only real difference when soldering a circuit is that the axial capacitors take up more space than the radial type.
The charging and discharging of a capacitor can be delayed by using a resistor allowing time delays to be created. A simple timer can be created this way but there are far more accurate alteranatives.
Similiar to the variable resistor, a variable capacitor's capacitance is varied by using a dial and was once commonly used to change the station on radios and TV's. There are preset versions also, and one example of their use was to tune in the stations that a TV could receive, which could then be selected using the channel switches.
Diode: Acting like a switch, a diode has two connections which are its anode and cathode. When the diode's anode is more positive than its cathode the component will have low resistance, allowing current to flow through it; it is said to be forward biased. However, when the diode's anode is more negative than it cathode the diode will block the current (except for a tiny amount known as leakage); in this mode it is reverse biased.
Because of its ability to control the flow of electricity, diodes are often used as rectifiers, that is, they convert AC to DC. This may be the case for power supplies that must deliver DC to the device it is powering and also in test equipment which accept an AC input but can only process it in DC form.
Another practical use of a diode that is possible because of its switching ability is in battery powered electronics where someone may insert the batteries the wrong way round. This could damage the components, but with a diode wired in series with the batteries it will not turn on unless they are connected with the correct polarity. There is a small price to pay for this feature; when current flows through the diode there will be a small voltage drop across it, something like 0.3V for a germanium (used rarely nowadays) diode or 0.6V for a silicon (the more popular material used to make diodes) diode.
Other types of diodes include Light Emitting Diodes, commonly referred to as LED's, which will only light when forward biased and, depending on its size, shape and the colour it produces, can work on as low as 2V at 20mA yet some can rival an ordinary lightbulb.
Lightbulbs have many disadvantages despite the fact that they're still so common; they can easily break and cause someone injury due to the glass, they need replacing often and like to blow when you turn the light switch on (thanks to the sudden surge of current). But LED's on the other hand, last for ages, are made from plastic and come in shapes and colours that you just don't see with lightbulbs and the recent white LED's are bright enuough to put some lightbulbs to shame and they won't drain the batteries so quickly. One reason that lightbulbs are still used so much is that because of the small voltage drop across an LED (e.g., 2V), the component can easily be damaged by too high a voltage or too much current, thus a limiting resistor is used in series with the LED; whereas a lightbulb usually doesn't need such a thing.
On the left is an average, 5mm red LED but on the right is probably the biggest LED you can buy, at 20mm. Large LED's such as this one are actually made up of a number of smaller LED's within the same package; the one shown in the photo on the left has three LED's internally at the bottom and three at the top, with individual connections for each LED. As to avoid damaging such a beauty (big is beautiful as they say), I soldered twelve connecting pins onto stripboard along with two ribbon cables; the LED is inserted into the pins.
There are hundreds of different types of LED's, but here is a taster:
* The ordinary types of LED's just described come in many colours with red probably the most common, green, orange and yellow also available, and blue and white more recent inventions and operating at slightly higher voltages. As with coloured lightbulbs that are really just white but shine the colour of its glass this applies to LED's originally but now semi-see through (or milky) and totally transparent LED's that light up white or any other colour are ready to buy with some LED's (as introduced below) that have to have a whitish bulb.
The size of LED's range from about 1mm to an incredible 20mm; the larger LED's are actually two or more LED's in the same casing that light together and thus illuminate a wider rand than a single LED could. As for shapes, there are round, square, rectangle, triangle and other variations but sometimes an ordinary round LED is used in equipment, with a filter used to give the illusion that the light is shaped such as for the play button for a VCR that is triangle.
Now that LED's can give lightbulbs a run for their money, LED Christmas lights are beginning to replace the more traditional lightbulbs. As already noted that LED's can be damaged by too high a voltage (or current) the LED Christmas lights run off either batteries or a step down power supply from the mains. LED's can be placed in series thus allowing them to run off a higher voltage (there will be a 2V drop across each LED so for example you could safely use four LED's on 8V), or in parallel but the voltage would still be the same (i.e 2V) but more current would be needed for each LED.
Most LED's are radial, that is, the leads come out from its base but you can get axial LED's that resemble ordinary diodes in that a lead originates from both ends.
LED's work behind the scenes in some devices such as to provide a backlight for an LCD; the backlight could be any colour but commonly is white, green or yellow.
* Bi-colour LED's are two different coloured LED's (usually red and green but might be red and yellow) connected in inverse parallel (the opposite way round) in the same package. They can be used as polarity indicators since one LED will light when the LED is connected one way and the other colour will light when the LED is connected the other way. However, there are bi-colour LED's which have three connections rather than just two and look just like a tri-colour LED. You won't get the third colour with the three-lead bi-colour LED's, of course; they are used to make it easier to light either colour since there's no need to reverse the polarity to get a particular colour.
Bi-colour LED's are used often to indicate the charging or discharging state of a rechargeable battery. For example, red may be used to show that the battery needs charging and green to notify that the battery is near or fully charged. They are also used to show whether a device is in standby such that red means that it is in standby and green shows that it is no longer in standby.
*A tri-colour LED has three terminals and lights up one of three colours, such as red, green and yellow (or orange); one of the connections is the common of the two LED's, the third colour is acheived by lighting the two LED's at the same time, mixing the colours together and thus creating the third colour. If you look closely when a tri-colour LED is lit yellow or orange you should see a hint or red and green at either side of the LED, as mixing the two colours produces the third as already outlined.
* There are special LED's which have a built in regulator, allowing them to work on a wide range of voltages and currents, saving you the worry of which limiting resistor to use. A variation on these LED's are those which flash or cycle through a number of colours, again using a built in chip and regulator.
* You can get RGB (Red, Green, Blue) LED's that can light up many different colours and would therefore be useful for creating an LED TV or monitor.
* Seven-segment LED displays are still in use today even with LCD's (Liquid Crystal Displays) using less power and thus more suitable to battery powered devices; it is the LED's greater brightness that perhaps makes them more appealing and are more suitable for mains supplied equipment; also, LED's are often used as backlights for LCD's. These displays are made up of seven LED's arranged in the all too familiar figure 8 pattern sometimes with one or more decimal points, allowing the numbers 0-9 to be lit as well as the letters A-F (i.e. hexadecimal) in a combination of upper and lower case, as well as other letters and symbols.
There are also LED displays with more segments so that more recognisable characters can be displayed but when pictures must be shown, dot matrix displays are used; made up of many round LED's.
Optoelectronics, as is the name given to devices which produce or detect visible or invisible light, is truly wonderful but wait, there is more to talk about! Photodiodes transmit an infra-red beam, allowing remote operation of a device, such as a TV or CD player for example, while a phototransistor detects the beam, switching itself on and causing something to happen (i.e., the channel changes).
If you couple (put together) an infra-red (or visible) diode and a phototranistor you create a slotted-opto switch; a non-transparent object that passes through the beam produced by the photodiode will be interrupted, causing the phototransistor to switch off. This can then be detected and trigger the necessary response.
These slotted-opto switches are commonly used in the following:
* In printers as to detect whether there is any paper left.
* In arcade pusher machines to trigger a sound when a coin is inserted.
* In fruit machines as to sense when the wheels have reached their startup positions and to sync the wheels (as to check they're not out of line).
* In traditional mice to detect movement.
* To detect if a moving part has reached a certain place (such as the print head in a printer).
Although more expensive than mechanical switches, slotted-opto switches last longer, require less force to operate but aren't self latching by nature and not as simple to use as the mechanical equivalent.
Slotted-opto switches have either four connections, or three if two of the connections are commoned. It may be the cathode and emitter connected together (most likely) or sometimes the anode and the collector. The anode, cathode, collector and emitter may be marked on the body of the slotted-opto switch (as A,K,C and E respectively) or you'll have to try out the different combinations as colour coding where wiring is concerned is hardly trustworthy.
There are also reflective opto-switches which are made very similar to slotted-opto switches but rely on a reflective object bouncing the infra-red beam towards the phototransistor. And finally, an opto-isolator has both a photodiode and phototransistor housed in a chip-like package, isolating two separate voltages yet allowing one voltage to affect the other, much like a relay does in that a small voltage triggers the relay, causing it to turn on a much higher voltage.
I hope it's becoming clear that the solid state versions of the mechanical equivalents are so much better, partly due to the lack of moving parts (hence solid state) that wear out with mechanical switches and relays. However, as great a keyboard would be made up of solid state switches, it would be too expensive and require more power than an ordinary keyboard, so there are still many valid reasons to use mechanical switches.
As already mentioned with regards to LED's, applying too high voltage or current to a diode in forward or reverse biased mode can damage it. LED's, just as with ordinary diodes, can be damaged if exposed to too much heat, so when soldering also use a heatsink with these and other semiconductors or failing that, be lightning quick!
Transistor: Probably one of the greatest inventions ever, the transistor has made possible the miniaturisation of electronic devices like radios, cassette players and so on. A transistor is a three terminal component which acts as a switch in that it controls the flow of electricity much like a diode, and also serves as an amplifier. Transistors are designed to be either best at switching current or amplifying though there are so called general purpose transistors that are average at both jobs.
The decision making logic gates that have made possible the computers of today are made up of many transistors that switch on and off rapidly as to make calculations and to store data. This digital control of data is how binary values are manipulated as it is easy to handle just ones and zeroes.
When a transistor is used as an amplifier, it controls the output so that it is a larger but faithful representation of its smaller input. Thus a transistor cannot deliver current that doesn't exist, it simply controls the available current according to the input signal. Usually the term amplifier is used to mean in general equipment that produces a louder replica of the original sound coming from something like a microphone, whereas the 'amplifier' will actually contain many transistors working together in addition to other, different components.
How well a transistor increases the power of an input signal that it delivers at its output is known as its gain, the ratio of ouput to input.
Microchip: Better termed the Integrated Circuit or IC, it is an electronic component that contains hundreds, thousands or more miniature components connected on a microscopic scale. Thanks to these chips handheld devices more advanced than the computers that once filled an entire room are so common we perhaps couldn't imagine a life without them. Although not every component can be scaled down as to fit inside an IC, and some components have to be emulated by others, transistors especially can be packed onto the silicon chip with thousands more.
(pic to be added)
Shown on the left are a number of chips, those that have connections parallel to each other of two sides are known as Dual in-line (DIL) or Dual in-line package (DIP). There is also a can IC which is an amplifier, these can chips are rare nowadays but this type of package is still used for transistors.
IC's actually look bigger than they really are, the slice of silicon is tiny but it has to be fitted inside a much larger package as to provide connections and protect the circuit from dirt and other damage. Microchips can have anything from three connections to 40 or more and are most often square or rectangle shape but can be mounted on the circuit board and covered by a blob of plastic; these type are common with electronic toys and watches.
It's easy to split microchips into two different types, they are analogue and digital. Analogue IC's specialize in amplifying and voltage regulation while digital chips cater for control circuitry and memory solutions. A typical computer will contain lots of microchips working together to direct and manipulate data, the Central Processing Unit or CPU is one of the most famous and important, though it would not be able to do much without one or more memory and control chips as well.
Basic Tools
Common tools such as screwdrivers, pliers, wire-strippers and the like are very handy and should be in your tool box, but more specific to electronics is a soldering iron and desolder pump. A soldering iron is used to melt solder as to fix the components of a circuit to a circuit board as well as to make an electrical connection thanks to solder being an electrical conductor. Soldering irons reach very high temperatures so should be handled with care; you can start off with a cheap one costing as little as £5. However, once you get serious you should consider a more expensive soldering iron which has a feature to adjust the temperature of the iron.
Please keep in mind that soldering is a skill and requires plenty of practice, and there will be times when you'll make a mistake. For example, if you apply too much solder to a joint it may overflow onto another joint and cause a short circuit; this is where a desolder pump is a life saver. Using your soldering iron you need to heat up the solder until it melts, hold the desolder pump in your other hand (or someone else's) close to the solder and release the mechanism which will suck up the solder. There is even a combination of a soldering iron and desolder pump known as a desoldering iron, but this is helpful when you need to only desolder components not when you're soldering comonents in a circuit as well; you should use a separate desolder pump if you mess up.
On the left in this picture is a temperature controlled soldering iron, a dial is used to vary just how hot the iron gets. When it is not needed for a few minutes the temperature can be turned down as to put less stress on the tip and be less dangerous to touch. As soon as it is needed again to finish the job the temperature can be turned up again and it will only take a few moments to warm up unlike an ordinary soldering iron (as seen on the right) which can only be turned on and off, thus creating longer delays waiting for it to warm up.
(pic to be added)
***Important! Soldering irons reach very hot temperatures which can cause painful burns if the tip is touched. Always be careful and never leave a soldering iron where others could reach it, escpecially children.***
Usually provided with a typical soldering iron stand is a sponge which should be soaked with distilled water for cleaning the tip, never use ordinary water from a tap because it can destroy the tip.
***Please be aware that it is important to only use lead-free solder, many places will now only stock this option. The lead that was used in the original type of solder can be harmful to people as well as the environment.***
To solder, insert the component's leads into the holes provided by the circuit board, you may need to clip it down or bend its legs slightly to keep it into place. Heat up one side of the lead with the soldering iron and then apply a small amount of solder at the other side. The solder should flow around the lead to both sides in a few seconds which is when you can remove the soldering iron before soldering the other connections. It's important to wait a few seconds before removing the soldering iron otherwise the joint may end up bad, you must also clean the tip of the iron and the circuit board itself before use.
Storage boxes are ideal for keeping your components safe and together. In this container I have polarized (electrolytic) capacitors, non-polarized capacitors, resistors and some transistors.
Below we have from the top a battery powered soldering iron that runs off three AA batteries (4.5V) and below it, a desoldering pump. Next is a solder dispenser tube and at the bottom in the middle is a tin of cleaning mixture wich also applies a small amount of solder to the soldering iron tip at the same time. Finally, either side of the tin are several crocidle clips which are useful for keeping things in place, for making temporary electical connections and to act as heatsinks to protect components from damage when soldering or desoldering them (diodes including LED's, transistors, IC's and the like).

A collection of handy tools are on display in the photo above all of which can be bought cheaply from plenty of shops. Common tools such as scissors, and tweezers (common if someone in your household collects stamps) are nedded frequently. Even nail clippers; I find them good for cutting off a small amount of a wire in an awkward place. And then there are the more specific electronics tools such as wire strippers and a desoldering pump.
(pic to be added)
Stripboard (a.k.a. veroboard or matrix board) is one type of circuit board used by electronic hobbyist, on the underside it has rows of copper tracks that carry the current from one component to another. It is necessary to break some of these traks depending on the circuit, this requirement can lead to problems such as shorts as well as limiting how small a circuit can be made. After cutting a track it should be checked visually and then with a continuity tester or multimeter on ohms range to make sure the track really is broken.
A better version of the normal stripboard a shown in the photo above has tracks already broken at regular intervals, designed especially for DIL IC's. Finally, though not a type of stripboard, the smallest piece (above) has no copper tracks, instead the componets are connected to one another using their leads and wires; the circuit board only holds them in place. This type of circuit arrangement is sometimes called nesting and certainly for manufactured products, is a thing of the past.
Printed Circuit Board (PCB) is what the professionals use but is somewhat expensive for amateurs to use; the tracks are etched away by a chemical. Much more sophisticated circuit designs are possible with PCB's than with stripboard and software has to be used to create the layout of the tracks for the really complex circuits.
You will also need to obtain measuring devices; a multimeter is essential, as it'll allow you to measure voltage, current, resistance and so on. These are on sale cheaply when only basic functions are offered but shoot up in price when you want a more advanced version such as one that can measure capacitance, inductance and frequency. You can manage with a simple multimeter if need be as other features can be emulated, for example, if your multimeter lacks a continuity (a good connection) test, you can use a resistance test on the lowest range.
Multimeters are divided into two main types that will affect its cost and slightly, how it can be used; they are analogue and digital. Analogue multimeters use a form of display that makes use of a needle that moves across a scale which isn't as clear to read as a digital multimeter, and the analogue versions tend to be more expensive. Digital multimeters on the other hand have an instantly recognisable (usually) LCD display and have a much higher input impedance (it will have little affect on the circuit under test).
That said, analogue and digital multimeters have their advantages and disadvantages. When you want to check for changes as they happen most digital multimeters are too slow to react in time, but with the analogue type you will be able to watch the needle move in time with the change in voltage, current, etc.

A basic digital multimeter is shown in the picture on the left with the two test leads, coloured black for negative and red for postive. This multimeter didn't cost much and can measure voltage, current and resistance, and is able to test bipolar transistors, and diodes.
The digital multimeter on the right has similar functions to the other one with the addition of an audible continuity tester and it also has a clamp at the top allowing for AC measurements to be made without connection to the wire from the circuit under test (the wire passes through the clamp).
As eager as you may be to arm yourslef with a soldering iron and create a project, there will be times when you'll need to test a circuit before soldering to make sure it works as it was designed. This is where a breadboard (made from plastic nowadays instead of the wooden boards used once upon a time where the term breadboard originates from) is used or prototype board as it is also known; and better explains what it is used for. A breadboard has many holes across its surface in rows and columns like stripboard, connected together internally.
A small piece of breadboard as seen left sitting on top of a much larger version. The big breadboard has enough space for several circuits or a large one such as a simple computer. It also has four coloured sockets intended for plugging in the power supply jacks or signals of some sort.
You insert the components of the test circuit into the holes of the breadboard, using single starnded wire to act as jump leads (multi-stranded wire can be used but is not advised because of the risk of wire strands that can fall off and get stuck in the holes). There will be a number of breaks so that IC's and other components can be used and maybe a couple of connectors for wiring to the battery or other power supply that you're using. Some small breadboards have the ability to be slotted together as to form a much larger piece of breadboard suitable for bigger circuits.
When you've finished testing you can then go ahead and make a more permanent version of the circuit, now sure of what components you need and how to put it together. But breadboard can be used for more than just prototyping ideas, it is great for learning how electricity behaves by wiring simple circuits on the breadboard and measuring voltage, current and so on at specific points.
Active and Passive Components
Passive: A component which is able to operate on a signal without any additional power and cannot amplify. This includes resistors and capacitors.
Active: As an opposite to passive, active components require power other than that provided by the input or control signal and produces power gain of some sort. A good example is the transistor.
Power
Components that get too hot will stop working or not perform as well as they should or will suffer damage; even components designed to handle a lot of power. To safely get rid of this heat, heatsinks are used, large pieces of metal attached to the surface of a component usually by a bolt and nut, and often heat absorbing glue. Some heatsinks that are on the big side are shared by more than one component, an example of which can be seen in the picture below.
(pic to be added)
Small and large heatsinks are shown in the photo on the left, with holes to screw components onto of the power type.
Since heatsinks are made from metal they will conduct electricity as well as heat and this can be used as an advantage. Components such as transistors and some IC's have an area of metal exposed as part of their body which is internally connected to one of its leads. If this makes contact with the heatsink, the metal of the heatsink can be used to make an electrical connection with other components mounted to the heatsink. But, if this should not happen in the case of what would be a short, an insulator such as plastic must be placed between the component and the heatsink, using a plastic screw as well. Some heatsinks are painted black (as to help dissipate the heat) so those types should not conduct electricity. Some heatsinks which are used as a conductor of electricity as well as heat have 'feet' which are soldered onto the circuit board as you would do with a component like a resistor, for example.
(pic to be added)
As can be seen in the photo above are four components each mounted to its own heatsink; the white stuff is heat transfer glue. You may be surprised at how big some of the heatsinks are compared to the actual component but even small devices can get very hot as current passes through them so they must be kept cool. As for the white, lone component on the left that's a power resistor (without a heatsink) much different in construction to your average low power resistor. All of these components were obtained from CRT TV and monitor equipment where high voltages and high power are the norm.
LCD Modules
Liquid Crystal Displays (LCD) has many advantages over other forms of display, for one thing they use very little current and because of that they have found themselves in many portable devices. That said, LCDs often require back lights and can be more difficult to use than other display technology such as LEDs.
It's just as well that Intelligent LCDs were invented, which can use either a parallel or serial interface, and are designed to help out the user with displaying information on an LCD. The text only intelligent displays usually have a built-in character generator and accept a limited amount of commands to scroll the display, move to a set position, and so on. This 'intelligence' is thanks to one or more controller chips that are part of the LCD module, handling both input from the 'outside world' and updating the LCD.
The parallel intelligent LCDs are easy to use to the point that for testing purposes you can get one to display characters by using just switches! They usually can be used in either 4 or 8-bit mode with the 4-bit mode requiring that both halves of the data be sent one after another but having the advantage that half as many connections are needed. But those with a serial interface are more difficult to program but have the big advantage that fewer wires are needed between the LCD module and the microcontroller or microprocessor.
An example of a Serial LCD Module
I took a bit of a risk when I bought online an LCD module that I knew nothing about but eventually I got it working. It's a sixteen 7-segment LCD module with what look like 16 commas, and has the numbers 35 209 16170 written on the board. The only clue to getting it working (and I do like a challenge!) was the two PCF2111T chips which so happen to be LCD drivers.
Having found a pdf data sheet about the LCD driver ICs I did a pinout of the LCD module connector which has no indication of the pin markings but the leads are all grey except for one red one.
(Red) Data input line enable DLEN (CBUS) 1
(Grey) Data input line enable DLEN (CBUS) 2
(Grey) Data input DATA (CBUS) 1 and 2
(Grey) Clock burst input CLB (CBUS) 1 and 2
(Grey) VDD (2.25V to 6.0V)
(Grey) VSS (0V)
Each LCD driver chip controls half of the display (i.e. eight 7 segments and eight commas) and just to complicate things a bit more you can only alter half of those segments at once. So, to update the entire display you would need to write to the LCD module four times. This is because one LCD driver has two latches and you can only select one or the other:
* The A latch is responsible for the segments a, b, c and g.
* The B latch is responsible for the segments d, e, f and comma.
This was assuming the usual labelling and that I had the display the right way up, but which way is the right way up depends whether you want the commas to be commas.
This LCD module isn't intelligent and requires a lot of hard work from the user; basically you send a pattern of bits using the DATA signal which, as well as turning on or off the segments, selects which latch you want to use that data. The DATA and CLB (clock) are common to both of the LCD driver chips, which of the two chips you want to receive the data is selected by taking either of the DLEN signals high.
I tested the LCD module using the parallel port of my PC which may seem a strange choice but it was the most easy for me to use. I powered the display using a 5V PSU and connected the power, display and parallel port to a common ground (0V) connection. Using C++ to 'talk' to the LCD module, the reason it took me so long to get the display working was the problem of sending the correct sequence of bits. The PCF2111T chips are 34-bit but, as suggested in the data sheet, you have to send a leading zero which is one of the conditions the LCD driver chips look out for to know when the start of a sequence has begun.
When I had finished the code I was impressed that the entire display updated very fast as I used no delays which I would have had to had it been an intelligent LCD. But it was just as well the LCD module responded as fast as it did as I had to do a lot of converting and such to send parallel data in serial form.
Since you can only display a limited number of characters using seven segments but I wanted to be able to use the String class, I tetsed each character in the string and if it was one that could be displayed on the LCD I converted the ASCII value to the correct idex. This index was used to look up which segments are lit or not lit for each character stored in the array.
For the characters that couldn't be displayed on the LCD I instead sent a space character to be safe but you could use another character if you wanted to. And if there were less than 16 characters in the string, spaces were padded onto the end so that the whole display was always updated.
If you want to show numbers on the LCD it's a simple matter of converting the number variable into String form which even takes care of the minus sign for negative values (as soon as I had added the minus sign in 7-segment form). Originally, as another test, I wanted to display a sum on the LCD and the result but a plus symbol isn't possible using 7-segment so I did a minus problem instead.
It's a good idea to put the coding into a class so that any program that wants to use the LCD module can and won't have to worry about knowing how to use the LCD; you'll also save on code as well be reusing it. You will need only provide public functions to allow the program to display data on the LCD module, keeping everything else private.
The PC Parallel Port
The Universal Serial Bus (USB) has become the standard form of interfacing devices to a computer but once upon a time the parallel port had anything from printers to external harddrives connected to it. Parallel ports are great for people into electronics as they are fairly simple to use and have a good number of inputs and outputs to use. However, most computers nowadays are made without a parallel port thanks to USB's popularity but you can buy a USB to parallel port adapter, but they aren't that cheap and because they are designed with printers in mind they lack the bidirectional capability of the original parallel port. So an old computer will be sure to have a parallel port, and if you have a printer cable for it you can use that for your parallel port projects.
The PC parallel port was originally designed for printers exclusively and despite some changes over the years, there remain a number of inconveniences to make note of. One of which is that the parallel port provides no power other than that which can be obtained from the outputs, only enough to light an LED. This means for some projects you'll need to use a battery or wall adapter to provide the extra power; only the power supply's ground (OV) is connected to the parallel port's ground connection as to act as a common.
The parallel port is controlled on the software side by use of three I/O ports at the CPU's command. The port address is different depending on the hardware configuration, but it is assumed here that the base address for the first (and possibly only) parallel port you're using is at port address 0x378. This is where you'll find the parallel port's data port, which has 8 bits that can be programmed to act as either all inputs or all outputs.
0x378 (Base address) Data Port
Bit # Use
7 D7
6 D6
5 D5
4 D4
3 D3
2 D2
1 D1
0 D0
Whether the data port's bits act as inputs or outputs depends on the state of bit 5 of the control port (see below).
The status port is read to learn the state of the six inputs to the PC provided by the parallel port, the status port also contains two reserved (unused) bits that can be ignored.
0x379 (Base address+1) Status Port
Bit # Use
7 Busy
6 /ACK
5 PE
4 Select
3 /Error
2 /IRQ
1 (Reserved)
0 (Reserved)
In case you're wondering, the names assigned to the bits are those used for printers such that PE stands for Paper Error but you can use them how you like with the one exception of /IRQ which does trigger an IRQ, if enabled. The '/' before a bit name means that that bit is active low, it is inverted by hardware but you can easily remedy that in your program, or it may actually help. The reason for the active low signals is so that when a printer wasn't connected to the PC's parallel port or was turned off, the inputs would default to safe conditions (i.e. no errors since the printer isn't on).
Last we have the control port that has two reserved (unused) bits, 2 control bits and 4 outputs from the PC via the parallel port.
0x37A (Base address+2) Control Port
Bit # Use
7 (Reserved)
6 (Reserved)
5 Direction
4 IRQ enable
3 /Select In
2 INIT
1 /Auto Feed
0 /Strobe
The direction bit (5) when set forces all the bits of the data port to function as inputs. When the direction bit equals zero, the data port goes into output mode. As for the IRQ enable (4), IRQ for the parallel port is enabled when the bit equals one, but IRQ is disaled if this bit is zero.
PC Parallel Port to Parallel Intelligent LCD Module
This is great for testing out a so-called intelligent LCD which is nothing more than an LCD and dedicated controller chip on board, but does a lot of the hard work of working an LCD, especially one which is capable of at least limited graphics. This means you can interface the LCD module to a PC's parallel port with not too much difficulty and once you have the software done, I'm sure you'll find many uses for it.
Intelligent LCD modules can be divided into two main types and they are those which can display only characters with very limited graphics by creating your own characters and the ones that can display graphics as well as text which can be of different sizes and styles. I'll be discussing the character only type below as they are the simplest to start with yet have many uses.
The LCD module that I used for this project came from a chucked out fax machine, and was made by Sharp with the code F2631XH-44 written on the circuit board. It uses the SEC C748B chip, compatible with the industry standard so I was able to use it without any trouble. It is made up of two lines that are each eight characters long but instead of one line below the other they are side by side. In other words, when the two line mode is enabled for this LCD module it is actually a single line with 16 characters.
Another suitable intelligent LCD, which came from a security alarm (that was not needed!), is a Winstar WH1602B and has 16 connections, the extra two (15 and 16) are for the LED backlight. This LCD module has two lines that are 16 characters wide, one below the other. Obviously the more characters that can be displayed at once the better but the software will have to be adjusted accordingly. It can be a little tricky to use both lines as you have to tell the cursor to move to the start of the next line at a certain position and before that you have to enable two line mode (as already explained may be just an extension of the single line).
Although these LCD modules have an 8-bit interface which is ideal for your average CPU, microprocessor and parallel port the LCD can be be forced into 4-bit mode. In 'nibble' mode you have to send one half of the byte after another which may seem a pain but the advantage is that you only need four connections (not including the other signals) instead of eight.
(pic to be added)
The circuit shown above illustrates the wiring needed for interfacing an LCD module to a typical PC parallel port. You can power the LCD module using a battery or batteries, or a wall adapter; this power supply's ground (0V) connection has to be connected to the parallel port's ground signal. The LCD can run off lower than 5V (a 4.5V battery is very handy) but you will need to use pull up resistors for D0-D7 and possibly the other connections to ensure that the parallel port gets the right voltage levels for logic 1 and 0. Actually, the LCD and the controller chip that's part of the module can work down to a tiny voltage, I've noticed that amazingly it can get power from the parallel port's signals (though the characters will be very faint). This means that you need to remove the LCD module from the parallel port (just remove the ground connection) as well as the power supply to completely turn the LCD off.
When power is applied to the intelligent LCD it starts off with the display blanked (though commands can still be sent to it such as to put it into two-line mode) but you may still see a number of blocks. If you do, then you'll need to adjust the contrast (VR1) until the blocks vanish, but not too much. The variable resistor can be replaced with a fixed reistor, as soon as you have found the right setting you can measure the variable resistor's resistance with a multimeter (when the power is off) on the ohms range to determine the value to use for the fixed resistor. Or you can use a preset variable resistor which can be adjusted once; please be aware that two-line mode requires a different level of contrast compared to just one line.
It is a good idea when testing an LCD module for the first time to set up the hardware using breadboard. Some intelligent LCDs have a ribbon cable connected to them others have a row of 'legs' which can more easily be inserted into breadboard. I used an old printer cable I didn't need and removed the centronic connector so that I could more easily use that end for interfacing with the LCD via breadboard.
When the hardware has been set up, you'll need to write the software to control the LCD, an example program I wrote in C++ follows. I used a Borland compiler which had no parallel port access functions so I used direct access by incorporating a couple of lines of assembly language amongst the C++ coding. With modern operating systems this is not a good idea and will not work with Windows 2000 or higher. Therefore you may want to explore better alternatives for accessing your computer's parallel port, on your PC (for Windows 2000 and above you can download software to grant you access to the parallel port or you could use a special driver).
//PC parallel port to LCD module
//By James S.
//Uses LPT1
const dataPort=0x378; //LPT1 data port
const statusPort=0x379; //LPT1 status port
const controlPort=0x37A; //LPT1 control port
const dataPortDir=0x20; //LPT1 data port I/O mode
const ctrlINIT=0x04; //LPT1 control port INIT o/p
const ctrlSTROBE=0x01; //LPT1 control port STROBE o/p
const LCDclr=0x01; //Clear LCD command
const LCDonULBlinkCur=0x0f; //LCD on with cursor underline and blink command
const LCDoff=0x08; //LCD off command
bool LCDon; //Is the LCD on or off?
void writeCommand(byte data); //Write command byte to LCD
void writeChar(byte data); //Write character to LCD
void writeCtrlPort(byte data); //Write byte to LPT1 control port
void writeDataPort(byte data); //Write byte to LPT1 data port
__fastcall TMainForm::TMainForm(TComponent* Owner):TForm(Owner)
{
LCDon=false; //Assumed LCD is off
}
void __fastcall TMainForm::LCDOnOffClick(TObject* Sender)
{
LCDon=!LCDon; //Toggle LCD on/off
if (LCDon) { //LCD to be turned on
writeCommand(LCDonULBlinkCur); //Turn on LCD
LCDOnOff->Caption="Turn LCD off";
}
else { //LCD to be turned off
writeCommand(LCDoff); //Turn off LCD
LCDOnOff->Caption="Turn LCD on";
}
}
void writeCtrlPort(byte data) //Write byte to LPT1 control port
{
_DX=controlPort;
_AX=data;
__emit__(0xee);
}
void writeDataPort(byte data) //Write byte to LPT1 data port
{
_DX=dataPort;
_AX=data;
__emit__(0xee);
}
void writeCommand(byte data) //Send command to LCD
{
writeCtrlPort(0); //Set data port to o/p and LCD to command mode
writeDataPort(data); //Write command to data port
writeCtrlPort(ctrlSTROBE); //Take LCD enable low
writeCtrlPort(0); //Take LCD enable high
}
void writeChar(byte data) //Write character to LCD
{
writeCtrlPort(ctrlINIT); //Set data port to o/p and LCD to character mode
writeDataPort(data); //Write char to data port
writeCtrlPort(ctrlINIT|ctrlSTROBE); //Take LCD enable low
writeCtrlPort(ctrlINIT); //Take LCD enable high
}
void __fastcall TMainForm::sendCharClick(TObject* Sender)
{
//Send character to LCD
int byte=StrToIntDef(charIn->Text,0); //Get character code
writeChar(byte);
}
void __fastcall TMainForm::clearLCDClick(TObject* Sender)
{
writeCommand(LCDclr); //Clear LCD
}
(pic to be added)
The LCD module, above, connected to breadboard as well as the cable from my computer's parallel port. The blue component is the preset variable resistor used to adjust the contrast of the LCD, the exact contrast setting will depend on the surrounding lighting conditions and the number of characters that can be displayed on the LCD (that is, the contrast will have to be changed when using two-line mode instead of one line).
The intelligent LCD will miss commands or characters if received too fast, you can check the module's busy flag to see if it's ready to accept more data but it's simpler just to wait a specific amount of time between sending data. Reading the busy flag requires use of the LCD's R/W line and that would need an extra output from the computer you are using. It's better to keep the R/W input connected to 0V so it's always in write mode and wait a short amount of time before sending the next byte to the LCD.
Using a for loop to create a delay isn't a good idea since the length of delay would be different on a faster or slower computer. Instead, use a timer component which will be responsible for outputting commands and characters to the LCD.
Project: CAT
The Computerized Anthropomorphic Toy, or CAT, is my attempt at a virtual pet but instead of existing purely inside a computer, it has a more touchable exterior. Inspired by the Nintendo Wii's remote that ignores the more traditional forms of input to video games and instead provides a more realistic interface, CAT has sensors to allow you to interact with her.
To start this project off I will outline how CAT is made up so that you can better understand what makes this virtual pet unique. CAT talks to you using an intelligent LCD (the alphanumeric type is fine), this is positioned at the mouth area.
CAT's eyes are tri-colour LEDs to indicate her current mood; when yellow she is neither particularly upset nor happy, when green she is happy and when red CAT is angry. Also, when the LEDs are lit she is awake and when they are off (showing no colour) CAT is sleeping.
As a form of input, CAT's whiskers can be pressed, she can detect whether you're touching her left or right whiskers. You could use ordinary switches for the whiskers but I prefer slotted opto switches since they are more reliable at the cost of a few extra components (i.e a transistor and a couple of resistors). When awake touching CAT's whiskers will cause her to comment and touching them when she's sleeping will wake her up.
No cat would be complete without a tail and in CAT's tail she has a temperature sensor (a thermistor) so that she can make remarks about how hot or cold she is. The tail module will require an ADC (Analogue-to-Digital Converter) to convert the temperature signal which is analogue to a digital signal that the computer understands.
Build Your Own Arcade Machine
This may seem a difficult and expensive task yet it's not too hard provided that you have a spare computer and the skill to work with both software and hardware. Video game consoles today are very much computers, the X-Box was just a modified PC in a different case and that's the general idea here (those booths that take your photo are just a PC and not much more).
To those who play your arcade machine it will appear just that, but open it up and you'll be exposed to the computer that you use to program the games machine. It will require you to be able to put a computer together which can be placed inside a custom case, one made out of wood shouldn't be too difficult to put together or you could get someone else to make it for you (as was the case with me).
I advise that you use a wireless keyboard and mouse, that way you can keep the arcade machine as just that but still be able to program it, remotely. That way the receiver can be hidden inside the arcade machine's cabinet and the people who play it will be none the wiser.
You'd think that using a PC would mean that all the hardware is done and that you only have the software to write, well you're wrong! To give as real feel to the arcade machine as possible you'll need to connect the joysticks, coin detector, credits display and so on to the computer and that will be challenging. You'll have to look at the ports available to you on the computer and determine the best ways to interface them, that's when you will have to design and build a fair amount of circuitry.
For my arcade machine it contains the motherboard, PSU, floppy, and CD-ROM (all within the tower) and monitor that make up the actual computer. All but the monitor are hidden but are accessible when programming the machine, you can cut out a hole in the front to expose the monitor's screen. Remember to use fans to cool the motherboard (if there aren't any in the case) and at least cut holes to allow the heat from the monitor (especially if CRT) to escape from the case. If you want your arcade machine to have sound then you'll need some computer speakers (i.e. amplifiers), mine are actually built into the monitor which saves space and a power cable.
You don't want several mains power cables trailing from your machine so you'll need an adapter of some sort to have just the one powere lead. Some computers allow you to connect the monitor to the PSU but even so unless the speakers are part of the monitor or have a special connector to be used at the PSU, another cable will be needed.
It would be ideal if you use a motherboard that has the graphics and sound adapter built in otherwise you'll have to connect them as card adapters, although that generally gives better performance. But, the disadvantage of the all-in-one type of motherboards is that they can be a pain to get drivers working for them and older versions of Windows don't help with this (assuming you're using Windows).
To make a sensor that can detect different types of coins is something that most of us won't be able to manage, of course if you can get your hands on an actual arcade coin detector then it's done for you. A simple way, though it won't be able to tell the difference between different types of coins, is by using a slotted opto-switch which the coin passes through briefly. The coin, or anything opaque which passes through the coin slot, will briefly block the infra-red beam produced by the opto-switch which then can be sensed to increase the credits; this will act like a clock pulse.
You'll only need a simple transistor switch for the slotted-opto switch, the circuit I use I've seen in coin pusher machines at the arcades as to activate a sound when the coin passes, with the difference that the slotted-opto switch is used more like a traditional switch for some of the coin pusher machines. If you want to be able to give yourself free credits without inserting a coin you can use a normally closed microswitch which disconnects the photo diode part of the slotted-opto switch since that will have the same effect as the coin blocking the infra-red beam from the photo diode. Just remember to hide the switch inside the machine otherwise no one will pay! For test purposes it's a good idea to include an LED (with limiting resistor) at the output of the coin detector circuit; the LED should blink whenever a coin makes its way through the slotted-opto switch.
The signal from the coin sensor can then be fed to the computer, perhaps to one of the parallel port's inputs. You could then display the player's credits on the computer's monitor but to get a more arcade look a couple of LED displays would be better for showing how many plays are left. I've seen real fruit machines that use a monitor that have LED displays for showing the remaining credits. And nothing looks better than giant LED displays, if you can get your hands on one or two (but be aware that larger LED displays work on a higher voltage, say 5V per segment, instead of 2V for a standard LED).
Just one LED display isn't enough as that will only allow for up to nine plays, but two is fine as they will handle a maximum of 99 credits. For each credit display you will need a BCD-to-7 segment decoder/driver and a BCD counter that can count up (when a coin is inserted) and down (after a play is used). It may seem obvious to connect the coin detector to the first counter but it's actually better to allow the computer to clock the counter. For one thing, after a play the counter needs to be clocked down so that will have to be done by the computer. Secondly, by granting the computer control over the counter it can award credits to players perhaps for completing a game without loosing a life, for example.
The first counter, which will be responsible for the least significant digit for the credits needs to clock the second counter that takes care of the most significant digit (assuming two displays). Depending on the counters you use this can be done using the carry out and carry input signals that most counters have while having the clock signals connected together.
So, the computer needs to be able to reset the counters (so that they start up in a known state for one thing), it has to clock the counters and finally it has to be able to select whether the counters count up (increase credit) or count down (decrease credit). There are a few output only signals from the parallel port that you could use to reset, clock and select if the counters count up or down. If the counter you are using doesn't have a reset input but preset selections instead then you'll need to connect all the presets inputs to 0V and use the preset enable (maybe called parallel enable/load or something similiar) to reset (to zero).
I recommend using 4029 counters as they can count up and down, and 4511 decoders for the 7-segment LED displays. Speaking of which, if you are using large LED displays then you may have to run them off a higher voltage (with suitable limiting resistors) so you can use the 12V that a PC provides. So using CMOS IC's such as the 4029 and 4511 is a good idea as they can cope with 12V.
If you are using something like a slotted-opto switch to detect a coin then you'll need to 'debounce' it otherwise as the coin passes through the sensor it will be detected multiple times. You could debounce the sensor in hardware but it's easy enough to do in software.
The method is the same as what you would do to stop a character in a game from continually jumping if the jump button was held, you'd wait for the jump button to be released first before making the character jump again. For the coin, make sure that first no coin has been detected (or that one has passed the sensor) and when a coin has been detected, increase the credits and set a flag so the credits aren't increased again until no coin is detected. If coins are inserted too fast they might not both be detected so it's a good idea to wait a couple of seconds before putting in the next coin (this is because two coins might go in next to each other front and behind, and seem like one coin to the sensor).
I have a joystick that is styled very much like what you would expect to see on a classic '80's arcade machine, when I can get a second just like the first I can do two player games. You could use the PC's game port connector (if it has one) but I decided to use the parallel port instead as it's simple to use. The joystick has the usual four directions plus two independent fire buttons and also for player one there are two extra trigger buttons mounted separately to the joystick. This totals to 8 buttons which is just right for connecting to the parallel port's data port, though if you have two joysticks you will have to multiplex them or switch between the two.
But there is a slight problem, the parallel port's data port defaults to output before any software can change it to input (most likely because the parallel port was originally designed with printers in mind). If someone was to press a button or the joystick before the data port was changed to input, the port signals would be shorted to ground and could damage the parallel port.
The work around is to connect a resistor of around 330R (a higher value won't allow you to detect multiple button presses) between the switches' common connection and ground. If a button was pressed while the data port was in output mode the resistor would be connected to 0V and limit the current, protecting the parallel port. Then your software can change the data port of the parallel port to input to read the state of the joystick switches.
The advantage of connecting the joystick and fire buttons to 0V is that there is no need for connection to +5V which isn't provided by the standard parallel port. However, this means that the switches will be inverted, that is, a button press will be detected as logic 0 and no button press as logic 1 but that can easily be changed with software. The parallel port's data port set as inputs float to logic 1 so there should be no need to add your own pull-up resistors.
Above you can see what my arcade machine currently looks like. It has a wooden case with metal air vents at the top, two giant LED displays for credits, the joystick on the left, and not visible in this picture is a key switch lower down for free credits.
Inside Sega's Turbo Out Run Arcade Machine
In England where I live we are fortunate to have a good selection of arcade machines ranging from the classics such as Sega Rally to the more recent House of the Dead 4. But never did I expect to stumble upon Sega's Turbo Out Run at a carboot sale! It had been dumped, was in a bad state, and far too big to take home so I removed from it probably the one usable item-the mainboard.
I have memories of playing Out Run not so much at the aracades but at home on my Amiga 500; the Amiga version came on a single floppy. Not only does the game have great graphics and tunes, it allowed you to select your own route unlike so many other racing games at the time. So I was delighted to see a 3D version appear recently in the arcades and on some video game consoles, anyway, back to this classic...
(pic to be added)
There was actually two mainboards, one circuit board plugged into the one below it. I was amazed at just how many chips had been used especially of the memory type, with spare sockets for more but I had to remind myself that it was made before the 90's.
(pic to be added)
Corner of the top mainboard showing the Out Run sticker. The copyright date is 1986. This is becaue Turbo Out Run, the unoffcial sequel, runs on the same hardware as the original Out Run, explaining the earlier date of '86.
The mainboards were screwed into a large metal case with holes most likely to allow for heat to flow through. Around the top mainboard are various connectors which were fixed to a smaller board that had leads running from it at the other side rather than simply make holes in the metal casing for the wires.
(pic to be added)
Closeup of the top mainboard showing the CPU.
The Turbo Out Run machine uses a 68000 16-bit CPU, socketed on the mainboard (actually there's a second, not so obvious 68000 also). It's quite unusual to not solder the main CPU directly to the circuit board but the advantage of using a chip socket instead is that it can easily be replaced or even swapped for a better, compatible version.
(pic to be added)
An army of memory IC's.
The bottom mainboard has even more memory chips in sockets than the top mainboard, though there are some empty sockets. Some of the memory IC's are the type which can be erased by exposing the window (hidden with a sticker) to ultraviolet light; this was a popular method to program chips at the time whereas today flash memory is the norm.
(pic to be added)
The bottom mainboard.
Both of the mainboards measure at 30cm (approx. 11.625 inches) by 31cm (approx. 12.375 inches) not including the connectors sticking out.
Now for a listing of every IC that was used on both mainboards:
Number in brackets is how many pins the IC has.
CH means a chip holder was used.
N/U indicates that the chip is referenced on the board but no chip is used there.
? means the chip number cannot be read or the number is not printed on the circuit board.
Mainboard 1
IC1-IC2 74LS157N (16)
IC3 74LS151P (16)
IC4-IC6 74LS244N (20)
IC7 74LS109AP (16)
IC8 74LS273N (20)
IC9-IC10 74LS174N (16)
IC11 27C256-20JL (28) CH
IC12 PLS153N 2188L15 (20) CH
IC13-IC14 74LS174N (16)
IC15 74LS112P (16)
IC16 74LS04N (14)
IC17 74LS399N (16)
IC18-IC19 74LS245N (20)
IC20-IC21 UM6116K-2 (24)
IC22 74LS244N (20)
IC23 74LS367AN (16)
IC24 74LS244N (20)
IC25 74LS367AN (16)
IC26 CK2605 218750L (20) CH
IC27-IC28 74LS174N (16)
IC29 315-5155 8727 C49 (20)
IC30-IC32 74LS161AN (16)
IC33 74LS11P (14)
IC34 74LS399N (16)
IC35 74LS155N (16)
IC36-IC37 74LS245N (20)
IC38-IC39 UM6116K-2 (24)
IC40 74LS244N (20)
IC41 74LS367AN (16)
IC42 74LS244N (20)
IC43 74LS367AN (16)
IC44 74LS244N (20)
IC45-IC46 74LS257AN (16)
IC47 27C256-20 (28) CH
IC48 315-5155 8727 (20)
IC49-IC51 74LS161AN (16)
IC52 74LS11P (14)
IC53 74LS04N (14)
IC54-IC55 C5563APL-12L (28)
IC56 N/U 27512 (28) CH
IC57-IC58 27C512P-20 (28) CH
IC59-IC60 74LS245N (20)
IC61 SCN68000CAN64 (64) CH
IC62 AMPAL16R4APC (20) CH
IC63-IC65 74LS161AN (16)
IC66-IC71 27C512P-20 (28) CH
IC72-IC73 C5563APL-12L (28)
IC74 N/U 27512 (28) CH
IC75-IC76 27C512P-20 (28) CH
IC77-IC78 74LS244N (20)
IC79 AMPAL16R4APC (20) CH
IC80-IC82 74LS161AN (16)
IC83 74LS244N (20)
IC84 N/U ? (20)
IC85 74S04P (14)
IC86 74S112N (16)
IC87 UM6116K-2 (24)
IC88 ? (28)
IC89 D780C-1 (40)
IC90 315-5218 (100)
IC91-IC92 UM6116K-2 (24)
IC93 74LS244N (20)
IC94 74S139N (16)
IC95 74ALS138N (16)
IC96-IC98 74LS244N (20)
IC99 74LS32N (14)
IC100 74LS74AN (14)
IC101 74LS04N (14)
IC102 74LS109AP (16)
IC103 74LS00N (14)
IC104 74LS32N (14)
IC105 74LS192P (16)
IC106 MB3771 (8)
IC107 YM2151 (24)
IC108 CK2605 KFH7127 8837K (20) CH
IC109 DAC1022LCN (16)
IC110-IC111 M8848 MF6CN-50 (14)
IC112 74LS137P (16)
IC113 74LS244N (20)
IC114-IC115 C5563APL-12L (28)
IC116-IC117 ? (28) CH
IC118 D27512J-2 (28) CH
IC119-IC120 74LS245N (20)
IC121 FD1094 (64) CH
IC122 74ALS08N (14)
IC123 74LS244N (20)
IC124 YM3012 (16)
IC125 uPC804C 8843A (14)
IC126 D74HC4066C (14)
IC127-IC128 74LS245N (20)
IC129-IC130 C5563APL-12L (28)
IC131-IC132 ? (28) CH
IC133 D27512J-2 (28) CH
IC134-IC135 74LS245N (20)
IC136-IC137 74LS244N (20)
IC138 315-5195 (52)
IC139 uPC324C (14)
Mainboard 2
IC1 74LS245N (20)
IC2 74LS245P (20)
IC3 74LS373N (20)
IC4 HD74LS245P (20)
IC5 74LS245N (20)
IC6-IC8 74LS373N (20)
IC9-IC24 27C512P-20 (28) CH
IC25-IC44 N/U 27256 (27512) (28) CH
IC45 315-5211A (43)
IC46 CK2605 (20) CH
IC47 74LS08N (14)
IC48 SN74S74N (14)
IC49-IC50 74LS367AN (16)
IC51-IC52 TMM2018AP-35 (24)
IC53-IC54 74LS244N (20)
IC55-IC56 74LS245N (20)
IC57 74LS244N (20)
IC58 T74LS374B1 (20)
IC59 74LS244N (20)
IC60 T74LS374B1 (20)
IC61 74LS373N (20)
IC62 HM65256BLSP-10 (28)
IC63 UM6116K-2 (24)
IC64 HM65256BLSP-10 (28)
IC65 UM6116K-2 (24)
IC66-IC81 TC51832PL-12 (28)
IC82-IC84 SN74LS157N (16)
IC85-IC87 SN74LS399N (16)
IC88-IC90 SN74LS157N (16)
IC91 74LS125AN (14)
IC92 TMM2063P-10 (28)
IC93 74LS245N (20)
IC94 D74HC273C (20)
IC95 TMM2063P-10 (28)
IC96 74LS245N (20)
IC97 D74HC273C (20)
IC98 SN74LS241N (20)
IC99-IC101 N/U 27256 (27512) (28) CH
IC102-IC104 27C512P-20 (28) CH
IC105 T74LS374B1 (20)
IC106 315-5197 (40)
IC107 74LS161AN (16)
IC108 SN74LS138N (16)
IC109 SN74LS32N (14)
IC110 HD74S04P (14)
IC111 74LS74AN (14)
IC112 74LS273N (20)
IC113-IC114 HD74LS253P (16)
IC115 74LS273N (20)
IC116 ADC0804LCN (20)
IC117 D4051BC (16)
IC118 74LS14N (14)
IC119 D8255AC-2 (40)
IC120 uPA2003C (16)
IC121 74LS273N (20)
IC122 uPA2003C (16)
IC123 CK2605 (20) CH
IC124 uPA2003C (16)
IC125-IC126 HD74LS253P (16)
IC127-IC130 2501 835 (16)
Recycling
You may not be aware but loads of electronics is wasted all the time, unused and harming the environent when a lot of it could be reused. Sometimes people throw out a perfectly working TV, for example, just because they are upgrading to a better model. And even when somethng electronic has stopped working or has been damaged it may be possible to repair it or re-use some of the components.
It has taken time but now some companies will recycle your unwanted electronics, usualy for free. Or, you could give that item to someone you know could make use of, or you have the option of donating it to charity. For those who build electronic circuits, in addtion to buying new components you can salvage components from unwanted devices. That is something I have done for many years and continue to do so today.
There are two main advantages to recycling electronic components, and they are that you can get them very cheaply or even free and, you may just get your hands on some rare gems that aren't even sold anymore or are but at high prices. Of course second hand components means they won't have as long life as they would have if bought new but that's a small set back and provided you're careful when desoldering, it's not much of a problem especially if they're obtained for free. Additionally, the components will most likely have shorter leads than when they were new but having said that, there are times when the length of some of the component's connections are kept close to the original size.
Often the older goods are better since the circuits aren't so integrated and therefore there are more usable components, and a lot more wire! It can be harder to desolder components from circuit boards which have tracks both sides because there is solder on each of the sides but this is not usually too much of a problem as heating up the solder one side will often melt the solder at the other side. But that said, new electronics still have plenty to offer, it's up to you what you are able to use with the tools and skill you have.
When desoldering, you may come across some components that you are unsure of what they are by just looking at them (for example, inductors can look like resistors when they use colour bands but the rest of their body is often green not grey or white used for resistors).
A component analyzer helps greatly but they're aren't cheap and are often limited to semiconductors. Fortunately, on the circuit board will be markings that give a clue as to the identity of the device, and as for transistors, the manufacturer might have been kind enough to provide a pin-out of the transistor which aso reveals what type of transistor it is.
Some examples of the abbreviations used to reference components on a circuit board are:
T For transformer or could be transistor.
TR or Q for any type of transistor.
D for diode even an LED, otherwise LED or just LD for an optical diode.
C for capacitor, polarized or not.
R for a fixed resistor.
VR for a variable resistor and PR for a preset variable resistor.
J or JP for a jump link, a small length of wire with or without insulation to connect two tracks together on a circuit board (as to avoid running into another track that would otherwise cause a short).
IC for an integrated circuit, better known as a microchip.
VC for a variable capacitor.
C or CN for a connector.
L for an inductor.
So, D56 would be the 56th diode which would then be referenced to on the circuit diagram (if you had access to it). However, sometimes the numbering doesn't start at 1 for a particular type of component so in that case it couldn't be used to count how many there are of a particular type.
So, where can you get your hands on electronics to recycle? One place for sure is at a carboot sale, you can buy cheap devices to use or salvage the components from. And if you're lucky, you may find something chucked out that couldn't be sold that you can use. This reminds me of a saying, "What's one person's rubbish is another person's treasure."
There are some unwritten laws about carboot sales:
* People who sell computer parts are always located on the last rows (worth the walk I guess).
* There will always be sellers trying to get rid of old scanners, printers, black & white TV's and CRT monitors at prices that you would associate with nearly new products.
* When browsing at a particular stall the owner will joyfully comment that if you had arrived earlier there would have been even better things for you to buy (I'll just go back in time...)
Some examples of great finds at carboot sales I have been to are a large number of computer ribbon cables (IDE, floppy, SCSI) and strangely a collection of connectors that had been cut from PC PSU's, but still usable. And a very heavy power supply unit with multiple outlets that for some reason was branded 'fragile,' this being a large metal box!
You'll need to be good at desoldering to reuse components and how much of a hard time you have depends on what the item is. Components with two legs are simple to remove, you can get rid of the solder with a solder sucker and then pull out the component; it helps to carefully push the component back and forward several times to loosen since the smallest amount of solder can cling to the component's leads (like a loose tooth). Another technique is to heat up one leg as you pull on the component at the other side (helps to have someone hold the circuit board for you) and then do the same for the other connections.
Remember to use a heatsink on the leads of components (as close to the body as possible) sensitive to high temperature (desoldering requires even more heat than when soldering), the heatsink can just be a metal clip. But for components that have far too short leads to attach a heatsink to you'll have to do without and be as quick as you can (a few seconds). Semiconductors such as IC's, transistors, diodes including infra-red and visible LED's are the ones that need to be protected when soldering or desoldering. It is possible to remove sockets and IC's soldered directly to the circuit board, you'll need to suck up the solder from each connection using a soldering iron and solder sucker pump.
An unwanted printer or scanner may be something you would ignore yet they have quite a few parts that can be put to use in your projects and include ordinary and stepper motors, and optical components like slotted-opto switches, often on long leads with connectors.
Above is a picture of an HP printer that was somewhat difficult to pull to pieces but was worth the effort when I had worked out the right order of removing the parts and fortunately I had a star shaped screwdriver. Unfortunately there are not many componets that I could use from the main board and there's all that metal to go to waste, but a great find nonetheless for the motors and optical parts that I can use.
What about a CD or DVD-ROM drive? They are great for parts you can use for your own projects, a typical optical drive contains two 'normal' motors, a stepper motor, switches, optical sensors and LEDs as well as other components. Many of these drives have flash or other type of rewritable memory in the form of a chip that can be removed.
Generate your own electricity
Electricity can be generated from the sun using solar panels and from motors by turning the spindle yourself. Traditional motors aren't that good when used to create electricity but stepper motors, which contain many coils, are much better for producing electricity for their size.
Only a few components are needed in addition to a stepper motor to generate electricity and they are a bridge rectifier (four diodes arranged in a bridge network) to convert the AC current from the stepper motor to DC. You will also need one or more capacitors for smoothing and storing the generated electricity.
Unless the load (which is to be powered by the generated electricity) uses very little current, more often the electricity that is produced by the stepper motor is used to recharge a battery which then powers something.
LED torch reviews
Gone are the days when we had to rely on torches that used lightbulbs; never mind if the battery would last, how about the lightbulb?! LED's are so much more efficient and less power hungry than traditional lightbulbs so it's just as well as LED technology continues to improve that they are replacing lightbulbs, however, even LED's aren't perfect.
For one thing, torches that use a lightbulb have usually a much simpler circuit than those that use LED's and there are several reasons for that. Firstly, although too high voltage or current will blow a lightbulb they can be made to withstand more power than LED's which typically operate on 2V 20mA for the colours like red and as for blue and white, they need no more than 4.5V at a similiar current rating. So, a limiting resistor is used to protect the LED from too high voltage or current that would destroy it.
This means, for example, if you wanted to replace the lighting in your house with LED's you would need a circuit to step down and rectify the mains voltage for the LED's or you would have to use batteries. Then comes along another problem, that LED's cannot produce as wide beam of light as lightbulbs, so many LED's have to be put together (often in a circular shape)-known as LED lamp or LED bulb-which increases power consumption and complicates wiring. LED's of size up to 20mm can be bought yet they are actually made up of many smaller LED's internally, hidden by the plastic casing.
You might think that connecting several LED's shouldn't be a big problem but you must take into consideration if you should wiring them in series, parallel or a combination of both. Connecting LED's in series will allow them to be used on a higher voltage with each LED getting the same amount of current so that, for example, two LED's in series that work on 2V each can use 4V together (i.e. double).
Parallel connected LEDs differ in that every LED will get the same voltage but the current drawn will increase with each LED added to the circuit. Because of the increase in current required from the power supply, if a limiting resistor is needed it may have to be of higher wattage rating (due to the increase in power demand) than what would be needed with only one or two LED's.
When buying an LED torch you should look for the following:
* Power supply: is the torch powered by batteries, and if so, how many and of what type (AA, AAA, C, and so on)? Some torches can be powered by shaking them or using wind up power, which is possible thanks to the advantages of LED's over lightbulbs (such as lower power consumption), so stored up power will last longer.
* Colour of LED(s): this may seem stupid but as with the cheaper energy saving lightbulbs, the not so bright so-called white LED's have a hint of blue about them (since blue is used to create the white light).
* Number of LED's: you may think that more LED's will be better but although LED's grouped together should increase how wide the beam of light is, that doesn't mean the overall light is very bright. One or two super bright LED's could equal the brightness of many more less bright LED's but with a smaller light beam.
Before I review various LED torches that I have bought I must mention that since LED torches will likely contain a number of LED's clustered together, you could use the LED's for your own projects. You will save money and the LED's will already be soldered in place, all you will need to do is connect wires to the circuit board. So that torch could become a desk lamp or provide illumination for the displays on equipment you have made, and so on.
Ok, now for the reviews, starting with a slim, silver, metal torch shaped in a traditional way that I got from Poundland. So that's £1 for the torch which uses 3 AAA batteries (despite it saying AA on the packaging) and has 3 very bright LEDs grouped together in a triangle formation.
Then there's the LED headlight that I bought in QD for £2.50 that is coloured silver and black with straps to secure it across your head as you would expect. It has a removable battery holder in which to put 3 AAA batteries, to turn the torch on you press the button to cycle through the states of middle LED on only, three horizontal LEDs on only, all seven LEDs on and off.
Next we have an odd shaped torch from Poundland that requires 3 AA batteries and uses a sliding switch in which to select the ten LED strip on, flashing orange light, 2 LED's at front on and off. This torch is much more worth the money for what you get and especially the LED strip light is very bright.
Now in more detail, the 10 LED strip current is approx. 400mA, the flashing LED current is approx. 40mA and the 2 front LED's current is approx. 140mA. The high current drawn from the batteries is due to the LED's being connected in parallel, with the exception of course of the single flashing LED. Speaking of the flashing LED, it appears that a two transistor (S8050) multivibrator oscillator causes the LED to blink which is actually white but made to look orange using a filter.
All content of this and related pages is copyright (c) James S. 2007-2009