Hello. This creation was inspired by the immortal saga of the Jedi.
With it, simply use the "force" that exists within you to have the earbud in your hands.
Step 1: Operation
The operation is very simple:
When approaching the ultrasonic sensor, it will take measurements and see if there's something close. Confirmed the presence of a nearby object, the Arduino sends a command to the servo move the rod and lift the earbud. Wait five seconds and then drops the rod.
Just train a bit to get the hang.
After all, any Jedi has gone through a training. Why would it be different with you?