First pass at the new fsm form.
Auto-generates minimised logic from the fsm.