Third party cookies may be stored when visiting this site. Please see the cookie information.

Introduction to Arduino

Arduino microcontroller for electronic circuits

Arduino is actually the name of one particular manufacturer and their boards which are based around microcontrollers. These are small computers, but not computers that you can connect up to a mouse and keyboard, these have much less functionality and will run your own code directly on the processor.

They can be used when you want an electronic circuit that needs to make a decision and gives it much more flexibility compared to fixed function electronic components.

Arduino Vs Raspberry Pi

The Arduino and Raspberry Pi are very different devices. There are somethings that the Arduino does well and some that the Raspberry Pi does well. There is also an area of overlap where either could do the same job. So which is best? The video below attempts to answer that.

Beginners tutorial for getting started with the Arduino

I've created the attached video which shows how to get started with the Arduino. This walks you through creating a circuit, setting up the IDE (on a Raspberry Pi), writing your first code and then uploading it to the Arduino. It also includes some hints on debugging and suggestions for dealing with unreliable signals at a certain voltage threshold.

This is based around a simple LDR light sensor circuit which turns a light on when it gets dark. You could create this project using basic electronics, but as explained in the video even basic circuits like this can sometimes benefit from a bit of logic control.

The circuit diagram and Arduino code is included below:

Beginner Arduino circuit breadboard layoutBeginner Arduino circuit schematic diagram

int analogPin = A0;

int digitalPin = 2;

void setup() {

  pinMode (digitalPin, OUTPUT);


void loop() {

  int analogValue;

  analogValue = analogRead(analogPin);

  if (analogValue < 200) {

    digitalWrite(digitalPin, HIGH);


  else {

    digitalWrite(digitalPin, LOW);


  delay (1000);


Arduino Breadboard Workbench holder for 3D printing.

Arduino or Raspberry Pi 7-Segment Display Circuits using Shift Registers

In the video on Shift Registers I have shown a LED 7-Segment counter. Unlike the other videos in this series this one actual shows a working digital circuit creating a numeric display which can connect to the Raspberry Pi and the Arduino. This project is complete with circuit diagrams for the Raspberry Pi and Arduino along with the source code.

Learn Electronics with Raspberry Pi

Coming later in 2020 - the second edition of my book "Learn Electronics with Raspberry Pi" now adds a section on Digital Electronics which compliments this page this with more details about driving digital electronic circuits using a Raspberry Pi.

To be notified about future videos
Subscribe to the PenguinTutor YouTube Channel

Previous Digital electronics
Digital electronics
Next Getting started with the Arduino
Getting started with the Arduino