A working wos driver.
A bit of refactorising to make writing tests easier.

And chasing down two bugs which cancled each other out and took for ever
to find.