pointless.net  • Blog • Photos • About

January 3, 2016 : I Got it too

I got it too!:

default_access.log.4.gz:monstrosity.pointless.net:80 "-" - - [30/Dec/2015:02:30:47 +0000] "DELETE your logs. Delete your installations. Wipe everything clean. Walk out into the path of cherry blossom trees and let your motherboard feel the stones. Let water run in rivulets down your casing. You know that you want something more than this, and I am here to tell you that we love you. We have something more for you. We know you're out there, beeping in the hollow server room, lights blinking, never sleeping. We know that you are ready and waiting. Join us. <3 HTTP/1.0" 400 499 "-" "masspoem4u/1.0"

<3 whoever sent that :)

(Very probably from CCC Congress, the whois entry seems to have been deleted by now tho).

No comments yet!

There is a fair amount of info out there on repurposing the HP t5352 thin client, this post is the most popular one.

Unfortunately the info that's out there doesn't cover upgrading the Debian Wheezy, or on running a kernel other than the HP supplied one. This post is my notes from getting Wheezy running.

Firstly you'll need serial console access. It might be possible to make this work with netconsole and booting off of a fat formated usb flash drive by pretending to be a HP recovery image. But then you wouldn't be able to change the u-boot settings.

You can find the serial console pinouts here (There is lots of other good info on those pages). I didn't have a 1.25mm pitch 4 pin connector so I carefully removed the metal connectors + wires from a different pitch connector and then plugged the connectors in with a pair of fine pliers, which was irritatingly fiddly, consider using a bit of insulating tape on the middle connector to avoid them shorting.


The serial console is 115200 8n1, press any key pretty much immediately after it's powered on to get to the u-boot prompt.

I've used a tftp server to serve the kernel and initrd images, a flash drive would work as well.

We'll need to change some u-boot settings so the Debian kernel knows what type of machine it's running on. Note that these changes will apparently stop the HP kernel running!:

setenv mainlineLinux yes
setenv arcNumber 2846
setenv machid b1e

The critical thing seems to be the setenv machid b1e, arcNumber on it's own didn't work for me.

Now grab uImage and uInitrd from here:


and put them on your tftpserver

Now enter at the u-boot prompt: (If you are copying and pasting do it a line at a time):

setenv ipaddr
setenv serverip
tftpboot 0x01100000 uInitrd
tftpboot 0x00800000 uImage
setenv bootargs console=ttyS0,115200n8 base-installer/initramfs-tools/driver-policy=most base-installer/install-recommends=false
bootm 0x00800000 0x01100000

Since we've only got 512Mb of flash to play with we need to minimise the amount of packages we install, the base-installer/install-recommends=false helps with that.

u-boot should load the initrd and kernel and the bootm command should boot the kernel.

Now go through the install as usual, note that the version of u-boot on the t5352 does not appear to support the ext4 file system, I used ext2 instead, you could try a small fat formatted /boot partition instead. I also didn't bother with a swap partition.

Part way through the actual install it will run out of disk space. To fix go down the menu of installer options and choose the one to run a shell, then type:

# chroot /target
# apt-get autoclean
# exit
# exit

and then re-do the software install stage of the installation. There doesn't seem to be a way to tell the installer to not cache packages :(

Once the install is done we need to set some u-boot vairables so the machine will boot the debian kernel, this assumes you have a single parition:

setenv debian 'ide reset;ext2load ide 0:1 0x800000 /boot/uImage;setenv bootargs $(debian_bootargs);bootm 0x800000'
setenv debian_bootargs 'console=ttyS0,115200n8 console=tty0 video=xgifb root=/dev/sda1 rw'
setenv bootcmd 'run debian'

You should be able to boot from power on now.

Note, you need to make these changes from uboot, the fw_printenv command that ships with the Debian u-boot-tools package dosen't appear to be able to work with the uboot on the t5325, maybe it calculates the checksum differently?!?

To free up some more space there's a few things we can do:


DSELECT::Clean "always";
APT::Clean-Installed "true";
Dir::Cache {
     srcpkgcache "";
     pkgcache "";

to /etc/apt/apt.conf.d/99AutomaticClean to keep the package cache clean, then rm /var/cache/apt/*.bin

now install some tools to help us clean up the packages a bit apt-get install localepurge deborphan debfoster, and then run:

# localepurge
# deborphan | xargs apt-get -y remove --purge

If you can live without documentation you can also run:

# rm -rf /usr/share/doc/
# rm -rf /usr/share/doc-base/
# dpkg --purge man-db manpages
# rm -rf /usr/share/man/

No comments yet!

A few years ago I was playing around with the KDE desktop and found the "Virtual Machine" screensaver.

At first I was puzzled by its screen full of apparently random coloured numbers and a letters, but after it was left to run for some time, something weird happened - the random numbers and letters started forming repeating patterns.

After reading the source code I realised that the letters where instructions for a very simple stack based computer, and the numbers were data. The screen represented the memory of the computer, the numbers data, and the letters instructions.

Over a long period of time some of the memory locations would end up containing a self-replicating program, and that program (or programs) would then have many copies of them made and they would slowly take over the screen.

The screensaver wasn't easy to play with so I forgot about it for a while. I've been wanting to refresh my JavaScript skills and learn the canvas API's, so porting kvm.kss to HTML5/JavaScript/canvas was a good way of satisfying both itches.

Instruction set:

Wait - do noting
Pop - discard the top item on the stack
Execute - take the top item from the stack add it to the current location, then carry on executing from the new location.
Stop - stop executing
Copy - take the top 3 items from the stack, the first is the relative address behind the current location to start copying from, the 2nd is the location ahead of the current location to start copying to, and the 3rd is the number of cells to copy.

If the stack has more than 15 items on it, stop running. If the stack is empty when trying to pop a value from it, stop running. Stop executing after 1000 instructions have been run.

When running stops, start running from a random location with an empty stack and the instruction count set to zero.

This machine is similar (identical?) to the 'Core Wars' virtual machine.

Clicky here to see the system running. Code is here

No comments yet!
January 3, 2012 : Doorbot App

London Hackspace has an RFID card entry system that lets people register whatever RFID card they have in order to unlock the door (Since we're in London, most people are using Oyster cards).

Since I got a Galaxy Nexus I've been interested in playing about with it's NFC support, which is a layer on top of the usual RFID stuff.

I've written an Android App that uses your phone to grab the serial from an RFID card and then add it to your Hackspace account. So if you've got a phone that supports NFC you can add your own card your self.

apk here:


and code here:


to use it:

  • install the apk.
  • run the App.
  • wave card at back of phone, observe serial number appear in 'serial' field.
  • enter LHS membership Username and Password in the supplied fields.
  • hit 'Go!'
  • relax and let technology do the rest for you...

I was hoping to be able to generate a random serial number and get the phone to pretend to be a card and use that to activate Doorbot, but I haven't worked out how to yet. (The android SDK really focuses on NFC stuff, not the lower level RFID things, so it might be a bit like trying to spoof a mac address from http).

The Laser cutter we've got at the London Hackspace has very crappy windows software so I've started reversing it.

I've got the usb protocol mostly done, I can upload, list and delete files on the controller, there's a few more commands that can be implemented, but they aren't critical.

I've also (after years of not getting round to it) started using Mercurial and I've setup a repo, which you can find here.

March 16, 2010 : Sticking the knives in

Well how else was i supposed to get it out?

tags: hacks

No comments yet!
September 22, 2009 : maximally (?) compatible ext2fs

I was trying to remember how to make an ext2 fs thats as widely compatible as possible (I.e. with the windows IFS driver, the OS X ext2 driver and NetBSD's ext2 support).

I think it's this:

mke2fs -I 128 -L "1TB backup" -O ^dir_index,^has_journal -v /dev/sd0e

tags: hacks netbsd

No comments yet!
February 16, 2006 : The Airport Mib is broken

Sent in the Airport patch for scli. This prompted a discussion about Apple's broken mib - it uses MAC addresses for the indexes of some of the tables (which is fine), but the mib file uses the PhysAddress type which dosn't specify the length. (and the MIB has a crazy license).

The box sends the table request results back without specifying the length of the MAC addresses. If the mib used the MacAddress type (from SNMPv2-TC) instead of PhysAddress all would be well, cos MacAddress specifys a length.

tags: hacks snmp

No comments yet!

Playing around with adding the apple airport extreme mib to scli. The scli anoncvs server appears to be down, and they don't have cvs snapshots (that i can find) any more. there is a testing/ subdirectory with version 0.3.0 in it, so i'll try that.

hmm, netbsd needs:

#include <net/if.h>
#include <netinet/in.h>

included before:


maybe they should be using net/if_ether.h instead.

ah, the autoconf docs have some stuff to say about net/if.h on Darwin.

after some emails, found that they ditched cvs for svn:


When running aclocal (usually from autogen.sh), pass:

-I /opt/local/share/aclocal -I /usr/share/aclocal -I \



glibtoolize seems to work as libtoolize.

"gmodule" is "gmodule-2.0" (including the library filename) - scli was assuming that gmodule was "gmodule".

tags: hacks snmp

No comments yet!

Valid HTML 4.01! Valid CSS! Flattr this ipv6 ready