Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Raspberry Pi Zero W Wireless Projects

You're reading from   Raspberry Pi Zero W Wireless Projects Go mobile with the world's most popular microprocessor

Arrow left icon
Product type Paperback
Published in Aug 2017
Publisher Packt
ISBN-13 9781788290524
Length 240 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Vasilis Tzivaras Vasilis Tzivaras
Author Profile Icon Vasilis Tzivaras
Vasilis Tzivaras
Arrow right icon
View More author details
Toc

Programming the controller

The microcontroller is an Arduino UNO R3 and our Raspberry Pi Zero W. The motors and the distance sensor will be controlled using an Arduino microcontroller. Then the microcontroller will be communicating with the Raspberry Pi Zero W board. Depending on the motor shield you will be using, you may need to change some part of the code but the main idea is the same. As mentioned in the hardware overview section, the motor shield that we will be using requires a specific library. The first thing that we have to do is download the library from Github and save the files in the appropriate folder. You can find the library at the following link:

AFMotor library: https://github.com/adafruit/Adafruit-Motor-Shield-library



After downloading all the necessary files, you need to place them under homefolder | Arduino | libraries and extract the file. Then...

lock icon The rest of the chapter is locked
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.
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 $19.99/month. Cancel anytime
Banner background image