Ex-jailbird judge helps prepare new prisoners