waxworlds.org

page feed

Planet

waxworlds.org

1 December, 2012

New root certificate

As planned, the waxworlds.org root certificate was changed today, to avoid it expiring. All service certificates have also been replaced for ones signed by the new root certificate. The new root certificate will expire in 2100, so I shouldn't need to replace it again any time soon.

waxworlds.org

29 November, 2012

Possible service outages

Apologies to anyone having difficulty accessing waxworlds.org services (in particular, jabber and mail). Our service provider has had a routing problem since the early hours of this morning. See their fault status page for more information.

Update: The issue seems to have been fixed. [1pm]

waxworlds.org

25 November, 2012

Remote SMTP authentication fixed

Apologies to account holders trying to send email remotely. SMTP authentication (which has to be over SSL) wasn't working, but it is now.

Quick reminder: less than a week before the waxworlds.org root CA certificate changes.

edam

23 November, 2012

Using an external editor for Arduino development

The Arduino IDE is nice to get beginners started, but you’ll quickly hit its limitations. And if, like me, you found an option in the preferences dialogue that enables an external editor, you’ll have been disappointed to find that it seems only to disable the internal editor!

It is possible to work entirely outside the IDE, with your own editor (like Emacs or Eclipse) and build your projects from the command line (or in another IDE). Here’s one way to do it…

You should make sure that the Arduino IDE is working first. This will ensure the compiler, C-library an Arduino libraries are installed and working correctly and that you can communicate with your Arduino. Then you’ll want to use a Makefile. I’ve spent some time writing one, in collaboration with quite a few other people, an it’s available here. It’s very easy to use, quite fully-featured, and as compatible with the IDE as possible. (Other makefiles also exist, of course.)

OK, so to build your project outside the IDE, you’ll need to do the following:

  1. Download the `arduino.mk` ([from here](http://ed.am/dev/make/arduino-mk)). You should save it somewhere accessible, like in your home directory. I keep mine at `~/src/arduino.mk`.
  2. In your project directory, edit your main file and save it as a `.ino` file, just as you would in the IDE.
  3. Create yourself a `Makefile`, with the following in:

    BOARD = uno
    include ~/src/arduino.mk

    Obviously, you should replace `~/src/arduino.mk` with the location you saved the Aruino makefile. Having saved `Makefile`, you can run `make boards` to see what board names exist. Then, you should set the `BOARD` variable correctly (“uno” may not be correct).

And that’s it!

To build your project, you should only have to type

$ make

To upload it to the Arduino board, go

$ make upload

(If it can’t detect your Arduino by its self, you may need to set the SERIALDEV variable in your Makefile.)

And if you want to use the Serial Monitor from the Arduino IDE without running the IDE, you can achieve this by going

$ make monitor

This actually runs GNU screen. (You’ll need to remember the shortcut keys to kill screen (^a k, by default) so that you can get out of it!)

If something goes wrong or isn’t working, you should have a look at the documentation for arduino.mk.

waxworlds.org

14 November, 2012

CA certificate for waxworlds.org changing on 1st December 2011!

In September next year the root certificate that is used to sign all waxworlds.org certificates will expire. It will have to be replaced (along with all waxworlds.org certificates).

So, on 1st December (a couple of weeks time), I will be changing the root certificate. Or, more accurately, I will be replacing every waxworlds.org certificate with ones that are signed by a new root certificate.

You will need to have the new root certificate installed in your browsers, mail clients and wherever else you want to trust waxworlds.org SSL/TLS certificates. The new certificate is here:

Sorry for the inconvenience.

waxworlds.org

12 November, 2012

Network downtime, oak replaced

The whole of waxworlds.org has been dark since Sunday morning. This was the result of two factors.

  1. Oak failed catastrophically at 7:52am on 11th November.

  2. Since the recent migration (in June), the root nameservers have had the wrong IP address for ns2.waxworlds.org. So in the absence of oak, waxworlds.org wasn't resolving at all.

The DNS issue has been corrected.

Oak is now a brand new machine with a fresh OS install. As a consequence, there may be a few loose ends that aren't set up quite right. In particular, oak handles our mail, DNS, jabber and has web and database servers on it. I would appreciate being told about any issues that anyone notices.

Long live the new oak.

edam

3 September, 2012

How to start an application on a specific workspace

Many X applications allow you to specify geometry, like this:

$ terminator --geometry=200x200+0+0

Which is great. But it doesn’t let you specify what desktop you want the application to open on.

For a while, in GNOME 3, I used the Auto Move Windows extension, which moves all windows of a given application to a particular workspace. The limitation with this approach is that it affects all windows of a given application and can’t be specified per application launch (which is not so useful for, say, terminals!)

So I wrote a script to do what I wanted. You simply pass the script a desktop (which is a zero-based index) and the command to launch. E.g.:

$ start-on-workspace 1 terminator --geometry=200x200+0+0

Here’s the script. It works by launching the process then polling the X-server for any windows that are owned by that process 10 times a second for 10 seconds. If it finds one, it moves it to the specified workspace.

#!/bin/bash

APP=`basename "$0"`

die()
{
    echo $APP: "$@" >&2
    exit 1
}

usage()
{
    echo 'usage: '$APP' WORKSPACE CMD [ARG]...'
    echo
    echo 'WORKSPACE is the zero-based index of the workspace'
    exit 1
}

# check wmctrl is available
[[ -x `which wmctrl` ]] || die "please install wmctrl"

# we should have at least 2 args
[[ -n "$2" ]] || usage

# check workspace
WS=$1
[[ $(( 0 + $WS )) -gt 0 || "$WS" == "0" ]] || usage
shift

# launch program
"$@" &
CPID=$!

# look for the window every 0.1 seconds for 10 seconds
for (( A = 0; A < 100; A++ )); do
    sleep 0.1

    # has child process terminated?
    [[ -d /proc/$CPID ]] || break

    # try to find process's window ID
    WID=`wmctrl -lp | \
        egrep '^0x[0-9a-f]+ +[-0-9]+ +'$CPID' ' | \
        awk '{print $1}'`
    if [[ -n "$WID" ]]; then

        # move the window
        wmctrl -ir $WID -t $WS
        break

    fi
done

# failed?
[[ $A -eq 100 ]] && die "couldn't find application's window..."

waxworlds.org

23 June, 2012

Old-style SSL jabber (XMPP) connections no longer supported

We are no longer accepting SSL connections on port 5223 to the jabber server. Jabber clients must use TLS on the usual jabber port, 5222. So, encryption is still required to connect to the jabber server.

The reason for the change is that port 5223, while commonly used, is not an official jabber port. Since the recent server migration, we're now using DNS SRV records to redirect jabber clients to im.waxworlds.org and no official IANA-assigned service name exists for port 5223.

Sorry for any inconvenience.

waxworlds.org

21 June, 2012

Migration complete

Various services have been migrated to our new server, ash, which is to function primarily as a webserver.

  • Web

    All hosted sites have now been moved to the new server. If there are any remaining problems, please let me know. Where user accounts don't contain an actual website, they have been left on oak and can now be accessed via oak.waxworlds.org (rather than www.waxworlds.org).

  • MySQL

    The MySQL server is running locally on ash, as it did on oak. MySQL is still running on oak, if you need it, however most of the user data has been migrated.

  • DNS

    Ash is now also one of our nameservers.

waxworlds.org

17 June, 2012

Server Migration

Most of our web services are going to be moving to our new web server, ash. There may be disruptions to sites over the coming week, but hopefully they'll be kept to a minimum.

Feel free to get in touch with any questions or to report any unresolved problems.