state.go bugifx
start modularizing: clock.c