I'm a leader not a follower!

I'm a leader not a follower!
Two Toads I rescued from the road!

Thursday, April 10, 2014

Panasonic DECT Cordless Phone KX-TGA672E with faint LCD

This Panasonic DECT cordless phone developed a fault where the LCD was very faint and adjusting the contrast made no difference. This fault was traced to the flexi-circuit from the LCD to the main printed circuit board of the phone. It was bonded in some way to provide the electrical connection and was not soldered. To fix it I cut up a rubber eraser to the correct size the width of the flexi-circuit and a thickness of (1.5mm). This eraser helped to push down on the flexi-circuit when the white LCD housing was clicked onto the PCB. This fixed the fault and the LCD is now as it should be and the contrast adjust also works. Very annoying fault and a result of cheap manufacture not lasting very long.
Thanks for reading, I hopes this helps someone.

Wednesday, February 5, 2014

DG843GT List dhcpd Clients

I wanted a way of listing connected devices that have been served an IP Address using the command line on my DG843GT ADSL2+ router with DGTeam Firmware. This firmware allows ssh login and the ability to change the noise margin amongst other things.

I began by looking at the link for attached devices on the admin webpage of the router. This URL was examined and the command nbtscan was noticed.

This was tried on the command-line but it didn't seem to do anything , nbtscan --help didn't help either.

I thought it must be something to do with arguments so I tried nbtscan (my routers IP Address) this listed the attached devices so it's a result.

I haven't written a script using expect to get and extract this info automatically yet but it's on my todo list.

Example of the command and its output xx added to anonymise my MAC addresses
 # nbtscan;UNKNOWN;00:xx:83:2D:xx:BA;TORE;00:1F:xx:C8:xx:B5;UNKNOWN;00:1B:xx:07:xx:A3;DEB;D6:56:xx:FE:xx:57;DAD;00:30:xx:46:xx:2E

Tuesday, February 4, 2014

Linux Tinyos example for patching a header file

 I was having problems making a simple program for TinyOS using the command :-

make micaz

The micaz is the target device and can be other devices like iris , telos & tmote etc.

The error I got was:- 

error: variable ‘McuSleepC__atm128PowerBits’ must be const in order to be put into read-only section by means of ‘__attribute__((progmem))’

From reading around the issue is documented here.

The patch is downloaded to the ~/tinyos-main/ directory and it patches the atm128const.h file to prevent the error messages.

The patch is applied using the following command:-

patch -p1  < tinyos-atm128-const-fix.patch

Wednesday, January 29, 2014

Pentalobe Screwdriver Size Modification for the Macbook Air

 Remember that using tools can be hazardous so wear eye protection and proceed with caution , if in doubt don't do it.

I had the annoying problem in that the Pentalobe screws for the Macbook Air I was repairing were too big for the Pentalobe screwdriver I had lying around , it was one supplied in a kit for replacing the LCD on an iPhone. I then realised that the head on this screwdriver has a stretched sort of taper so I basically ground the end of it with a grindstone fitted to my Dremel tool until it fitted the screw-head , testing the fit as I went. Job done , although the modified tool will now no longer fit the iPhone , that's not too much of a problem because iPhone replacement LCD's usually come with the tools required to do the job.

Ground Down Pentalobe

Tuesday, November 12, 2013

Wireless Charging on a Star S7189 Mobile Phone

Warning: while soldering be careful of solder fumes, wear eye protection and don't burn yourself.  Note that charging batteries can be dangerous especially Li-Ion but the work detailed here means we are effectively generating our own internal 5V supply in the phone and connecting this directly to the USB power connections as they come into the phone. It is the equivalent of connecting a micro USB cable to the phone from a 5V USB charger, only its wireless. You have been warned and I am not responsible for your actions.

S7189 Display

This S7189 quad-core Android phone from Star was pretty cheap around £100 and it worked well.  I found the front facing camera was not the best, but for the price I can live with it. Screen was also pretty good with a reasonable viewing angle. It was also pretty slick running any Apps I downloaded from Play with no signs of lagging.

Palm Internal Charging Circuit
I wanted to add wireless charging to the S7189 so I didn't have to keep plugging the charger into the micro USB connector. I noticed on HackaDay that some people had added wireless charging to their mobile phone , this is what I wanted. So I ordered a wireless Palm case back from Ebay for £3.

Palm Back Cover

I then using scissors cut out out the area of plastic bounded by the Plastic label with Palm on it. This was to allow one to be able to peel off the label more easily from inside the case. I then stuck the label on some plastic film (after removing the circuit board, coil and metal discs) to preserve its stickiness.  

Circuit Cut Out of Plastic Cover
The coil and circuit board were removed from the old Palm cover by soaking in a plastic tub of Methylated Spirits for a few hours to soften the double-side sticky tape holding circuit and coil onto the plastic cover.

Sticky Cover Preserved

Stuck to Clear Film

S7189 Back with Cover Removed

The S7189 internal back cover is removed (quite a few small black screws) exposing the Circuit board. I plugged in a Micro-USB adapter to find out where the center conductor was connected to on the Power PCB at the lower part of the phone using a multimeter set to continuity tone check. Ground was the metal tabs of the Micro-USB connector. I used Kapton tape to insulate the sticky copper foil I was using to route out power to the top of the back cover.

Ground Connection

I then soldered flexible tinned insulated wire between the two Copper tabs next to battery, taking care not to overheat the plastic.

Routed Copper Tape

Palm Charge Circuit Added to S7189 Back Case
The removed Palm charge circuit was stuck to the middle of the S7189 back cover using its original sticky cover. Of the two small square gold connectors to the left of the Kapton tape the Lower one is the +5V the upper one is 0V or Ground. To be sure check the output yourself with a multi-meter to ensure you have the correct polarity before connecting it to your valuable phone.

Phone Placed on Charger

Phone Now Charging

The S7189 is now able to be charged either by using the Micro-USB or wirelessly via the Palm Touchstone charger. Note: don't use both at the same time or there could be overcharging problems with subsequent overheating and fire from the battery and circuit boards.

Pure Evoke 1 Crackly Burbling Audio

Warning: while this radio is low voltage around 12V dc no mains voltage appears in the actual radio, so it is relatively safe to work on. The wall-wart power supply itself however is mains voltage ( in my case it's 230V AC ) so this needs to be treated with respect. Also while soldering be careful of solder fumes, wear eye protection and don't burn yourself. You have been warned, I am not responsible for your actions.

I have had this Pure Evoke 1 DAB radio for about 7 years but it started having problems. The audio became crackly and it also had an associated burbling noise. The signal quality displayed for the radio station I listen to normally which previously was 97 was now wavering between 40 up to about 70.
The first thing I tested was the most accessible thing the wall-wart power supply. This power supply seemed to be ok, measuring around 17.4 volts dc on my Fluke multimeter.

Evoke 1 Amplifier Board
I opened the case of the Evoke (remove all the screws on the back of the case) this is where I noticed that the antenna f connector was loose. I tightened the f connector using an adjustable spanner and pliers. Thinking it was a poor signal because of the loose connector I switched it on again but the audio problem was still present. I then proceeded to measure the regulator voltages on the main audio board. Most voltages appeared ok, however I noticed that the 3.3v supply which supplies the RF board was not solid but was wavering round quite a bit. I examined the electrolytic capacitors on the board but found no evidence of them being swollen due to localised heating from the various heat-sinks on the board.
So I started removing the capacitors on the amplifier board one-by-one to test them on my Peak capacitance and equivalent series resistance meter. All capacitors measured well within 10% of their marked values and low ESR apart from one capacitor, C7 a 100uF 16V electrolytic which is located very close to a regulator heatsink that runs very warm. Its value measured low and its ESR was higher than it should be so it appears that it is effectively being dried out over time.

Faulty Capacitor C7 on the tester
 I replaced this capacitor with one of equivalent value but its voltage rating was higher at 25V this is not a problem in this application.

When I soldered the new capacitor into the board I bent the new capacitor body away from the offending 3.3 V regulator heat-sink to prevent the new capacitor being dried out with the heat.
Capacitor bent away from heat-sink
The signal quality returned to 100 after the repair, I soak tested the radio to ensure that it was repaired.

Job done. Thanks for reading and good luck if this is what has happened to your Pure Evoke 1.

Saturday, September 21, 2013

Use an ATTiny45 to auto-boot a NAS200 on power up

I make no guarantees for the information contained herein, I also cannot be held responsible for data loss as a result of your actions, we make our own decisions.

I needed a way of booting the Linksys NAS200 automatically when powered up. As standard from Linksys the NAS200 just stays off when powered up. The Power button on the back left hand side when looking at the rear of the NAS200 needs to be pressed to start the NAS. I often found that when I tried to connect to the NAS it was powered off usually due to a power outage that occurred through the night. I would then have to go upstairs to power it on and wait for it's disk check to finish before I could actually use it. So I set out to fix this inconvenient feature of the NAS200.  First power off and disconnect the power supply then remove the hard drives so they don't get damaged. I numbered the drives 1 and 2 to match the bay they came out of before removal just to be sure they went back into the correct drive bay.  I proceeded to open up the case of the NAS. This involved removing the silver painted base cover using a screwdriver to lift the plastic sprung pillars out and then slide the cover to the front of the NAS. Four screws included one covered by a warranty sticker ( only proceed if you are happy having no warranty and only if you are confident of success ) are removed. This allowed removal of drive bay 2, be careful of the power wires to PCB and SATA connector. Another four screws are removed to remove drive bay 1, again be careful of SATA and power cables. This will allow the main PCB to be accessed. Four screws are removed and this allows the PCB to be removed. An 8 pin socket was procured, pin 4 was soldered to the rear of one of the PCB mounted USB socket, pin 8 was connected to the 5V pin on the LM7805 voltage regulator see the picture below.

NAS200 ATTiny45 in Socket

Pin 5 is connected to the conductor of the power push button at the rear of the PCB via a flexible insulated wire, I soldered it to the top of the push button.

The ATTiny45 was programmed using an Arduino Uno programmed with the ISP Sketch, it's in the Arduino IDE examples, remember to choose the correct board and serial port in the IDE. See my previous post on how to program the ATTiny45 with the Arduino Uno Board.

The AutoPowerON.ino sketch basically sets up the port pins we are using as inputs this gives us the high impedance state so the pins don't affect the NAS200 power up or switch off function using the button. After 10 seconds (just to be sure the power has settled) from power being applied the pins on the ATTiny45 being used are set as outputs and PB0 PB1 go low and high respectively for half a second. They then return to high impedance state, the NAS200 has begun booting. After this the program in the ATTiny45 is then caught in an infinite loop, this ensures the pins are only pulsed once for each power cycle.
Note* I only use pin 5 this is the active low output, pin 6 can be used for circuits that may need an active high 5V pulse.
Code I used is pasted below I saved it as AutoPowerON.ino :-

 NOTE* This Sketch will pulse a Pin low on the ATiny45
 This is to auto power up a NAS box to ensure it
 is available after a power cut. It normally has to be
 turned on by pressing the power button.
 If using an Arduino to program these devices you need to 
 program the ISP Sketch found in the IDE onto the Arduino 
 So the circuit will pulse a pin low after a
 predetermined amount of time say 10 Seconds
 This pin will be connected the same part of
 the NAS box's push button circuit to simulate
 a button press.
 We only want to do this procedure once on every power up.
 hence the capture while loop at the end of the loop function.
                 PB2 |    8     |PB4
               +-----|7        3|----+
                 PB1 | ATTiny45 |PB3               
               +-----|6        2|----+             
TO               PB0 |          |PB5             
Push Button    +-----|5        1|----+          
                     |    4     |    

(Wiring Diagram for Auto Power On Circuit)
 By Jim Park jim (dot) buzz (at) gmail (dot) com
 Coded :- 18/09/13
int PowerPin = 0;          // Pin 5 to power up the NAS if it's active Low  
int PowerPinInv = 1;       // Pin 6 to power up the NAS if it's active High

void setup() {
// declare pins as O/P's or I/P's
  pinMode(PowerPin, INPUT);           // HI-Z pin
  pinMode(PowerPinInv, INPUT);        // HI-Z pin

void loop() {
// Now delay for 10 Seconds
  delay(10000);                       // 10 second delay to be sure power is stable
  pinMode(PowerPin, OUTPUT);          // Remove HI-Z state from pin
  pinMode(PowerPinInv, OUTPUT);       // Remove HI-Z state from pin
  digitalWrite(PowerPin, LOW);        // Active Low on Pin 5
  digitalWrite(PowerPinInv, HIGH);    // Active High on Pin 6
  delay(500);                         // Half a second delay
  pinMode(PowerPin, INPUT);           // Back into HI-Z state
  pinMode(PowerPinInv, INPUT);        // Back into HI-Z state
  while(true){}       // Capture for ever......and..ever.........

The programmed ATTiny45 is inserted into the socket carefully ensuring that pin 1 on the ATTiny45 goes into pin 1 on the Socket ( see the photo above ). The unit was tested by plugging in the power to the NAS, after 10 seconds the familiar boot beep with the flashing leds occurred. After the full boot the NAS was available on the network all without having to press the power button. :)