Motor is an electrical machine we are familiar with, which converts electrical energy into mechanical energy. There is a lot of detail about motor but it is not needed to learn them in deep. Different types of motor and their working concepts we will discuss later with the topic arise.
Here we will learn about simple DC 5V motor and later it’s interfacing with arduino with help of Motor Driver IC L293D.
Circuit below is also the same circuit as we made above but rather than using cell or battery we are using Logic-state, where
- ‘1′ means HIGH that is +5V &
- ‘0’ means LOW that is 0V
Here you can see rotation of motors in clockwise and anti-clockwise direction with respect to supply voltage direction. If you inverse direction of supply voltage (positive and negative) direction of motor rotation also inverses.
H-bridge IC specification and functionality (L293D)
Yes, we can connect motor as same manner we connect led with Arduino in Light up led using arduino (in section how to take output from Arduino) but the problem with motor is, it has coil inside it, and if we energize and de-energize a coil it may cause back EMF which will affect our circuitry at arduino side or microcontroller side circuitry.
To avoid this or we can say to protect our main circuit, we connect an L293D motor driver IC in between Arduino and motor but this IC does not only protect it from back EMF but also helps us to control motor up to 36V (according to datasheet) with a 5V signal from arduino.
In the next section you will learn how to interface L293D IC and how to get input from Arduino or any logic circuit.