added debug statements temporarily, fixed outbound nextState pointer in Go()
Lots of bug fixes, added rectifyAngle, lots more bug fixes. - bird