How do I get started learning Arduino?

One of the most common questions I get is “How do I get started learning X?” (Where X is a some topic in STEM, most often electronics and programing). In an effort to help as many people as possible, I am writing a handful of articles on the most popular topics. Let’s get started with: Arduino microcontrollers, yay!

So you want to learn Arduino hardware and programming? That’s awesome! Like all things, learning a new skill takes practice. That means the best way to learn something is to do it.

Regardless of what you want to learn, my advice is (almost) always the same: Find a project you are passionate about and build it. 

Whether that means making an automated watering system to keep your plants happy and healthy, or gathering data to monitor air quality, or a gesture controller to play your favorite video game (Minecraft? Minecraft.). Whatever idea is pressing on your mind, the thing that you’ve always wanted to build, or whatever makes you giddy and excited and want to shout from the rooftops: build THAT.

If you close your eyes and listen to yourself, sometimes you very clearly can hear or see that idea. But what if there’s utter silence? Or perhaps even more challenging, too much noise?? What now?!?

Relax. I guarantee that you have plenty of ideas bottled up inside of your brain that will make you truly and ridiculously excited. You just need to spend a little time thinking, maybe writing, and maybe looking around for inspiration.

Why should you find something you’re passionate about?

Because learning new things is HARD. And at some point, you will get stuck. At some point, things will break and/or not work. If you do not care about the project you’re working on, it is easy to give up and walk away forever. But! If you genuinely and deeply and fervently want to bring that project to life, you will push through the frustration (maybe after some time away) and mess and the fixing to, eventually, finish it (or at least get it to a point where you are satisfied).

Caring about a project means you are internally motivated to finish it and that, my dear friends, is the key to learning anything: patience and persistence.

Okay, great! Find a project you are passionate about, and build it! Seems simple, right? Well, yes and no. It’s definitely easier said than done, and the hardest part when you’re a completely beginner is figuring out how to read the foreign languages of computer code, datasheets, electrical schematics, etc. etc. It can be daunting when it feels like you don’t know anything.

Start with a super simple prototype. It does not have to be the final version and it definitely does not need to have every feature or concept you envision. Break down your idea into its most basic part, and work on that. It can be dirty and disorganized and not quite what you want, but get something to work.

Or, find a tutorial that is close to what you’re envisioning and use that as a guide. A tutorial will be immensely helpful when you are first getting started because a (good) tutorial will walk you through all the parts and pieces, background info, and what the code is doing.

Okay, so all this so far has been quite general (although 100% applicable), so I can sense you’re aching for some actual, WHAT-DO-I-DO type ish. Fine, fine, here are a some specific suggestions for getting started learning how to do hardware and software projects with Arduino microcontrollers:

  1. Learn how to read Arduino software code.
    1. Use tutorials! Code written for tutorials (aka educational purposes) will most likely have comments that walk you through what the parts of the code are doing and what you can change.
  2. Learn how to read Arduino error messages.
    1. Inevitably, you will need to know what the errors printed in the text bar at the bottom mean. Look for line numbers as this will give you a clue as to where the error is, and that will (hopefully) help you figure out if it is a syntax error (aka a “spelling” error) or a logic error (aka something is wrong with the structure of your code).
    2. A good way to get started is to copy the error message summary, and paste into a search engine. There are thousands of other folks who have had the same questions as you, so leverage the power of knowledge in the World Wide Web to help!
  3. Learn how to use a breadboard to build circuits.
    1. Breadboards are tools for rapidly building prototypes of circuits. They are incredibly useful and almost essential when building a project that involves more than just a single sensor or output device.
    2. There are lots of guides on how to use breadboards, including this one!
  4. Learn how to read Fritzing schematics and, eventually, electrical schematics.
    1. Once you can read and understand the basics of Arduino coding and use breadboard to build simple circuits, it is super helpful to be able to build circuits using Fritzing schematics. Fortunately, Fritzings are cartoon-y, cute, and quite user friendly, like the picture to the right 🙂
    2. Color coding works as follows:
      1. Red = positive power;
      2. Black = negative power/ground (“gnd”)
      3. Other colors: signal wires
    3. Fritzing schematics are quite popular these days, but you may also run into you’re classic electrical schematic, particularly in books, which has symbols for components instead of pictures. It is a useful skill to be able to read these.
  5. Learn how to read, and use, code libraries.
    1. Whether you’re working in C++, Python, or Wiring (Arduino’s coding language) the secret to programming is knowing what libraries exist and how to use them.
    2. Explore the built in libraries in Arduino (Tools –> Include Library) and find code examples that use those libraries so you can more easily see the syntax and structure of how you use them.
  6. Learn how to gather essential information from datasheets.
    1. Once you’ve got a basic understanding of the software and hardware side, you’re ready to start tackling datasheets! Datasheets are where you’ll find the critical information for using different types of electrical components like sensors and motors.
    2. To be able to read a datasheet, you’ll need to have some background information about electricity, including knowing the basics of voltage, current, resistance, and power. That said, a good way to start to get a feel for this stuff is to start reading them! (you probably have guessed I would say that by now)
    3. You can find datasheets for parts by, quite literally, searching for: “PART NAME datasheet”, where hopefully you replace “PART NAME” with the thing you’re looking for (e.g. “servo motor HS-485HB datasheet”).

If you learn those five things, you will be able to build all sorts of projects with Arduino!

And now that I’ve taken the “hardest teacher ever” approach, I’ll be a little easier on ya. Here is a handy (and useful) tutorial to get started with:

Using Arduino for Citizen Science

Why this one? Because this tutorial teaches you the basics of how to use different types of sensors, both analog and digital. It walks you through writing simple programs, flashing the board, making the hardware connections, reading software code, and includes a range of increasingly more complex projects so that you get practice using the main features of Arduino.

I would highly recommend actually building each of these projects and, instead of copying-and-pasting, actually type in the code. Trust me, semicolons are still the bane of my existence, and the more you practice adding them, the easier your coding life will be 🙂

That’s about it! I know this was a broad overview, but that’s because it’s a broad subject and there is a LOT to learn. But just like everything else, learn it one step at a time, and practice, practice, practice!

 

Still have questions or need more help?

Contact me! If you’re in the Seattle area, I teach workshops and offer private lessons. If you’re beyond my travel zone, I also offer virtual lessons.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.