Book Image

Arduino Essentials

Book Image

Arduino Essentials

Overview of this book

Table of Contents (17 chapters)
Arduino Essentials
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

DC motor speed control revisited


For the second example of using analog inputs, I have to use a very common electronic component in almost any project: a potentiometer, or simply, a variable resistor, which is a component that by the use of some kind of knob, allows us to change the resistance it offers.

Potentiometers are all around us, from the volume knob on your sound equipment to the temperature regulator of your heating system.

For this project, I'll combine a potentiometer with the motor speed controller we built in Chapter 4, Controlling Outputs Softly with Analog Outputs, in such a way that we can easily change the motor speed by acting on the potentiometer.

The potentiometer

Two typical potentiometers along with their corresponding schematic symbol are shown as follows:

Two typical potentiometers and their schematic symbol

The component itself has three legs. If you measure the resistance between the external two legs, you should get the total resistance of the potentiometer, but if...