Use heart phases to detect beat timing