Hi!! I’m trying to use heart rate sensor to detect heart rate and then change the flow rate of water based on different heart rate. I use a water pump, and here is my circuit:
I think that @d901ia has a human hanging off the heartrate sensor and is trying to control the pump flow by controlling or monitoring the human's pulse.
When A0 is reading 700 or above, PWM signal on pins 3 and 5 (which I guess are your motor drivers - I can't be bothered to try and figure out that spaghetti image) is changed randomly to between 100 and 200 about 9,000 times per second. The PWM rate will average out at 150.
When A0 is below 700, pins 3 and 5 are set to 0, i.e. LOW, i.e. motors off. This is also done about 9,000 times a second.
In both cases pins 2 and 4 are set LOW - again this happens about 9,000 times a second.