send state back and forth