Moved handling of heartbeats into its own file in PC.