Correct roundoff for print register encoding.

Thanks to Pascal Obry for pointing out the problem.