lots of updates ready for re-write now