This completes an enrollment implementation for the upekts driver.
It's based on code from libthinkfinger, but as there seemed to be many
unknown details there, I spent some time analysing the bus messages in
more detail and have effectively rewritten almost all of the borrowed code.
Note that libthinkfinger is GPL licensed, so that reflects on this code too.
At release time I will ask them if they are OK for me to relicense it.
upekts will need to know when the first enrollment stage is attempted for
the first time, so add an __enroll_stage counter which actually indicates
the next stage to enroll. -1 is a special value and it means 0 is next *and*
it is the initial attemt.
Added more debug output to the enroll handler.
Added new fp_enroll_status codes for too short or uncentered scans.
Changed the print_data allocator to consider the device rather than the
driver, this feels more natural. Added missing return value.
Make fp_enroll_status codes start at 1. 0 can now be used as a
special/temporary value by the drivers. Also check that we aren't exceeding
the number of enroll stages.
Also add a missing exit() call to the verify example and update for the
above.