Wrap up 5.2 exercise, add reusable debug to see process loop state