medical device that transmits electrical signals to the heart to ensure that it contracts and pumps blood to the body