We can find distance between two points or objects by using two sensor (time of flight sensor and rotatory encoder). By using this the range of the room or dimension of the chair or some other path can be measured by using laser and rotation of a wheel which makes easy to measure. Both the laser module(time of flight) and rotatory encoder are in the same gadget and we can switch between them by using switch. Steps to build this project is coming as follows,
Step 1: Connect LCD SDA SCL TO A4 AND A5 of Nano.
Step 2: Connect laser sensor SDA and SCL to A4 and A5 of arduino.
Step 3: Connect rotatory encoder of Step and clock to D6 and D7 of Arduino nano.
Step 4: Connect 5 volt power supply to all VCC and Ground(gnd) of components and Arduino nano.
Step 5: Connect RGB LED to arduino nano for mode change indicator.
Schematic
PCB
3D Model
Enclosure Box
we use 3D design to do a box-like structure that will hold all these components after connection and make it essential to use. It is optional because even without it the project is meant to be completed because we can measure the distance between two points or object accurately.