Reader small image

You're reading from  Mastering Arduino

Product typeBook
Published inSep 2018
Reading LevelBeginner
PublisherPackt
ISBN-139781788830584
Edition1st Edition
Languages
Tools
Right arrow
Author (1)
Jon Hoffman
Jon Hoffman
author image
Jon Hoffman

Jon Hoffman has over 25 years of experience in the field of information technology. Over these years, Jon has worked in the areas of system administration, network administration, network security, application development, and architecture. Currently, Jon works as a senior software engineer for Syn-Tech Systems. Jon has developed extensively for the iOS platform since 2008. This includes several apps that he has published in the App Store, apps that he has written for third parties, and numerous enterprise applications. He has also developed mobile applications for the Android and Windows platforms. What really drives Jon the challenges that the field of information technology provides and there is nothing more exhilarating to him than overcoming a challenge. Some of Jon's other interests are spending time with his family, robotic projects, and 3D printing. Jon also really enjoys Tae Kwon Do, where he and his oldest daughter Kailey earned their black belts together early in 2014, Kim (his wife) earned her black belt in December 2014, and his youngest daughter Kara is currently working towards her black belt.
Read more about Jon Hoffman

Right arrow

Preface

Mastering Arduino is an all-in-one guide to getting the most out of your Arduino. This practical, no-nonsense guide teaches you all of the electronics and programming skills that you need, to create advanced Arduino projects. This book is packed full of real-world projects for you to practice on, bringing all of the knowledge in the book together and giving you the skills to build your own robot from the examples in this book. The final two chapters discuss wireless technologies and how they can be used in your projects. 

The book begins with the basics of electronics, making sure that you understand components, circuits, and prototyping before moving on. It then performs the same function for code, getting you into the Arduino IDE and showing you how to connect the Arduino to a computer and run simple projects on your Arduino.

Once the basics are out of the way, the next 10 chapters of the book focus on small projects centered around particular components, such as LCD displays, stepper motors, or voice synthesizers. Each of these chapters will get you familiar with the technology involved, how to build with it, how to program it, and how it can be used in your own projects.

Who this book is for

Mastering Arduino is for anybody who wants to experiment with an Arduino board and build simple projects. No prior knowledge is required, as the fundamentals of electronics and coding are covered in this book.

What this book covers

Chapter 1, The Arduino, introduces the reader to the Arduino by giving a brief history of the Arduino and going over the different versions. We also look at the headers and what the different pins are used for.

Chapter 2, Basic Electronics, introduces the reader to the basics of electricity and electronics. We also introduce the reader to basic electronic components and discuss what they can be used for.  

Chapter 3, Circuit Diagrams, introduces the reader to circuits and circuit design. It also introduces the reader to circuit properties such as voltage, current, and resistance and how they affect the circuit. We also introduce the reader to the Fritzing tool that can be used for circuit design.

Chapter 4, Basic Prototyping, introduces the reader to prototyping and shows them how they can create basic prototypes of their projects. We also discuss the tools needed to create prototypes with the Arduino.

Chapter 5, Arduino IDE, introduces the reader to the Arduino IDE and the Arduino Web Editor. We will show the reader how they can use the both the IDE and the Web Editor to program the Arduino.

Chapter 6, Programming Arduino - The Basics, gives the reader an introduction to the language used to program the Arduino and the layout of the files.

Chapter 7, Programming Arduino Beyond the Basics, shows the reader how they can interact with the pin headers of the Arduino. We also go over more advance topics such as structures, unions, and classes.

Chapter 8, Motion Sensor, is the first “project” chapter. We show how to use the HC-SR01 motion sensor with the Arduino. 

Chapter 9, Environment Sensors, helps the reader build a basic weather station using a temperature and humidity sensor and a rain sensor.

Chapter 10, Obstacle Avoidance and Collision Detection, teaches the reader how to use crash sensors, infrared obstacle avoidance sensors, and ultrasonic range finders to sense objects nearby.

Chapter 11, Fun with Lights, teaches the reader how to use the Arduino to control RGB Leds and NeoPixels.

Chapter 12, Fun with Sound, shows how the reader can use piezo buzzers and an 8-ohm speaker with the Arduino tone library to create sounds and music. It also teaches the reader learn how to play RTTTL (Ring Tone Text Transfer Language) ring tones with the Arduino.

Chapter 13, Using LCD Display, teaches the reader how to connect and use the Nokia 5110 LCD display with the Arduino.

Chapter 14, Speech Recognition and Voice Synthesizing, teaches the reader how to use the MOVI speech recognition and voice synthesizing shield to create a voice activated temperature device that will tell them the temperature.

Chapter 15, DC Motors and Motor Controllers, teaches the reader how to use DC motors with the L298 motor controller and L293D h-bridge motor driver.

Chapter 16, Servo Motors, teaches the reader how to use servo motors with an external power supply to create a robotic claw.

Chapter 17, Using a Relay, shows the reader how a relay can be used to allow the Arduino to control an AC powered device.

Chapter 18, Remotely Controlling the Arduino, shows the reader how to use both a RF (radio frequency) and an IR (infrared) remote controls to control the Arduino.

Chapter 19, Creating a Robot, shows the reader how to take the knowledge they gained in previous chapter and use it to design a robot. We do not actually design a robot, we show how the parts can be used so that the reader can design their own creation.

Chapter 20, Bluetooth LE, teaches the reader about Bluetooth LE and how to use the HM-10 Bluetooth LE radio module with the Arduino.

Chapter 21, Bluetooth Classic, teaches the reader about Bluetooth Classic and how to use the HC-05 Bluetooth radio module with the Arduino.

To get the most out of this book

  • This book assumes no previous knowledge of electronics, programming, or the Arduino. Everything that is needed is covered in this book.

Download the example code files

You can download the example code files for this book from your account at www.packt.com. If you purchased this book elsewhere, you can visit www.packt.com/support and register to have the files emailed directly to you.

You can download the code files by following these steps:

  1. Log in or register at www.packt.com.
  2. Select the SUPPORT tab.
  3. Click on Code Downloads & Errata.
  4. Enter the name of the book in the Search box and follow the onscreen instructions.

Once the file is downloaded, please make sure that you unzip or extract the folder using the latest version of:

  • WinRAR/7-Zip for Windows
  • Zipeg/iZip/UnRarX for Mac
  • 7-Zip/PeaZip for Linux

The code bundle for the book is also hosted on GitHub at https://github.com/PacktPublishing/Mastering-ArduinoIn case there's an update to the code, it will be updated on the existing GitHub repository.

We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing/. Check them out!

Download the color images

Conventions used

There are a number of text conventions used throughout this book.

CodeInText: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "Mount the downloaded WebStorm-10*.dmg disk image file as another disk in your system."

A block of code is set as follows:

#define BUTTON_ONE 12
#define LED_ONE 11

void setup() {
  pinMode(BUTTON_ONE, INPUT);
  pinMode(LED_ONE, OUTPUT);
}

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

display.clearDisplay();
display.drawPixel(10, 10, BLACK);
display.display();

Any command-line input or output is written as follows:

at+nameBuddy
at+name?

Bold: Indicates a new term, an important word, or words that you see onscreen. For example, words in menus or dialog boxes appear in the text like this. Here is an example: "Select System info from the Administration panel."

Warnings or important notes appear like this.
Tips and tricks appear like this.

Get in touch

Feedback from our readers is always welcome.

General feedback: Email customercare@packtpub.com and mention the book title in the subject of your message. If you have questions about any aspect of this book, please email us at customercare@packtpub.com.

Errata: Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you have found a mistake in this book, we would be grateful if you would report this to us. Please visit www.packt.com/submit-errata, selecting your book, clicking on the Errata Submission Form link, and entering the details.

Piracy: If you come across any illegal copies of our works in any form on the Internet, we would be grateful if you would provide us with the location address or website name. Please contact us at copyright@packt.com with a link to the material.

If you are interested in becoming an author: If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, please visit authors.packtpub.com.

Reviews

Please leave a review. Once you have read and used this book, why not leave a review on the site that you purchased it from? Potential readers can then see and use your unbiased opinion to make purchase decisions, we at Packt can understand what you think about our products, and our authors can see your feedback on their book. Thank you!

For more information about Packt, please visit packt.com.

lock icon
The rest of the chapter is locked
You have been reading a chapter from
Mastering Arduino
Published in: Sep 2018Publisher: PacktISBN-13: 9781788830584
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime

Author (1)

author image
Jon Hoffman

Jon Hoffman has over 25 years of experience in the field of information technology. Over these years, Jon has worked in the areas of system administration, network administration, network security, application development, and architecture. Currently, Jon works as a senior software engineer for Syn-Tech Systems. Jon has developed extensively for the iOS platform since 2008. This includes several apps that he has published in the App Store, apps that he has written for third parties, and numerous enterprise applications. He has also developed mobile applications for the Android and Windows platforms. What really drives Jon the challenges that the field of information technology provides and there is nothing more exhilarating to him than overcoming a challenge. Some of Jon's other interests are spending time with his family, robotic projects, and 3D printing. Jon also really enjoys Tae Kwon Do, where he and his oldest daughter Kailey earned their black belts together early in 2014, Kim (his wife) earned her black belt in December 2014, and his youngest daughter Kara is currently working towards her black belt.
Read more about Jon Hoffman