Input devices

This means sensors, any kind of sensors, I made a ultrasonic distance sensor and and a joy stick.
It is important to say that this devices are sensors because they will tell the micro controller what's going on on the real world. This devices will also let us introduce data to our micro controller. NOTE, this devices will always be written on the code with "INPUT" on the pin declaration.

HC-SR04 Ultrasonic distance sensor

ultrasonic distance sensor

This sensor uses sound and time to measure distances, one of the cylinders (trigger) sends a sound wave, the sound wave travels until it collides with something on it's way, then, the sounds goes back to the second cylinder (echo) and the measurement takes into account the sound speed and the time it took to the sound to travel from the trigger, to the object and back to the echo. So you have to do some maths to get the result in cm, mm, in or ft. So here is the PINOUT:

Pinout

Here is the most relevant information about the dataset:

Parameter Value
Working voltage DC 5V
Working current 15mA
Working frequency 40Hz
Max range 4m
Min range 2cm
Measuring angle 15ยบ
Trigger input signal 10uS TTL pulse
Echo Output signal Input TTL lever signal and the range in proportion
Dimension 45*20*15mm
I took the information from this data sheet where you can also se more
Datasheet