New state diagram implemented