Removed dataOffset as not used.
Fleshing out state machine. WIP.