initial commit of some code that mostly does what it says on the box