Motor Control Projects with Arduino and Raspberry Pi

Page 8

Motor Control - Projects with Arduino & Raspberry Pi Zero W

CHAPTER 2 • SIMPLE DC MOTOR PROJECTS 2.1 Overview In this Chapter, simple DC motor projects are explained. In all the projects in this Chapter a small brushed permanent magnet DC motor will be used with an Arduino UNO development board and also with a Raspberry Pi Zero W development board. Arduino programs will be developed using the Arduino IDE and the Raspberry Pi programs will be developed using Python programming language. The projects will be described wherever possible by giving the following for each project: • Project Title and brief description • Block diagram • Circuit diagrams (both Arduino Uno and Raspberry Pi) • Project construction • Program listings (both Arduino Uno and Raspberry Pi) • Suggestions (where possible) In this Chapter the term microcontroller will be used to refer to the Arduino UNO development board and also to the Raspberry Pi Zero W development board. 2.2 PROJECT 1 – Motor ON/OFF Control This is a very simple project where a small brushed DC motor that can operate with 3 – 6V is connected to the microcontroller through a transistor driver. The motor is turned ON for 10 seconds and then OFF for 5 seconds. This process is repeated forever until stopped manually. The aim of this project is to show how a DC brushed motor can be connected and operated from a microcontroller. 2.2.1 Block Diagram Figure 2.1 shows the block diagram of the project. One of the output ports of the microcontroller is connected to the motor through a transistor driver.

Figure 2.1 Block diagram of the project 2.2.2 Circuit Diagram – Arduino Uno Figure 2.2 shows the circuit diagram for the Arduino Uno. The base of a BC108 type NPN transistor is connected to pin 3 (see Appendix C for Arduino Uno pin diagram) of the Ardui-

● 30

Motor Control Projects UK 171004.indd 30

18-10-17 13:16


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.
Motor Control Projects with Arduino and Raspberry Pi by Elektor - Issuu