Pacemakers and defibrillators for congestive heart failure