Best of both worlds

Now comes the part where we combine what we have learnt so far in this chapter into one project. We are going use the sensor to calculate the distance between an object and relay this information to be displayed on the LCD screen in real time.

You are going to combine both the circuits from the previous two sections and create something like this:

Best of both worlds

Note that, at the bottom of the setup, you can see two power VCC/5V/red wires merging into one. We did not use a breadboard because we wanted to save space. A simple way to go about this is to use a male splitter. A crude way is to cut a male to male in two and cut one female to female ...

Get Arduino: Building exciting LED based projects and espionage devices now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.