Friday, 21 March 2008

Dreambox 7025 Timer Edit Bug

With the DM7025, you can add a timer through the TV by selecting the ‘info’ button when watching a programme. Once this is stored, if you go to the web server, and try to edit it, you get the error message: “Please only use the characters …. in the name and description field”. You get this message even if the name & description field appear to have valid characters.

This appears to be due to the add timer mechanism through the TV puts invalid characters into the recording entry - these characters look like spaces in the web edit page, but are not actually spaces.

I suspect that these characters are unicode control characters.

The answer, therefore, is to replace anything that ‘look like a space’ with a space.

Wednesday, 6 February 2008

Citroen Xsara Central Locking

After a flat car battery, my Citroen Xsara (2003) remote locking fob (PLIP) stopped working.

After searching on the internet, I found that if you hold the Lock button down for more than 10 seconds whilst the key is in the ignition, it will marry back up to the car and everything will be fine. Well, it didn’t work!

I went into Dutton Forsharw’s in Preston, and was told that sometimes after a flat battery, the car ‘forgets that it has central locking’ - that didn’t make sense to me as it was the fob that was messing me about. The guy took the fob away and came back telling me that it could not be married up to any car, and I’d need a new fob at £140.

I’ve been using the key in the lock for the past week, and today, the car central locking stopped working completely. This is a real problem as it is now impossible to lock the boot!

I found a sequence on the Citroen Owner’s Club Website, thanks to Andy which tells you to:

  1. Put the driver’s window down, lift the bonnet and ensure all equipment is switched off.
  2. Ensure all doors are closed and remove key from the ignition.
  3. Wait for 3 minutes, disconnect the vehicle battery and wait 15 seconds.
  4. Reconnect the vehicle battery, wait a further 10 seconds (do not open doors.)
  5. Switch on the side lights through the driver’s window.
  6. Switch on the ignition and check system’s functionality.
  7. Hold lock button on key down for 10 seconds.
  8. Remove key open & close door test central locking system
  9. Start the engine and complete the system’s check.

I went through this sequence, and lo-and-behold, the central locking works again. The fob, however, even with a new battery still doesn’t work.

All I can think is that the car computer holds many parameters in RAM, and if the battery voltage gets low, this RAM gets corrupted. When you re-charge the battery, the computer doesn’t reset, and it is possibly this faultily operating computer that talked to my key fob in swaheli and trashed it.

Unplugging and re-connecting the battery enabled the computer to start working correctly.

I’d suggest that whenever a battery in a Citroen gets very low, the computer should be re-set by disconnecting and re-connecting it before doing anything else.

If I’d followed the charger instructions properly, I’d have disconnected the battery to charge it anyway!

Fixing the Remote

I took the car into Dutton Forshaws in Preston, and they told me that the remote was broken, and I’d have to buy a new one. This seemed strange - how could letting a car battery go flat break the remote?

I was only passing through Preston, so took my car into my local Citroen Dealership in Letchworth and asked them. They told me that there was absolutely nothing wrong with the remote, and took the car to the service garage to take a quick look. The guy came back about 10 minutes later with a puzzled look on his face, and suggested that it needed to be brought in for a full service, so I booked it in.

On driving out of the garage, I noticed that the indicators didn’t work - neither did the wipers, nor the headlights … I took it straight back, and the puzzled guy took the car back. 5 minutes later, he cam to me and told me that the lights, and wipers were now working fine … and by the way, so was the remote!!

He had done a full reset of the computer - this is something quite fundamental, and does not appear to happen normally when the battery is removed. I have no idea what this reset is called, but suspect that they are reluctant to do it as the car also looses some other important parameters (perhaps learned engine tuning parameters?).

Anyway, the car is now working fine!

My lessons learned -

  1. Follow the instructions properly on how to reset your car after a flat battery.
  2. If the daft car repair man tells you something is broken - something that was not involved in the original problem, go get a second opinion.
  3. Make sure absolutely everything is reset in the computer, and you may get your keys to work.
  4. Use the Letchworth Citroen Repair Centre - they are extremely helpful and considerate.

Sunday, 3 February 2008

Bad Battery Day

I used one of those timer heater thingies to defrost the windscreen of the car from the inside before you get out in the morning. It is essentially a clock with a big battery and heater, and you set it to come on 30 minutes before you get out in the morning. You then charge it in the cigarette lighter whilst you travel so that it is ready for the next day.

Well, I set the clock incorrectly, and left the defroster plugged into the cigarrette lighter. Needless to say, when I got to the car in the morning, the window had frozen again, and the unit decided to go back onto a charge cycle, and I had a flat battery.

I was supposed to be taking Colin into work with me, but as he was ill, he lent me his car to get to/from work. As I was in his car, I didn’t have my mobile phone charger with me, so by the time I got to work, the phone battery was flat.

Now, my car does everything for you, including automatically switching off the lights when you get out. Colin’s, however, is not. I really could have done with my mobile phone charged so that I could call the RAC for a jump start.

I hate Mondays!

Tuesday, 25 September 2007

FSG3, SMF, Visual Verification Headache

I am running the Simple Machines Forum software (php) on an Freecom FSG3 Network Storage Box, and have been banging my head on the table because I cannot get the visual verification function to work - all I see is the randomised dots, and no letters in the middle.

The server is Apache, so I checked that it could do graphics - I ran httpd -l to get a list of all of the included modules, and didn’t see the ‘gd’ module, which is needed for the graphics - I though that was it, and wasted a long time trying to cross-compile Apache (that’s a different story). Eventually I found that if you create a php file as follows:

And access if from your webserver, it tells you everything you need to know, including the fact that the gd modules are, after all, included.

Configure Command: ‘./configure’ ‘–prefix=’ ‘–target=arm-linux’ ‘–host=arm-linux’ ‘–build=i686-pc-linux-gnu’ ‘–with-mysql’ ‘–with-apxs=../apache_1.3.33/apxs’ ‘–with-config-file-path=/usr/local/apache/conf’ ‘–enable-mbstring’ ‘–with-gd’ ‘–with-png-dir=/lib’ ‘–with-jpeg-dir=/lib’ ‘–with-zlib’

Knowing that it was after all supported, I started to delve into the php code for the server, looking at each function in turn to check if it was supported. The only thing that was not supported was the true-type-font functions, but this didn’t matter as the code checked for it.

Eventually, I looked at the manpage for the imageloadfont, and saw the following:

“The font file format is currently binary and architecture dependent. This means you should generate the font files on the same type of CPU as the machine you are running PHP on.”

It all became clear. The FSG3 is a big-endian system, whereas (I presume) the SMF software was tested on a little-endian system.

The simple act of replacing the font files with big-endian versions enabled the visual verification system to work.

If you just see random dots and no text in the SMF visual verification image, and your system is big-endian, simply replace the gdf font files with big-endian versions.

Saturday, 15 September 2007

My Windows Vista Machine cannot access my NAS Shares

After falling over in the house, and pushing my crutches through the screen of my laptop, I’ve replaced it with another one - this is running Vista.

The very first problem I encountered was that I couldn’t see any of the network shares that I used to see on my old XP machine. After a lot of searching, it seems that Microsoft have beefed up the network file sharing security, and made Vista incompatible with old file sharing system security features by default.

There is a registry hack to re-enable this old mode (Using regedit to set the LMcompatibilityLevel to 1).

I have since found that my PC is very slow copying files on the network - to copy 400 files, totalling just 1Mb from a zipfile onto a network drive took 50 (yes Five Zero) minutes.

The real solution is to upgrade the server software at the other end to be compatible. I’m running samba on a Freecom Network Storage Box (FSG3), and upgrading to the latest firmware, which includes samba version 3, has allowed these shares to be seen again.

This may not be the end - at the moment, the machine seems to be running OK.

There is a hotfix available from Microsoft (Knowledge Base Article 931770 - The copy process may stop responding when you try to copy files from a server on a network to a Windows Vista-based computer), but I’ve not applied it at the moment….

Sunday, 9 September 2007

Running a DNS Server on an FSG3 Network Storage Box

I have a NAS box in the house, which is used to store my music and video. In the house, also, I have an internet radio / media player, and a networked satellite receiver, and of course, a webserver which recognises several different names (virtual hosts) to direct the access to different directories.

I want to be able to refer to these devices by name, rather than IP address, but I don’t want to go around hacking hosts files on every machine - the solution is to use a named server, and point all the machines in the house towards it. This has the advantage that I can override the internet recognised domain (e.g. trumpton.org.uk), to divert the address locally.

I have just upgraded my FSG3 to the latest kernel (2.6).

Firstly, I needed the name server (in a package called bind), and a dependant package (openssl). I downloaded bind_9.3.4-1_armeb.ipk and openssl_0.9.7m-2_armeb.ipk, and installed them on the FSG3 with the ipkg command.

Next, I created the name server files. Rather than storing them in the default /opt directory, I have decided to install them into /home/named - this means that the files will be retained following any firmware upgrade (on this particular device).

Note that in these files, a semicolon indicates the start of a comment, not the end of a line. If there are no comments, no semicolons are needed.

The first file is named.conf:

options {
pid-file “/home/named/named.pid”;
directory “/home/named”;
port 53;
};

// Internet Root Servers
zone “.” {
type hint;
file “root.zone”;
};

// Local Host Loopback
zone “0.0.127.in-addr.arpa” {
type master;
file “db.local”;
};

// Local network Addresses
zone “local” {
type master;
file “local.network”;
};

// Local netork Reverse Addresses
zone “14.168.192.in-addr.arpa” {
type master;
file “rev.local.network”;
};

// trumpton.org.uk
zone “trumpton.org.uk” {
type master;
file “trumpton.org.uk”;
};

The file contains pointers to all of the named configuration files - the options section identifies where files reside, the zone sections identify the forward (i.e. loking up www.trumpton.org.uk) and the reverse (i.e. looking up 192.168.14.1) files. The special zone file ‘.’ has pointers to other servers on the internet for the various naming authorities (RIPE, ARIN etc..).

The ’local’network’ file contains the names for the local (internal) network:

@ IN SOA webserver.local. junkmail.trumpton.org.uk. (
2006012103; serial
28800; refresh, seconds
7200; retry, seconds
604800; expire, seconds
86400 ); minimum, seconds;
NS web.local.;
;
MX 10 web.local.;
;
local. A 192.168.14.1
internet A 192.168.14.1
cam 192.168.14.100
desktop A 192.168.14.101
satbox A 192.168.14.102
nasmedia A 192.168.14.103
netradio A 192.168.14.104

web A 192.168.14.105

The part at the top of the file is used to put a timestamp on the file, and tell other servers on a network how often they should be updated. The list following, gives the names of all of the machines, and their corresponding IP addresses.

Of course, if you have an IP address, and want to know the machine name, you need reverse lookups - that is what the rev.local.network is for:

@ IN SOA webserver.local. junkmail.trumpton.org.uk. (
2006012103; serial
28800; refresh, seconds
7200; retry, seconds
604800; expire, seconds
86400 ); minimum, seconds;
NS web.local.;
;

1 PTR internet.local.
100 PTR cam.local.
101 PTR desktop.local.
102 PTR satbox.local.
103 PTR nasmedia.local.
104 PTR netradio.local.
105 PTR web.local.

The file ‘trumpton.org.uk’ contains the name lookups. Note, however, the MX entries here - these point to my service provider’s mail exchange, as in my case, all mail goes through their servers, and I do not run my own mail server. If I did, these would simply point to ‘trumpton.org.uk’. Note the ‘.’ at the end of a name - if the dot exists, it indicates that this is the end of the name, and if it is missing, the domain specified in the named.conf file for this particular file is appended.

@ IN SOA webserver.local. junkmail.trumpton.org.uk. (
2006012103 ; serial
28800 ; refresh, seconds
7200 ; retry, seconds
604800 ; expire, seconds
86400 ; minimum, seconds
) ;

NS web.local.;
;
MX 10 easymx2.easily.co.uk.;
MX 10 rhea.easily.co.uk.;
;
trumpton.org.uk. A 192.168.14.105
www A 192.168.14.105

Once the files are in place, it’s just a matter of editing the S09named script that was installed in the ipkg to refer to the correct directories, copying it to the /etc/rc directory, and starting it with /etc/rc/S09named start.

Im my case, the ‘pidof’ program was missing. Rather than installin the bundle that includes pidof, I created /bin/pidof

PSLIST=”`ps -ef | grep $1 | grep -v pidof | grep -v grep | cut -c1-5`”
echo “$PSLIST”

Now, the computers on the network need to be pointed at this DNS, rather than the firewall’s one. Usually, it is possible to add at least two entries, mine are:

nameserver 192.168.14.1
nameserver 192.168.14.5

Saturday, 8 September 2007

Paragliding - What Not to do !

I’ve recently been on holiday to Spain, for a week’s paragliding.

My first day was excellent, with a nice 3 hours flight, getting to a height of 2.5km above ground level. A great triangular flight, covering 35km, and getting back to the top of the mountain.

The next day, however, things weren’t quite so great. We used a take-off site I had never visited before - I am always apprehesive on take-off, and a new site only increases the stress. I set up on the hill, at which time there was nill wind. The logical thing to do was to wait for a thermal to come through.

Well, the thermal came through, and I picked up my paraglider - it was slightly off to one side, so I corrected with the brake lines and turned round to face the direction I’d be running. The paraglider then dipped off slightly to the right, so I adjusted with the brake as I began to run. At this point, I’m not exactly sure what happened - either I stumbled, or I was picked up and dumped by the back end of the thermal - it is likely that as this happened, I put on a lot of left brake, as I flew to the left across take-off, crashing left-foot first into the mountain.

I rolled over onto my back, and my left foot wasn’t quite pointing the direction it should have been. Now I was surprised that this did not hurt as much as I thought it would (I had actually broken my ankle and fibula, and it seemed to hurt less than when I broke my toe a few years ago).

After about 20 minutes, the ambulance, police and local doctor appeared on the side of the hill. Fortunately, I’ve been learning Spanish at my local college, and could manage some rudimentary communication. The doctor gave me the once over, worried that I had damaged my spine - I explained that the crash was relatively slow speed, and that my paraglider harness had protected my back.

It took 6 people to carry me down the 20 yards to the ambulance. After another check by the doctor, I was bundled off to the hospital (1 hour away in Ávila).

Now I had it in the back of my mind that there was a maximum amount of morphine you could take, and I thought that I’d need everything that I could have to get me through the night. As the pain was not excruciating, I refused painkillers. The time I really wished I had had some morphine was when they took my tight boot off (this hurt quite a bit) - anyway, at least my foot was pointing in the right direction afterwards.

The surgeon explained that I’d need an operation to fix the bones in the ankle. We had a conversation of risks of travelling, waiting and DVT, and I chose to have the operation in Spain, rather than wait until I got home. 5 hours later, I was in surgery.

They gave me an epidural, which was an interesting experience, as you were completely with it, and could hear everything that was going on (they didn’t let you watch). The incision felt strange - it felt like someone drawing on your foot with a biro - that was the only sensation I had. I heard some drilling, and the staple gun (used to close the wound), and the 20 minute operation was over, and I went on to spend a couple of hours under observation, until the anasthetic wore off.

I then spent a couple of days on the ward - and by this, I mean in room with one other patient. Spain is very different from the UK in the way hospitals work - firstly, they seem to work ! - and secondly, it is normal for the family to look after the patient in the hospital, washing, feeding, fetching water etc… There is no ‘visiting time’ as such, in fact, it is the opposite “Families must vacate for 1 hour a day, when the doctors are doing their rounds”. It is not uncommon for a family to stay with the patient throughout the night.

My room-mate had a head injury, after a light aircraft accident, and was suffering from double vision. His wife never left the room (unless the doctors came round, or I needed a pee).

I guess one of the worst things was the heparin injections that were given in my stomach fat (thank heavens I have quite a bit of that!). After 2 nights, I was discharged, went back to Steve and Puri’s, and spent the rest of the week chilling. The local nurse cleaned and re-dressed the operation wound, and taught me how to do my own injections.

My insurance company made arrangements to fly me back business class, and then taxi me to my door. The following Monday, I went to the local hospital, where the surgeon was pissed off that I had the audacity to have my operation done in Spain. I had the half-cast replaced with a full-cast, and ambled home by taxi for 5 weeks of lying with my foot elevated.

After three weeks, the cast had become so loose, the leg was supporting the cast, rather than the cast supporting the leg. I returned to the hospital, where it was replaced. I’ve just over a week to go before the cast comes off, and it is getting loose again …..

It’s now a week or so later, and I’ve got rid of the cast. My left calf muscle is almost non-existant (wasted to less than half its original size in the 6 weeks of rest).

I’ve got some excercises to do, and a visit to the phisiotherapist, but within a couple of weeks, I should be able to get rid of the crutches, walk and drive again.

For now, I’ve to keep the weight off it and gently excercise it, but it will be a while before I am flying again.


Connecting Silvercrest SBF75 Scales to An Android Phone using OpenScales and Google Fit

Overview This guide includes the steps to connect a Silvercrest SBF75 set of scales to Google Fit on an Android Phone using the OpenScales a...