Microcontroller Basics

I loved learning about the microcontroller basics when I was studying. It meant I could start taking advantage of microcontrollers in my electronics projects. It kind of felt like with this knowledge, I was unstoppable. I could build ANYTHING!

And it is actually true. Microcontrollers are powerful components. They let you write programs to control your electronics. Combine this knowledge with how to build your own circuit boards, and you’re gonna make amazing things.

By using a microcontroller in your project you will have access to a vast amount of functionality from the tips of your (programming) fingers.

Microcontroller basics example board

Which microcontroller to use?

There are many types of microcontrollers available on the market. Some are easier to use than others.

There are 8-bit, 16-bit and 32-bit microcontrollers available. The simplest microcontrollers are 8-bit. They can do a lot, but they can’t handle operations that needs heavy calculations.

I am not going to list all of them here. But two 8-bit microcontroller families that are easy to use for hobbyists and beginners are AVR and PIC. These are great for learning the microcontroller basics.

AVR is by Atmel and is the microcontroller that I have used the most. It’s really popular among hobbyists. PIC is by Microchip. I have not used PIC, but people say it’s good. It’s also very popular among hobbyists.

There are several types of both PIC and AVR microcontrollers. What sets them apart is the amount of memory, the number of IO pins and the types of peripherals they have. Peripherals are function like Pulse-Width Modulation, Analog-to-Digital conversion, Serial Peripheral Interface, I2C, etc..

If you only want a simple microcontroller to control pins on/off, you don’t have to worry about all the peripherals. Just find one that has enough IO pins and that you are comfortable programming.

For example check out ATtiny2313 for a simple and cheap microcontroller for getting started.

Microcontroller Basics: Using them in projects

There are two ways of using microcontrollers in a project:

  1. Use a microcontroller board
  2. Integrate a microcontroller on your circuit board

This simplest way to get started is to use a microcontroller board.

But it will be both cheaper, more compact and less messy if you integrate a microcontroller to your own board.

Using Microcontroller Boards

Arduino microcontroller board

The most famous microcontroller board is Arduino. It’s a hardware and software suite designed to make it easy to get started with programming microcontrollers. Learn about Arduino programming.

But you can also find other microcontroller boards. They usually have just the microcontroller chip and the necessary components to make it work. This is a great way to test a microcontroller that you haven’t used before.

To get started and learn the microcontroller basics, I would definitely recommend getting an Arduino board. This is the absolute simplest way of getting started. By one together with some basic components, and start experimenting.

Click here to get the Arduino Starter Kit

Using Microcontroller Chips

A microcontroller always has a datasheet where it’s functionality is described. In the datasheet, you will almost always find a reference schematic design for the microcontroller.

This makes it pretty easy to get a microcontroller board up and running.

I have also written a tutorial that teaches you how to build your own microcontroller circuit from scratch. Check out the microcontroller tutorial here.

(Remember to make sure you have a way of programming your microcontroller. This is not always added in the reference diagram)

Schematic with microcontroller

To expand on the microcontroller basics, learn microcontroller programming to learn how to program a microcontroller.

Return from Microcontroller Basics to Electronics Schematics

More Microcontrollers Tutorials

22 thoughts on “Microcontroller Basics”

  1. Oh yeah, microcontrollers are where the real fun begins! I attracted to them during studies (mechatronics) while classes in Arduino programming. Some excersises and turned out it was not enough for me and from that time I love designing electronics and programming chips :) not only as a hobby, but mainly at work. Just regret I found it fascinating so late!

    Cheers,
    Przemek

    Reply
  2. Hello Oyvind, i just read your article thats good information about microcontroller…
    i want make microcontroller to auto watering, i know censor and actuator that i will use but i dont know what chip microncontroller i must use? is that need capacitor, how any resistor that i need? how to draw IC?
    may you give me some resource or link where i can learn deep about microcontroller?
    Thanks
    btw i did not use Arduino….

    Reply

Leave a Comment