Implement state_client in python

to be used by gui, etc...