Book description
Ultimate guide for programming Arduino with C
Key Features
- Get hands-on experience with the Ardruino board and learn to control it with your programming skills
- Learn the essential concepts of C such as variables, data structures, functions, loops, and pointers
- Work with electronic devices such as LEDs, switches, and motors and connect them to Arduino using C
Book Description
This book will start with the fundamentals of C programming and programming topics, such data types, functions, decision making, program loops, pointers, and structures, with the help of an Arduino board. Then you will get acquainted with Arduino interactions with sensors, LEDs, and autonomous systems and setting up the Arduino environment. Moving on you will also learn how to work on the digital and analog I/O, establish serial communications with autonomous systems, and integrate with electronic devices. By the end of the book, you will be able to make basic projects such as LED cube and smart weather system that leverages C.
What you will learn
- Play with mathematical operations using C
- Use logical operations and loops to play with LEDs and the Arduino board
- Create custom functions using C and connect an SD card to the Arduino
- Use Object-oriented Programming to connect a GSM module to the Arduino board
- Play with an LCD board and Servo using standard Arduino libraries
- Build projects using Arduino such as a LED cube, a smart weather system, and home security
- Identify and fix common errors on an Arduino board
Who this book is for
This book is for hobbyists who have no knowledge about programming and microcontrollers, but are keen to learn C programming using a very affordable hardware device.
Table of contents
-
Learning C for Arduino
- Learning C for Arduino
- Credits
- About the Author
- About the Reviewer
- www.PacktPub.com
- Customer Feedback
- Preface
- 1. Getting Started
- 2. Our First Program!
- 3. Exploring C with Arduino IDE
- 4. Blinking with Operations and Loops
- 5. Functions and Files with Arduino
- 6. Arduino and C++
- 7. Using Pointers and Structure
- 8. Working with Arduino Libraries
- 9. Lets Build Something Awesome
-
10. Few Error Handlings
- Few common errors
- Auto-reset
- Bootloader
- java.lang.StackOverflowError
- Arduino software freeze when I try to upload a program
- Board doesn't turn on (the green power LED doesn't light up)
- Get an error when launching arduino.exe on Windows
- Could not find the main class
- Cygwin conflicts on Windows
- Tools | Serial Port menu is not visible
- Sketch appear to upload successfully but not do anything
- Undeclared functions or undeclared types error
- Invalid device signature when trying to upload a sketch
- 'xxx' does not name a type error
- Library is not Installed properly
- Wrong folder location
- Library dependencies
- Wrong library name
- Wrong folder name
- Forgot to close the Arduino IDE
- Check your hardware connections
- Check the coding syntax error
- Use serial monitor
- Stay connected with the Arduino forum
- Summary
Product information
- Title: Learning C for Arduino
- Author(s):
- Release date: March 2017
- Publisher(s): Packt Publishing
- ISBN: 9781787120099
You might also like
book
Beginning C for Arduino: Learn C Programming for the Arduino, Second Edition
Beginning C for Arduino, Second Edition is written for those who have no prior experience with …
book
C Programming for the PIC Microcontroller: Demystify Coding with Embedded Programming
Go beyond the jigsaw approach of just using blocks of code you don’t understand and become …
book
Programming with STM32: Getting Started with the Nucleo Board and C/C++
Create your own STM32 programs with ease! Get up and running programming the STM32 line of …
book
Arduino Robotics
This book will show you how to use your Arduino to control a variety of different …