Showing posts with label diy. Show all posts
Showing posts with label diy. Show all posts

Monday, December 26, 2016

I upgraded my computer--including stupid technician tricks

System Information (from Control Panel/System)


The last two times I was on +Adafruit Industries #showandtell, my video was unacceptable.  That's a minor irritation for me, but the second time I had my seven-year-old-granddaughter on. She was able to get through it, but it was a struggle.  Show and and Tell is a Google Hangout, and the minimum requirements include a quad-core processor.  I had been getting by with an AMD Athlon X2 dual-core processor and ASUS Motherboard for the 3 years I've been participating by shutting everything else down and running just one tab on Chrome for the hangout, but I guess Google's "enhancements" have rendered my computer obsolete.

The computer was an 8-year old home-build, and has served me well, but I decided that I needed to get my granddaughter on again in fine style, so I bought an AMD 8-core processor and ASUS motherboard. Actually I bought an ASRock motherboard first, but I had some issues with the build (see below) and I read reports of this mobo bursting into flames, so I returned it and ordered the ASUS. I will report here after I try Show and Tell again, but so far it's great.

Additions

I also ordered a new graphics card.  I'm not very happy with it. First, the description, the invoice, and the parts list all say it supports DirectX 12.  What Newegg sent me supports DirectX 11.2, according to the box. I returned it for replacement, expecting them to fix their error right away.  It turns out that they refused to replace it until the receive the one they sent in error.  So, I changed it to refund and ordered a new one.  I got the new one 5 days before they received the return. To my surprise, it was the same version. Newegg has been good in the past, but this is not good.  Over 2 weeks later I still do not have a refund.  

In addition, I got this card because Microsoft says that the Windows 10 video capture tool works with AMD Radeon R7 and later. However, it's still telling me that my video card is not good enough for them. More research.

The motherboard has an  M.2 slot for what is essentially and SSD stick.  When I get around to it, I will add a 250GB SSD using this new, smaller, faster technology.

The motherboard also has COM header for a serial port, Since my ham radios are able to work digital modes through a serial port I ordered one from China and will hook that up to enable me to experiment with digital modes. More learning and excitement!

Since the 650W power supply I had in the machine had failed recently, I had replaced it with a 800W supply.  Underpowering a system is an invitation to frustration, so if you're upgrading, don't forget to be sure that you have a power supply that will meet all the requirements of your new system.

Stupid Technician Tricks

I won't go into detail on the big one (it's embarrassing and I know better), but here are some suggestions for installing an AMD CPU on a motherboard:
  1. lift up the lever next to the pad on the motherboard
  2. align the arrow in one corner of the CPU with the arrow on the motherboard pad (also check the pattern of the CPU pins to be sure they align with the pattern on the pad
  3. only after the CPU is seated properly, push the lever down
  4. check that everything is secure BEFORE adding the heatsink/fan assembly
Enough said, except that the overarching recommendation is "Take your time!"  

The only other problem I had was minor:  the hard drive light was not lighting. Obviously, I connected it wrong.  Lesson: double check your connections before you plug in the unit, and check that everything works before putting the case all back together.

Activation

Initially, I thought I may need to buy a new copy of Windows, but I read up on Microsoft's digital license policy and made sure that I was all set up.  I had Windows 10 Pro, installed as part of Microsoft's free upgrade program. Since I had purchased Windows 8.1 Pro, it upgraded me to Windows 10 Pro.  After I fired up the  machine I was not asked to activate Windows (although Office 2010 did ask to be activated--quick and easy).  I did get a message "you need to fix your Microsoft Account."  Google revealed that I needed to update a user. When I went in to do that I was told I couldn't because Windows wasn't activated.  I went through the activation process--which tells you you need to buy a new copy but has a non-prominent link "I recently upgraded my hardware."  I clicked that, and after a couple of "our servers are down" messages, I was able to activate.  Done,

I use Norton Security provided as part of my subscription to Comcast.  Norton said it had expired.  I couldn't convince it that it hadn't, and Comcast help was typically useless, so I uninstalled it and reinstalled and all was forgiven.

Summary

I have a fast new machine that should work with the Adafruit Show and Tell Google Hangout. Everything is activated.  I have and upgrade path to an SSD and will have a serial port to use for ham radio digital modes as soon as it arrives.  Overall I'm happy with the build.

The only issue is the video card.  I read on the interwebs that others with this card have had the problem Windows 10 video capture.  I'm working on it.

Friday, November 25, 2016

Generator House Upgrades

Upgraded house, showing new roof, exhaust system, and PVC carrying wires to/from the residence.

The generator house (see this post) did a great job.  However, we needed some upgrades.

First, we needed to get the exhaust fumes out.  The extra heat and the flammable gasses were a potential problem. So, with some black iron pipe and some welding (again, my brother-in-law has skills), we fashioned the exhaust system and connected it to the generator.

Next, in order to power the house, we had to run a cable from the generator to the transfer switch--every time.  I bought a new transfer switch with more circuits and more suitable for my house.  We ran 10/4 wire from the transfer switch, and 14/2 from an existing circuit, to a junction box, then out through the wall, where the wires ran through PVC down the outside wall, underground, and into the back of the generator house.  The 10/4 goes to a junction box, where it connects to a cable that plugs into the generator. Now we don't have to mess with the heavy cable every time we want to power the house.  The 14/2 supplies 2 boxes:  one with a switch that goes to a light plus 2 unswitched  receptacles and the other to a switch that controls 2 receptacles--the fan is plugged into one and the battery charger to the other. These will always be powered, except in the time between house power going out and running the generator.

Third, the quick roofing job was not sufficient, so we took off the old shingles, put down tar paper, added metal drip guard around the edges, re-shingled, and added lead flashing at the top.

Now we have something!  When we have a power outage, all we need to do is flip the switches on the transfer switch to off, start the generator, let it run for a few minutes, then flip the transfer switches to generator, and we have power.  The whole house, except air conditioning and the stave and dryer can run off the generator.

BTW, when I say "we" with respect to any work I mean my brother-in-law under my expert supervision (which is mostly me saying "that' looks good").

See the video.

Sunday, April 3, 2016

Adjustable Power Supply Problem Solved - DUH!

I have this very useful Compact Switching Power Supply - Selectable Output 3-12VDC from +Adafruit Industries.

I noticed a while back that the polarity was not what I thought--center-pin negative instead of center-pin positive.  It didn't matter a whole lot, because I used it a lot for my 5V Regulated Power Supply, and since I used my meter to check which was + and which was -, I got away with it.  Later, I found that the adapter did not work in certain applications.

I put that away for a while, but it just started to bug me again, so I Google'd the problem and was taken to the Adafruit product page (see above).  Reading the not so fine print, I saw that the device can switch from center pin positive to negative. Next question: how?

I did not find an answer, so I went to look at the device.  It comes with tips to accommodate various size receptacles.  I turns out that the wire to the adapter has + and - on each side, and the tips have CEN with an arrow. So, if you want center pin positive, mate the side marked CEN to the side marked +, and vice versa. I never noticed that before. Live and learn. Anyway, my problem is solved. I must be some kind of genius!

Thursday, August 27, 2015

@MAKE #Electronics Experiment 32: Robot Cart (Part III - Cart is together)

The saga continues...

I put the pieces of the cart together as shown here:
I attached the hinge to the body only to expand the pilot holes to make it easier when I put the movable wheel assembly together (see upper right).  The wheel at the lower right has the mounting wheel for the motor ready to go.

Next step was the wheel assembly.  I needed 1" #6 bolts to put the 3 pieces together (each piece is 1/4").  Once I got it together I realized that it was upside down (the holes for the axle needed to be on the bottom), so took it all apart and reassembled.

Next was the driving wheel. The pre-drilled holes in the mounting wheel were not big enough for any screws I had or could get quickly, so I reamed them and used #4 sheet metal screws (needed 1/2"--another shopping trip).  Pan head screws won't do because the wheel needs to clear the motor. Even with flat-head screws I had to file down a small plastic cylinder on the motor, which has no use that I can discern.

Now I was ready to mount the motor. I was clueless here, but I thought ahead enough to buy a mounting bracket, which attaches to the motor with a #4 machine screw (again, 1/2" flat-head). I measured the cylindrical piece to the motor--it's 3/4". I drilled a 3/4" hole in the ABS side (3/4" from the bottom like the other wheels, and over enough so that the wheel did not extend beyond the front of the body--2.25" in). I had to file the hole to get the motor through it, but it's in and stays put. The bracket doesn't do much, but if I need to secure the motor later on, I can screw it to a piece of plywood that I secure to the frame.

The motor is a Solarbotics GM2 Offset Shaft Gear Motor. I used a Solarbotics GMW mounting wheel, and GMB28 Mounting Bracket.

Next was the limit switches.  They need to be in the front with the sensors out so that when they hit something the switch will activate the timer sequence and flop the relay for 5 seconds, reversing the motor. (See my post, including a video, on the circuit.) I drilled the holes (1/8") on both sides but only mounted one, using 3/4" #4 machine screws and nuts.  I'm keeping the other connected to the breadboard circuit for the final pre-completion test.

Next Steps:

  • test the circuit again
  • construct the circuit on an +Adafruit Industries Perma Proto Board and mount it on standoffs in an Altoids Tin with insulation on the bottom
  • test and rework as necessary
  • solder everything up and go


Here's what it looks like at this point:
Right view. Note the limit switch on the front.
Front view (driving wheel, motor. limit switch)


Rear view (moveable wheel assembly, hinge)

Left view (motor protruding through hole)


Saturday, August 22, 2015

@MAKE #Electronics Experiment 32: Robot Cart (Part IIA-Better)

3rd attempt at the cart.  Used a hand saw this time, and my handy drill. I marked Xs on the pieces I want to cut out to remind me what I'm doing.

Cart is now fabricted.  You can see some damage from bending the frame, but it will do for now.  I may redo it if I like the final product and want to showcase it.
OK, so I can't follow directions. It's a good thing I bought 10 sheets of ABS, because I have ruined 2 now, and may need another.  I got through my measuring, drilling and cutting, only to see that I pu the cuts on the wrong side.  So, I measured and drilled again...that's the top photo..and took the step to mark the pieces that wanted to cut out.

I made the cuts. used my heat gun to soften the plastic, and bent the sides.  I left the final cuts (removing the short pieces on what would become the top) so I could bend those into a position to cut them.  It was ugly.

I'd like to say that I started on the wrong side on purpose (one side is textured and the other smooth), but it was by mistake. It turned out to be almost OK because I had significant shaping and deburring to do, using my Harbor Freight Dremelish tool.

When I bent the frame back to put the textured side out, there was some damage (see lower photo).  It's usable as-is, so I'm going with it.  If I really like the cart when it's done. I'll redo the frame.

Next:
By some 14" plywood, the hardware (hinge, bolts, nuts, screws), and maybe some 3" disks to use as wheels,  as suggested by James Floyd Kelly.

Friday, August 21, 2015

@MAKE #Electronics Experiment 32: Robot Cart (Part II)



So, carpentry and fabrication are not my strong suits. Evidently I'm not real strong on following directions, either. Anyway, this is pass one, and I'll keep at it.

The good news:  I proved that I can use the 12"x12"x1/8" sheets of ABS (that I bought from Amazon about a year a go thinking they's come in handy) for the main cart body.  They're not thick enough to screw into, so I'll add 1/4" plywood, or maybe see if I can find 1/4" ABS.  I was able to cut the sheet to 9"x8", drill holes for rounding corners, then cut the rest, and use my heat gun to soften it for bending into shape See Fig. 5-92 on p. 275.

Problems:
  1. I used the wrong saw. That's why the cuts look ugly.  I knew that, but I bought a reciprocating saw at Harbor Freight and have been dying to use it.  I'm going to a hand saw, maybe a coping saw. 
  2. I drilled 3 of the holes in the wrong place. The idea is to have 1/2" diameter holes to round the 4 corners of the cut ABS, but you need to drill the holes in the inside of the cut, not the outside (that's why you see some holes that don't appear to be random--they are just wrong).
Other than that it's great.  I'm ready for pass two, and I learned a lot.

Tuesday, August 18, 2015

@MAKE #Electronics Experiment 32: Robot Cart

I'm ready to start on this. First step was to gather the materials.  The parts list on page 268 is incomplete, although on p. 276 there's a "you will also need..." See the schematic on p.277 and this blog post by +James Floyd Kelly  (it's on experiment 31, but references shopping for 32). The 50K potentiometer shown in the schematic controls the time the motor runs in reverse before going forward again.
Make: Electronics by Charles Platt, Figure 5-98. p.277 (in the edition I have)

Also, the erratum on p. 277 mentions adding a diode or transistor. I'm going to try a diode (handsonelectronics says diode).

I found that my DPDT relays on hand are not appropriate. Some are latching relays bought for experiment 20, and the other was 12V, so I ordered two 5V DPDT non-latching relays from Amazon.

Charles spends a great deal of time on fabrication and not much on the circuit.  Since I care more about the circuit, and there are some issues with it, I'm going to build that first. I'm going to try to use plastic for fabrication. I have some 12"X12" pieces of ABS, and the shell of a multi-function printer that I tore-down.

Here's the concept:
When switched on, the cart moves forward until one of the microswitches hits something, it cuts power to 555 Trigger Pin 2, causing the the Output Pin 3 to pulse the relay, which then flops, reversing voltage to the motor, which reverses. The timer cycle (determined by 555 Threshold Pin 6 and Discharge Pin 7 as powered by the capacitor/resistor combination along with the Pot). When the cycle ends, the Output Pin 3 goes low and the relay flops back, causing the motor to reverse again (making it go forward).

The time it reverses starts at ~5 seconds (47uf cap*100000Ohm resistor = 47//1000000*100000 = 4.7). The Pot did not make much difference, if any. I thought it did, but it turned out that I had unhooked the 100K resistor. DUH.

I had other DUH moments in this, but I was helped immeasurably but people running into the same problems I did, particularly +James Floyd Kelly .  Thank you James. First, I bought a 5V gearmotor from robotshop .com. I fussed around for way too long trying to figure out how to wire it--then I noticed the two copper tabs on the neck.  Second, I was getting weird buzzing from the relay, and the motor was not reversing. I remember the symptoms from James' blog. My relay had different pinouts from the schematic. There are 8 pins. If you number them 1-8 starting with 1 at upper left and go counter clock-wise, I needed to switch pins 2 and 3 on one side and 7 and 6 on the other.  I could not find a datasheet for this relay, but I had a similar issue once before with another DPDT relay, so I guessed.

Third problem was the diode,  The motor would not reverse, but fortunately I had seen this before (thanks James), so I added the diode across pins 1 and 8 of the relay with the cathode towards pin 8.

I also struggled with wiring the switches.  I tested it with just the switches, power supply, and a meter, and came up with:
555 Trigger Pin 2  to switch1 NO prong, connected to switch 2 NO
Both NC Prongs connected to GND
Both COM prongs (on the side--at least on mine) connected to GND

If neither switch is pressed, current is flowing to the trigger pin through the 10K pull-up resistor making it high and thus the output pin is low. When either switch is pressed, the trigger pin goes low, making the output pin high, and flopping the relay and reversing then motor.  The output pin stays high until the 47uf capacitor dishcarges (4.7sec) to the threshold pin, making it high and setting the output pin back to low, flopping the relay back and the moving the motor in the original direction.

It works.  Here's the video.

Thursday, July 9, 2015

@MAKE #Electronics Experiment 30: Fuzz

From Make: Electronics, by Charles Platt. Sebastopol, CA: Maker Media, Inc, 2009, p 259.

In Experiment 30, we are creating distortion rather than filtering.  It's really an extension of Experiment 29, using a schematic similar to part 2. The differences are:
  1. The 10K and 33K resistors on TEA2025B IN1 pin 10 are replaced by an 820 Ohm resistor. The audio input still comes in at this point.
  2. There are no filters. The speaker connections go directly to OUT1 (pin 2) and OUT2 (pin 15) of the amp. 
  3. The 680K resistor on 555 and 500Ohm Pot on output pin 3 of the 555 are replaced by a .1uf cap, going to the base pin of a 2N2222 transistor (Q1). The rest of the 555 connections are unchanged. The 100K Pot still adjusts frequency.
  4.  The big difference is the addtion of the transistors.  The collector of Q1 is connected to power through a 33K resistor. The emitter of Q1 is connected to a 1K resistor and 1uf capacitor, which are also connected to the emitter of Q2.  Q2's base pin is connected to the 33K resistor, power, and Q1's collector. Q2's emitter is connected to a 100K pot through an 8K2 and 390 Ohm resistor and .22uf cap, with the other side of the pot connected to the audio input.
The transistors amplify the waveform coming from the 555, as adjusted by Pot1.  This signal overwhelms the amp, causing distortion to a degree determined by Pot2, which Charles calls the "fuzz adjuster."

I spent some time with the datasheet for the TEA2025B.  It's a stereo amp that we used in "bridge mode" for these Experiments 29 and 30.  The leads to the single speaker are connected to OUT1 and OUT2 (pins 2 and 15), and the audio input goes to IN1 (pin 10). In stereo mode, each speaker would have one lead connected to an output and the other to GND, and the additional audio input would connect to IN2 (Pin 7), which would have the same .22uf cap + resistor combination as IN1,

Another interesting experiment.  I plan to fuss around more with the TEA2025 and associated resistor and capacitor values, just for grins.

One curiosity: as reported here and by +Eric Buijs, the TEA2025 overheats, and overheats a lot at 9V.  I was having trouble getting go0d results from this experiment, so I decided to swap out the chip. It hat melted the breadboard under it, and the new chip gave me what I expected (including overheating).  The datasheet says it will take up to 15V, but at least 2 of us have experienced overheating.


Wednesday, July 1, 2015

@MAKE #Electronics Experiment 29: Filtering Frequencies Part II


Note: first, apologies to +Eric Buijs who noted that the TEA2025B runs hot at 9V.  I either did not notice or did not perceive that in part 1. However, in part 2 I experienced the same thing. Using an adjustable wall wart, I was able to apply different voltages.  9V works best, but it runs at safer temps at 7,5V and 6V. Besides the heat, the biggest difference is the volume coming out of the speaker (see video at link below).

Part 2 of this experiment involves adding a 555 timer in astable mode (with resistors and capacitors) and two pots: a 500 Ohm for volume control (between output pin 3 of the 555 and the input of the TEA2025B) and a 100K to manipulate the waveform (between 555 discharge pin 7 and threshold pin 6). I skipped the buttons for this exercise, and connected it with each filter and with no filter at all. The differences are discernible.

I did not have a 500Ohm pot, so I used a 1K.  It really only worked as a volume control at 9V.

Charles says to disconnect the audio source and use the timer as input to the amp.  I also added my cell phone playing Pandora back in.  It works for that, too.

A very worthwhile experiment. I'm looking forward to doing more with audio.

Here's the video.

Monday, June 22, 2015

@MAKE #Electronics Experiment 29: Filtering Frequencies Part I


I know very little about audio, etc., so this experiment is very interesting to me.  When I was 10-12 years old, I read about people making hi-fis, ham radios, and the like, and thought I'd like to do that someday.  With neither persistence nor guidance, that interest was never nurtured, but it was always somewhere within me. Thank you Charles for helping to bring it back. 

The photo below shows the breadboard, nearly complete according to the instructions.  The two momentary, normally open push-button switches are for the two filters. The coil is not shown--110ft of 20 gauge hook-up wire, which I had to unwind./rewind to get access to both ends. I used two 22uf electrolytic capacitors, back-to-back, instead of the 10uf NP cap Charles had in the schematic.  I could not find .15uf caps, so I used .22uf. I took the speaker out of an old Sony Trinitron TV before I took it to the dump (also got some pots and other useful stuff). Since I'm totally ignorant, I wasn't following Charles' instructions for connecting audio, so I bought some plugs to fit into the adapter. Once I took the plug apart and saw the connections, I understood what he meant. Since I spent the money (US$4.99 for eight at Radio Shack), I'll use it. Besides, it gives me an excuse to solder. The box for the speaker is a US$1.99 pencil box from K-Mart.  I use them for project boxes, but this seemed like a good application.

Breadboard almost ready, speaker taken from an old TV set, RCA adapter from Radio Shack, and a pencil box from K-Mart

The next photo is the speaker box after I drilled holes. Not the tidiest of jobs, but I think it will work.

Pencil box ready to be a speaker enclosure

Next step, hook up the filters and the music (I'll plug the adapter into my cell phone and play something on Pandora).

The idea is to bring mono input into the amplifier chip. The output goes through either a high-pass (caps) or low-pass filter (coil) to the speaker. I used the RCA adapter to get sound from my cell phone, plugged into one of the jacks in that adapter, and wired the plug to ground and to the 33K resistor/amp input.

Everything hooked up as expected. There is a big difference with and without the coil, not so much with and without the caps. The coil provided more difference after I removed the 33K resistor (also less noise). I will try using smaller caps. In the next post I will add the 555 timer and pots.  I'll add video there too.

This was another simple, but informative experiment.  I love this book. See you in part 2.


Monday, April 20, 2015

@Make #Electronics Experiments 26-28--Fun with Coils

These three experiments, like #25, are pretty short. Since they're related, I decided to do them all together.  I thought of doing this starting with 25, but I did not have all the parts I needed (lacking the spool of magnet wire).  Now that I have what I need, I'm ready.


Here's a video of the three experiments.  Following is a discussion of each part and links to individual (shorter) videos.

Experiment 26: Tabletop Power Generation

This one is neat. It's in two parts:

  1. Use a 3/4-inch neodymium magnet to generate alternating current
    By stripping the ends of a 100ft coil of 26-gauge magnet wire on a spool, connecting the ends to an LED, and then moving the magnet up and down through the spool, we generate electricity to light the LED. The LED flashes only on one direction--reverse the connections and it only flashes in the other (alternating current).
    Video.
  2. Use a diode to rectify AC current and store in a capacitor
    Using the same coil as in part 1, we use a 1N4001 signal diode and 100uf electrolytic capacitor in series to replace the LED.  We connect a multimeter across the leads of the capacitor to measure volts.  When we move the magnet up and down through the coil, it generates electricity, but the diode blocks one direction, so it's DC.  The capacitor charges up until we stop moving the magnet (I got it to about 2.5V), then it slowly discharges.
    Video.

Experiment 27: Loudspeaker destruction
I fudged this a little because I did not have a 2" speaker. The 1 1/4" Radio Shack cheapie was good enough for demonstration.  The whole point is that there's a coil and a magnet and the inputs to the speaker causes vibrations which are received as sound.
Video.

Experiment 28: Making a Coil React
In this experiment , we power a circuit from 12V DC, passing through a momentary tactile switch, a 220 Ohm resistor, two low-current LEDs oriented in opposite directions, and on through a coil.  When the button is pushed, the coil initially blocks flow so the circuit finds a path through one of the LEDs.  Once the coil;s self-inductance is overcome, it accepts current and the LED goes out.  When we release the button, the current that was stored in the coil releases and lights the other LED.
Video.

Sunday, April 19, 2015

Regulated 5V Power Supply


Taking a break from the book experiments, I decided to make my own 5V regulated power supply, since we've been including it in many experiments.

This took WAY longer than it should have. I though it would take an hour--instead it took most of two afternoons, including 2 trips to Radio Shack.  The first day was setting it up on a breadboard so I could replicated it on a PCB.  I made a bunch of stupid mistakes...finally took it all apart and re-did it and it worked.

The second day was taking the model and putting it on a PCB.  I wanted it on perfboard, and I wanted header pins to plug into a standard breadboard.  Plain perfboard does not facilitate soldering. I had a one sided PCB, and I got the header pins on, but that made soldering connections on the bottom side difficult.  First trip to Radio Shack: unsuccessful, no double-sided PCBs. I have several Adafruit perma-proto boards in 1/2, 1/4, and 1/8 sizes.  They don't fit the breadboard, but I made due with the 1/4 size.  After a bunch of wiring errors, I got it working.

Parts:
Adafruit barrel jack
Adafruit 1/4 size perma-proto board
LM7805 Voltage Regulator
PCB mount toggle switch
22 Gauge Hook-up wire
Tinned Copper Bus Wire
10uf electrolytic capacitor
.1uf electrolytic capacitor (I ran out of the mylar versions)
LED
330 Ohm resistor
standoffs and screws

The barrel jack takes 6-12V in.  The power from the jack connects to pin 1 (power in) of the LM7805 and ground to pin 2 (ground).  the 10uf cap goes between LM7805 pins 1 and 2, and the .1uf between pins 2 and 3 (power out) Since both capacitors are electrolytic, the negative side for both goes to pin 2.  Pin 3 goes to the PCB power rail, and Pin 2 to the ground rail.  Hookup wire connects the rails from side to side of the PVB.  Pin 3 also goes to one side of the toggle switch, and the other side of the switch goes to ground (WRONG!--see "Update" below). The LED goes from power to the 330 Ohm resistor to ground.

Since I could not plug this into a breadboard, I added hook-up wire (22-gauge, solid core) soldered to the power and ground rails.

Here's the video.

Update: see my comments, below.  The voltage regulator overheated when the device was turned off with the toggle switch.  Dumb mistake: I should have put the switch between 9V in from the barrel jack and the 9V side of the LN7805.  I fixed that. Here's  an annotated photo of the bottom of the PCB. I know it's messy--I haven't trimmed the wires yet.
DIY 5V Power Supply Wired Correctly (bottom view)

Saturday, April 11, 2015

@MAKE Electronics Experiment 24: Gonna Skip It

I've been away, and recovering from being away, for a couple of weeks, so I'm just getting back to my journey of discovery with Charles Platt as my guide.

Experiment 24 involves enhancing the intrusion alarm from experiment 15.  All the enhancements are worthwhile, but I never implemented the system (my wife was not enthusiastic about adding the reed switches to windows and string wires around the house). So, the enhancements would be a learning exercise only. That's not bad--these are all learning exercises--but I think I've got the concepts and I'm ready to move on.

Here's what Charles proposes:

  1. Delayed activation
    Use a 555 timer mounted in a separate box with a button to activate the circuit and the 12V power to the alarm passing through it. Before leaving the house (e.g.) you push the button, activating the circuit which cuts the power to the alarm for 30 seconds. That gives you 30 seconds to open and close the door (which in this case has the reed switches) without triggering the alarm,  After 30 seconds, the power to the alarm is restored and the next time the door is open the alarm will be triggered.
  2. Keypad Deactivation
    In experiment 15, once the alarm is triggered it makes noise until the power is cut.  By adding a latching relay and keypad system a la experiment 20, we can turn it off without cutting power
  3. Delay before deactivating
    It would be nice to have some time when entering the house before the alarm sounds.  The solution here is to add another 555 circuit, in bistable mode.  This is interesting, becuase in addition to using the threshold/trigger mechanism, it is necessary to be sure the the circuit starts and stays going without being reset, so there is a smaller capacitor on the reset pin to make sure it starts LOW (output inhibited) and becomes HIGH (output allowed) faster than the output is triggered.  If we did not do this, we're leaving it to a 50/50 chance that the output is H or L. This feature allows us to control that.
A worthwhile exercise, but I'm ready to move into Chapter 5.

Saturday, March 21, 2015

@MAKE Electronics Experiment 22: DeBouncing and Flip-Flop

This experiment is deceptively straightforward. The only issue I had was a bad chip.

First, I mentioned in the last experiment that the slide switch was not breadboard friendly.  The pins are not long enough and with only one row of pins it's not stable. I tried taking it apart with the intention of making a breakout board, but that proved to be harder than it should be (I should have left it together).  So, I went to Radio Shack and found this. The advantage is that it's a DPDT and  has 2 rows of pins, making it more stable.

So with a better switch, I tackled the experiment. Both circuits do the same thing. Debouncing means ignoring errant button pushes. Since latching logic gates set in the first impulse, anything further is ignored.  We latch by feeding the outputs of each gate to one of the inputs to the other.  The second input is connected to a pull-down (NOR) or pull-up (NAND) resistor and to one side of the switch. The pole of the switch (we only use one) is connected to Vcc (NOR) or GND (NAND).
Each output also powers a low current LED when it's HIGH.

NOR output is LOW unless both inputs are LOW.  When the switch is towards a gate's input, that input goes H, making the output  L. That gate's LED is off, and one input to the second gate is L. Since the switch is away from the second gate, that input is also L, making the output H, turning on the LED and making one input back to the other gate H, keeping it's output L and it's LED off. Switch to the other gate and one input goes H, making output L  and both inputs to the other gate L and it's output H and LED on.  It can only be in one state or the other. Debounced.

NAND works similarly.  NAND output is H unless both inputs are H.  The switch is connected to GND and each gate has 1 input connected to a side of the switch and a pull-up resistor. So, one input is H unless the switch is closed to that side, in which case it's output goes H,turning on the LED and feeding H to one input of the other gate.  Since the switch is open to that side, it's pull-up resistor makes the other input H, making the output L, turning off it's LED and feeding L back to the non-switch input of the other gate, keeping it's output H until the switch is moved (or power to the circuit is cut).

Fun and interesting. Here's the video.

Tuesday, March 17, 2015

@MAKE Electronics Experiment 21: Game Show Button Controller

After the last experiment this one is pretty straightforward. One 74HC32 quad OR chip, 2 timers, one SPDT switch, 2 tactile buttons, 2 LEDs, 3 10K resistors, 2 330 Ohm resistors. The wiring's the thing.

I couldn't get it to work at first, but it was just a loose connection. That, and my "breadboard-friendly" SPDT slide switch wasn't so breadboard friendly. I had to bend up the tabs on the side to get it to fit the breadboard at all, and the legs still weren't long enough. But it works.

Anyway, the switch is for Art Fleming to activate and deactivate the contestants buttons.  The buttons are tied to Vcc through a pull-up resistor. A jumper from one side of the switch to the side of button 1 1 not connected to Vcc and then a second jumper from there to the corresponding button on button 2. The other side of B1 goes to OR Gate1, input 1. The same for B2, the corresponding side goes to OR Gate 2, input1.  Both input2s are connected to Gate3 output. Gate3 inputs are connected to the output pins of the 555s.

So, in order for the output of either 555 to go H, the input on trigger pin 2 must be L. The trigger pins are tied to the outputs of OR Gates 1 and 2.  OR output is H if either input is H.  One input is tied to 555 output, which is L until triggered by it's corresponding OR Gate. Button outputs are H if no action is taken, so the 555s are not triggered. When a button is pushed, the voltage from the button goes negative, making both inputs L, and the corresponding output L, thus triggering the corresponding 555 output. Both 555 outputs are connected to LEDs, so the LED lights and stays on until reset.  Once one 555 output is H, Gate 3 output is H, and neither button has any effect because the corresponding outputs will be H.

When Art Fleming activates the contestants buttons and asks a question, the first contestant to press the button lights his/her LED and locks the other contestant out.  The other side of the slide switch is connected to the 555 reset pins (4), so when Art slides back the LED turns off.  When he's ready for the next question, he flips the switch back and the cycle repeats.

Here's the video.

Sunday, March 15, 2015

@MAKE Electronics Experiment 20: Keypad Security System Epilogue Part II: Making it Work

Getting past the fact that the 555 won't supply enough voltage, ever, the next question is how can we amplify it. The answer is with a transistor.  It took me way longer than it should have to get it to work, because of wiring problems and cooked transistors.

First the wiring:  instead of taking 555 Output Pin 3 to the + side of the relay coil, I connected it to the base pin of a 2N2222A transistor (NPN BJT).  I then connected + side the relay coil to the 5V rail, and the - side of the coil to the collector pin of the transistor.  The emitter pin goes to GND. Initially, I left the LED in the circuit, but since that's connected to GND, the circuit was always completed. I'm sure there's a place I can put it, but it works without it.

After few wrong connections, I still could not get it to work. I was absolutely sure that it was wired correctly.   During this process I must have cooked a transistor or two, In desperation, I replaced the transistor again, and it worked.

So, that's the answer:  insert a transistor, properly wired, and the voltage that was too low to trip the relay is enough to activate the transistor, allowing 5V to flow from the 5V rail through the relay to the collector, and when the 555 is triggered, the output pin will supply enough voltage to the base pin of the transistor to allow current to flow through to the emitter, completing the circuit.


Here's the video

I'm glad I got this to work.  I hate to leave something incomplete..

Wednesday, February 18, 2015

@MAKE Electronics Experiment 20: Keypad Security System (Part I)

Experiment 20 builds on the logic chip exercise in #19 to build a keypad security system. The full experiment ends with hacking into a computer's power button and cutting a hole in the case to attach the keypad.  I have several carcasses around that I can use for that, but I think rather than dedicating the system to a computer I don't use I will do the experiment with the case open.  I will go as far as cutting the power lines and fixing them to the relay.

That's getting a little ahead of where I am. Here's the project:

Use a 12-button keypad (like a telephone) with 14 contacts (1 for power, 1 for each of the 12 buttons, and 1 dummy) to enter a 3-digit security code in order to be able to power on a computer. The circuit is connected to the power-on button in the computer, which therefore won't work unless the code has been entered.

The contacts for the 3 digits used for the code are connected to 3 of the 4 AND gates in a 74HC08:
  • Gate1 input1 is connected to digit 1 of the code, a 10K pull-down resistor, and GND. Input2 is connected to the input of Gate1 of the 74HC04 inverter, a 10K pull-down resistor, and GND.
    The output is connected to input2 of AND Gate2, and also through a diode back to Gate1 input1.
    So, Gate 1 input 2 is always HIGH, since the inverter input is always LOW.  When the digit is pressed, input1 goes HIGH and stays there due to the diode for latching (see experiment 19). H/H ANDS to H, so input 2 of Gate 2 is H only when digit1 has been pressed.
  • Gate2 input1 is connected in the exact same configuration as Gate1:  10K resistor and GND, also a diode and gate2 output.  Thus, if digit1 has been pushed, input2 is H and if digit 2 is then pushed input1 is H, making output H and latching there.
    Output2 goes to Gate3 input 2 as well as back through the latch.
  • Gate 3 input 1 is connected to a pull-down resistor and GND and to digit3 (no latch). So only if the first two digits have been entered successfully, input 2 is H, and when digit3 is pressed the output3 is H.
    Output3 (Gate3 output) goes to Inverter Gate2 input.
    Inverter Gate2 output goes to pin2 (trigger) of a 555 timer.  H output of AND Gate3 is inverted to L, triggering the timer.
The circuit then functions after the 3 digits are connected in sequence:
  • 555 pin3 (output) is connected to an LED==>10K resistor==>GND and also to the upper coil of the latching relay
  • So, when the 555 is triggered, the positive pulse flashes the LED and activates the relay, completing the power circuit inside the computer and allowing the computer to be powered on.
Two other keys of the keypad (* and #) are also in use:
  • The * key powers on the circuit, while it is held down.  I connects to an LED/resistor/GND to show that power is on, and to the power pins of the ICs (pin 14 of the logic chips, pint 8 of the 555). It also connects through a 100K resistor to pin 7 (discharge pin) of the 555. 
  • The # key connects to the lower coil on the relay, as well as to an LED/Resistor/GND.  So when the button is pushed, the LED lights, and the relay unlatches, disabling the power on the computer
  • So, to start the process, press the * key and hold it while entering the 3 digit code, in sequence.  LED1 is on while the key is held.  LED 2 flashes when the relay is activated.  The * key can then be released, and the computer can be powered on.  After  the computer is powered down, the # key deactivates the relay and it can not be turrned back on again until the code is reentered.
The 555 serves to send a pulse to activate the relay.  In addition to the connections already discussed, pin 8 connects to pin 4 (reset), to keep it H while the * button is held.  Pin 7  also connects to pin 6 (threshold), Pin 6 also connects to a 10uf capacitor and GND. Pin 5 (control, connects to a .1uf capactor and GND). Pin 3 (output) connects to an LED/resistor/GND in addition to the upper coil on the latch, so it flashes the LED when the 555 is triggered.

Here's the schematic from figure 4-84 on p. 201 of the book:


Here's what I've done on the breadboard so far (a little messy):


I'll post another when I' closer, but it represents the schematic less the keypad.

For the keypad, I'm considering soldering a set of header pins, so I can either stick it directly in the breadboard or use F/M jumper wires as depicted below.  The top wire is power, The others are randomly connected for now, but they will go to the pads assigned to numbers as discussed above. Other options are to solder wires directly to the pads or to use female headers. 


More when I get to soldering.



Saturday, February 14, 2015

Friday, February 13, 2015

Happy Valentine's Day

I've been fascinated by electroluminescent wire (EL wire) for a while. I just needed a project in which to include it.   I got the idea for heart-shaped glasses for Valentine's Day and that seemed like the perfect fit.

I bought the Adafruit EL Wire starter pack in red and I was off and running.

I convinced myself that I needed 2 sections of EL Wire, 1 for each heart, but I wised up and did it with just one. The challenge was the crafty part (cutting hearts, sewing, the hearts to the cardboard, etc.

My original plan was to hot glue the hearts to some old glasses, but I found out that they work fine as an overlay to my regular glasses.


This was fun to do. I'll use EL wire again.  Here's the video.