Added constants for each of the scanner's internal states.
Fixes #9.