start to implement a heartbeat protocol

seems like decent progress, still need to hammer out some things and
test it