Interfacing 2 HC-SR04 to PIC Microcontrollercharmi pabari2017-02-03T13:01:17+00:00 Home › Forums › Microcontrollers › PIC Microcontroller › Interfacing 2 HC-SR04 to PIC Microcontroller Tagged: 16F877A, HC-SR04, PIC, Timer This topic contains 1 reply, has 2 voices, and was last updated by Ligo George 7 months, 2 weeks ago. Log In Register Lost Password Viewing 2 posts - 1 through 2 (of 2 total) Author Posts February 2, 2017 at 7:08 pm #13461 charmi pabariParticipant How can I interface two HC-SR04 ultrasonic distance sensor with PIC 16F877A using a single timer (timer 1) ? February 3, 2017 at 1:06 pm #13467 Ligo GeorgeKeymaster You can do that. Just need to read one by one. See below. Send trigger to first HC-SR04 Start timer Listen for echo. Stop timer once you got the echo Convert timer value to distance (first distance) Send trigger to second HC-SR04 Start timer Listen for echo Stop timer once you got the echo Convert timer value to distance (second distance) So it is easy. A microcontroller can do above steps very fastly, so it will appear to you that both sensors are reading simultaneously. Author Posts Log In Register Lost Password Viewing 2 posts - 1 through 2 (of 2 total) You must be logged in to reply to this topic.