Closed daidaimar closed 5 years ago
I'm currently away from my office this week, but the dual Pulse Sensor code should work fine with the servo code to control two servos with two Pulse Sensors. When I'm in my office, I can run some tests to find the bug, but often times when you use multiple servos on an Arduino Uno the current draw can make things tweak weirdly. To fix this problem you should use an external power supply for your servos. Here's a couple of examples.
https://www.instructables.com/id/Arduino-How-to-Use-a-Servo-Motor-With-an-External-/ Not sure about the unregulated power supply on that example.
https://captain-slow.dk/2010/10/19/servo-with-external-power/ This one uses an external power supply regulated to 5V. You can also use regulated 5V for the servos, and keep the Uno connected to your computer, while sharing a GND connection between the Uno and the servos.
Hi,
I'm following your Playground source code of "TwoPulseSensors_On_Onearduino" and "PulseSensor_Servo" and trying to create a project by combine the two example into "two pulse Sensor with a Servo" project.
However if I combine the both sample codes, the Arduino seems doesn't work, From my investigation, it appears if I remove the servo.h from header, the code would start working. below code is simply added Servo.h and created a variable in the sample code of "TwoPulseSensors_On_Onearduino", however the code won't work and Arduino would stop after a while. Do you have any idea ?
Env Arduino IDE version 1.8.5. Arduino Uno R3
thanks