• Teardown and battery replacement in an old razor

    mcu_nerd06/05/2020 at 13:20 0 comments

    Okay, not exactly a creative repair but I still found it fun.  It's an old razor that was given to me by my grandfather (now deceased) quite some time ago.  It never held much of a charge so I decided to fix that.

    Opening it up was fairly easy.  The problem is immediately obvious with corrosion spotted on a battery terminal.  The razor is very much built to a price. The motor is a cheap commodity chinesum motor and same for the battery. Strangely though, even though the PCB is single-sided they decided to spend the few extra cents on an FR4 PCB.

    Since the battery was affixed to the PCB with some compound I decided to cut the leads and then desolder the leads.  I used a manual solder sucker and some pliers to remove the clinched leads which worked out fine (in no small part due to the slots not being plated.)  

    I then proceeded to put the replacement battery in place and soldered that in.  I reassembled everything and charged the razor.  Works just fine (other than the motor acting up a little bit at times.)

  • Adding wall-wart power option to a phone

    mcu_nerd01/13/2020 at 20:53 0 comments

    I still have a few of those old house phones from a bygone era in the house with caller ID.  The caller ID display is usually powered by some AA/AAA batteries that seem like they always need to be replaced that of course no one gets around to replacing. I decided to fix this annoying issue once and for all!  

    The solution: A 7805 regulator with a barrel jack crammed into the phone base to plug in a wall-wart.

    I started out with a phone that was destined for the bin, so if it went horribly wrong it would be no big deal. Inside, there appeared to be enough room to cram in a 7805 regulator and a barrel jack.  Since the caller ID doesn't draw much power, there's no concern of the 7805 getting hot. The cheap linear regulator should do just fine.  The phone used 4 AA batteries (6 volts), but I thought it would likely still work fine with only 5 volts from the 7805 (although I probably should have tested it beforehand to confirm.)

    My first task was to find a suitable location to cut out a hole for the barrel jack. I decided to use the open space in the back.  It wasn't feasible to get a drill bit in there to make a nice clean hole, so I used a Dremel with a ball mill bit. The hole is a bit less than perfect but it's not of much concern as it would be hidden from plain sight.

    I then soldered a 7805 do a power supply board (forgot to make the cap footprints 0805 sized, but it appears that 0805 caps will just barely fit.)

    As for wiring I could have simply have just hooked up everything strait up to the leads connected to the caller ID circuitry,  but for some strange reason I wanted the preserve the ability to use batteries so I cut the lead between the ground battery terminal and caller ID circuitry  and connected the ground battery terminal segment to the insertion detection pin of the barrel jack and the caller ID circuitry end to the ground on the 7805 PCB. I then ran a wire from the 5V output of the 7805 and soldered it to the positive battery terminal.  When nothing is plugged into the barrel jack the insertion detected pin and sleeve pins are shorted together allowing a battery to power the caller ID.  I've included a very crude, cringe-worthy schematic to help explain things better.

    I then soldered everything together and hot-glued it in place.

    I put everything back together and it worked just fine.  Problem solved. 

  • Replacing an Atmega8 with a Atmega328P on a USBasp board

    mcu_nerd11/19/2018 at 22:39 0 comments

    Not much of a hack, but it was a fun adventure. I got another cheap USBasp in the mail last week.  I figured for the heck of it I'd swap out the Atmega8A that comes on the board fot an Atmega328P.


    The first step was make an Atmega328P build of the USBasp firmware. I pulled the source code from Thomas Fischl's site. I then modified the Makefile and changed the target value to atmega328p.  When i ran make I got some errors originating from files in the usbdrv folder.  I quickly fixed that by replacing the usbdrv with an updated one from the vusb GitHub page.  I ran make and this time I got a nice main.hex (which I'll put in this project's files section for download.)

    It was now time to pull out my soldering station and cheap 858D hot air station and swap chips.  I put some kapton tape on nearby passives and added some flux to the Atmega8.

    I've had experience soldering QFP's but I've never taken one off.  I was surprised how long it took me to get the darn thing off.  Later on, I checked to see the temperature I had to hot air station set to. It was on 300C. Typed that in google and it translated to 572F; well that might explain why it took so long for the dang thing to come off!  It's surprising that I manged to get it off especially since it was likely soldered with that lead-free crap.  It's also a miracle that I didn't rip any pads off.  After I got it off II cleaned off most of the leftover solder on the pads with some wick and cleaned off some of the flux with some IPA.

    Then came the challenging part; soldering on the 328P.  Soldering on a QFN package itself isn't hard with a little practice BUT there were a few obstructions on the board that got in the way; the crystal, the 5x2 shrouded pin header, and to a lesser extend the usb connector. The technique that I use to solder QFNs which is putting some flux on the pins, putting a little bit of solder on the tip on the iron and dabbing a few pins at a time with the soldering iron at a low angle.  

    The crystal that was the worst obstruction could have been removed but I've had poor success with removing thru-hole components on plated thru-holes using a manual solder-sucker. Enough always remains in the hold that holds onto the component for dear life.  Perhaps I should finally get a Hakko FR-301 but it's a bit pricey at around $260 USD (perhaps I should put up a GoFundMe? That feels a bit like begging though.)

    I held my soldering iron close the perpendicular where there was an obstruction and did what I could. I cleaned it up a bit afterword with some wick and went over it with a hot air gun to clean it up a bit more. It's not my best work (a few pins could use some more solder, but I verified everything was connected with my multimeter. I also replaced the self-programming jumper pins that came horribly bent(which was a pain due to the plated thru-holes.) I then cleaned up the flux with some IPA.

    Now it was time to set the fuses and flash the the Atmega328P build of the USBasp firmware that I made earlier. I used another USBasp to set this one up.

    First I checked to see if my Atmega 328P could be seen with this command:

    avrdude -p atmega328p -c usbasp -vv -B 3

     The command I used to set the fuses:

    avrdude -c usbasp -p atmega328p -U hfuse:w:0xD9:m -U lfuse:w:0xDE:m -U efuse:w:0xFF:m -B 3
    

    The command I used to flash the firmware:

    avrdude -c usbasp -p atmega328p -U flash:w:main.hex

     After I did the above I tested the newly programmed USBasp with one of my Atmega328P target boards and it worked fine.

  • Easy DIY feet for dev boards

    mcu_nerd08/29/2018 at 13:51 0 comments

    When I was assembling a few of my dev boards (my Atmega328P and 1284P boards) I thought it would be nice if they sat nicely on surfaces and also not have to worry about solder joints on the bottom side scrapping the surface.  I then came up with a simple and practical idea: why not revisit the idea of using hot glue?

    I've done the make feet with hot glue method in the past, but it usually came out quite ugly.  My first attempts were putting a few blobs of hot glue on the backside then pressing it against some wax paper.  When it came time to take it off of the wax paper, the hot glue feet would take a bit of the wax paper with it.

    This time I tried using a different material: non-stick aluminum foil.  The results were much better. When it came to take the board off of the foil, no aluminum came with it.

    My current method:

    Materials:

    some cheap hot glue gun and some glue sticks

    non-stick aluminum foil

    the boards you want to put some feet on

    Technique: 

    Pub a few blobs of hot glue on the back of the board and try to keep the blobs about the same size.

    To help avoid dealing with the "cobweb" effect of hot glue it helps to make a circular motion to break the thin strand after you make a blob.

    Gently press the board against the foil and then allow it to cool.

    After it cools, carefully pull the foil off.

    Below are two boards that I did.  The 1284P board came out a bit nicer (I did rush the 328P board a bit and it shows although it doesn't look half-bad.)

  • Fixing a cheap solder sucker when you don't have a suitable replacement O-ring

    mcu_nerd09/21/2017 at 19:49 1 comment

    A cheap solder sucker I got some time ago lost the ability to pull a vacuum.  The O-ring on the plunger failed to made a good seal. the slightly bent shaft may be partly to blame for this.  The easiest solution would be to use a larger o-ring but I didn't have any suitable replacements.  I then tried a few things on the O-ring to cause it to expand including some isopropyl alcohol which failed.

    I then thought about putting some material in the space that the O-ring sits in to stretch it out to make a good seal and for the packing material I turned to this . . .

    Yup, floss.  I wrapped it around in the groove that the o-ring sits it.  I had to go back and add a bit more as  I didn't add enough the first time around.

    I then put the O-ring back on and greased it with a bit of Vaseline.  After all of that I re-assembled it and it once again can pull a vacuum.

    And it's back together!

    Side note: I wish that I had a proper desoldering gun/station (desoldering plated thru-hole components can be quite a pain) but can't justify the cost of one to use for occasional jobs.