With Examples for Arduino UNO, Raspberry Pi Pico and ESP32
Programming small electronic systems has never been more accessible. Tasks that once demanded expensive tools, specialized hardware, and deep electrical engineering expertise can now be tackled with low-cost development boards and approachable software. At the centre of this shift is the Arduino environment, which provides a unified and familiar way to program a wide range of microcontroller platforms—from classic AVR boards like the Arduino UNO to modern ARM-based boards such as the Raspberry Pi Pico, and powerful Wi-Fi-enabled devices like the ESP32.
This book introduces embedded programming through the core idea that defines all microcontrollers: reading inputs, processing information, and controlling outputs in a predictable loop. The Arduino environment abstracts much of the hardware complexity, allowing you to focus on behaviour rather than implementation details. With just a few lines of code, you can blink LEDs, read sensors, control motors, and communicate with other devices.
While the Arduino UNO, Raspberry Pi Pico, and ESP32 boards differ greatly in performance and features, they share the same fundamental building blocks: digital and analog I/O, timers, serial communication, PWM, interrupts, and power management. Learning these concepts within the Arduino framework builds skills that transfer easily across platforms and scale toward more advanced applications.
By exploring multiple boards while maintaining a consistent programming approach, this book helps you progress from simple experiments to confidently produce well-structured designs—showing that embedded development can be both practical and enjoyable.
Programming the Finite State Machine with 8-Bit PICs in Assembly and C
Andrew Pratt provides a detailed introduction to programming PIC microcontrollers, as well as a thorough overview of the Finite State Machine (FSM) approach to programming. Most of the book uses assembly programming, but do not be deterred. The FSM gives a structure to a program, making it easy to plan, write, and modify. The last two chapters introduce programming in C, so you can make a direct comparison between the two techniques. The book references the relevant parts of the Microchip datasheet as familiarity with it is the best way to discover detailed information.
This book is aimed at Microsoft Windows and Linux users. To keep your costs to a minimum and to simplify the toolchain, specific applications are provided as a free download to enable you to use an FTDI serial lead as the programmer. The assembler used is the open-source "gpasm". All programming can be done in a text editor. There are detailed instructions on how to perform the necessary installations on Windows, Linux Debian, and derivatives such as Ubuntu and Fedora. For programming in C, Microchip's XC8 compiler is used from the command line. In addition to the programming applications, two serial read and serial write applications can be used for communicating with the PICs from a computer.
A voltmeter project including practical instructions on building a circuit board from scratch is included. All theory is covered beforehand, including how to do integer arithmetic in assembly.
Two PICs are covered: the PIC12F1822 and the PIC16F1823. Both can run at 32 MHz with an internal oscillator. You do not need to buy a factory-made development board and programmer. With relatively inexpensive parts including a serial lead, microcontroller, a few resistors, and LEDs, you can get started exploring embedded programming.
Links
Updated Programmer
Projects Using Arduino IDE and the LVGL Graphics Library
The ESP32 is probably one of the most popular microcontrollers used by many people, including students, hobbyists, and professional engineers. Its low cost, coupled with rich features makes it a popular device to use in many projects. Recently, a board called the ESP32 Cheap Yellow Display (CYD for short) is available from its manufacturers. The board includes a standard ESP32 microcontroller together with a 320x240 pixel TFT display. Additionally, the board provides several connectors for interfaces such as GPIO, serial port (TX/RX), power and Ground. The inclusion of a TFT display is a real advantage as it enables users to design complex graphics-based projects without resorting to an external LCD or graphics displays.
The book describes the basic hardware of the ESP32 CYD board and provides details of its on-board connectors. Many basic, simple, and intermediate-level projects are given in the book based on the ESP32 CYD, using the highly popular Arduino IDE 2.0 integrated development environment. The use of both the basic graphics functions and the use of the popular LVGL graphics library are discussed in the book and projects are given that use both types of approaches.
All the projects given in the book have been tested and are working. The block diagram, circuit diagram, and the complete program listings and program descriptions of all the projects are given with explanations. Readers can use the LVGL graphics library to design highly popular eye-catching full-color graphics projects using widgets such as buttons, labels, calendars, keypads, keyboards, message boxes, spinboxes, sliders, charts, tables, menus, bars, switches, drop-down lists, animations, and many more widgets.
Using the RFID Starter Kit
An Arduino board has now become ‘the’ basic component in the maker community. No longer is an introduction to the world of microcontrollers the preserve of the expert. When it comes to expanding the capabilities of the basic Arduino board however, the developer is still largely on his own. If you really want to build some innovative projects it’s often necessary to get down to component level. This can present many beginners with major problems. That is exactly where this book begins.
This book explains how a wide variety of practical projects can be built using items supplied in a single kit together with the Arduino board. This kit, called the 'RFID Starter Kit for Arduino' (SKU 17240) is not just limited to RFID applications but contains more than 30 components, devices and modules covering all areas of modern electronics.
In addition to more simple components such as LEDs and resistors there are also complex and sophisticated modules that employ the latest technology such as:
A humidity sensor
A multicolor LED
A large LED matrix with 64 points of light
A 4-character 7-segment LED display
An infra red remote-controller unit
A complete LC-display module
A servo
A stepper motor and controller module
A complete RFID reader module and security tag
On top of that you will get to build precise digital thermometers, hygrometers, exposure meters and various alarm systems. There are also practical devices and applications such as a fully automatic rain sensor, a sound-controlled remote control system, a multifunctional weather station and so much more.
All of the projects described can be built using the components supplied in the Elektor kit.
Open-Source-Code mit Arduino IDE und PlatformIO
Autonomes Fahren: GPS, Accelerometer, Gyroskop
PS3-Controller
Mikrocontroller wie der Arduino und Einplatinenrechner wie der Raspberry Pi haben sich zu beliebten Komponenten entwickelt. Dritter im Bunde ist der ESP32 der Firma Espressif. Mikrocontroller dieser Baureihe zeichnen sich durch eine Vielzahl implementierter Funktionen aus, die bei einem Arduino konventioneller Prägung mit einem Atmel-AVR-Mikrocontroller erst mit weiterer Hardware möglich sind. Prominentes Beispiel sind hier die WiFi- und Bluetooth-Funktionalitäten. Gegenüber einem Raspberry Pi zeichnen sie sich durch einen deutlich geringeren Preis aus.
Allgemeine Informationen für die Realisierung eines Roboterauto-Projekts mit dem ESP32 sind leicht zu finden. Dabei handelt es sich aber oft nur um Ausführungen zu einem Teilaspekt, ohne inhaltliche oder funktionale Abstimmung. So ist nicht nur die Beschaffung der benötigten Informationen mühselig und zeitaufwändig, sie kann auch außerordentlich fehlerträchtig sein.
Ansatzpunkt dieses Buches ist, diese Lücke zu schließen. Es geht auf verschiedene Möglichkeiten eines Chassis ein, vermittelt nötige Kenntnisse und führt schrittweise von einer einfachen Motorsteuerung zu einem komplexen sensor- und sprachgesteuerten Roboterauto. Hacks rund um GPS und eine PlayStation 3 runden die Sache ab.
Inhalt
Bei der Reihenfolge der Kapitel wurde versucht – beginnend bei der Darstellung von grundlegenden Informationen – über die Lösung einfacher Aufgaben zu etwas anspruchsvolleren Techniken zu führen.
Der Mikrocontroller ESP32
Die Software erstellen
Die Stromversorgung
Rund um die Hardware
Das Chassis
Der Gleichstrommotor
Kabellose Steuerung über WiFi
Mit Sensoren Hindernisse erkennen
Eine eigene Roboterauto-App
Servo und Lichtsensor
GPS
Accelerometer / Gyroskop
PS3-Controller
Roboterauto-App
Hinweis zur Software
Die Dateien haben das Suffix (.cpp). Grund ist die Entwicklung mit PlatformIO. Mit Copy & Paste sollten sie auch in der Arduino-IDE verwendet werden können.
Build your own AI microcontroller applications from scratch
The MAX78000FTHR from Maxim Integrated is a small development board based on the MAX78000 MCU. The main usage of this board is in artificial intelligence applications (AI) which generally require large amounts of processing power and memory. It marries an Arm Cortex-M4 processor with a floating-point unit (FPU), convolutional neural network (CNN) accelerator, and RISC-V core into a single device. It is designed for ultra-low power consumption, making it ideal for many portable AI-based applications.
This book is project-based and aims to teach the basic features of the MAX78000FTHR. It demonstrates how it can be used in various classical and AI-based projects. Each project is described in detail and complete program listings are provided. Readers should be able to use the projects as they are, or modify them to suit their applications. This book covers the following features of the MAX78000FTHR microcontroller development board:
Onboard LEDs and buttons
External LEDs and buttons
Using analog-to-digital converters
I²C projects
SPI projects
UART projects
External interrupts and timer interrupts
Using the onboard microphone
Using the onboard camera
Convolutional Neural Network
AVR Architecture and Programming An in-depth look at the 8-bit AVR architecture found in ATtiny and ATmega microcontrollers, mainly from a software and programming point of view. Explore the AVR architecture using C and assembly language in Microchip Studio (formerly Atmel Studio) with ATtiny microcontrollers. Learn the details of how AVR microcontrollers work internally, including the internal registers and memory map of ATtiny devices. Program ATtiny microcontrollers using an Atmel-ICE programmer/debugger, or use a cheap hobby programmer, or even an Arduino Uno as a programmer. Most code examples can be run using the Microchip Studio AVR simulator. Learn to write programs for ATtiny microcontrollers in assembly language. See how assembly language is converted to machine code instructions by the assembler program. Find out how programs written in the C programming language end up as assembly language and finally as machine code instructions. Use the Microchip Studio debugger in combination with a hardware USB programmer/debugger to test assembly and C language programs, or use the Microchip Studio AVR simulator. DIP packaged ATtiny microcontrollers are used in this volume for easy use on electronic breadboards, targeting mainly the ATtiny13(A) and ATtiny25/45/85. Learn about instruction timing and clocks in AVR microcontrollers using ATtiny devices. Be on your way to becoming an AVR expert with advanced debugging and programming skills.
The Elektor Super Servo Tester can control servos and measure servo signals. It can test up to four servo channels at the same time.
The Super Servo Tester comes as a kit. All the parts required to assemble the Super Servo Tester are included in the kit. Assembling the kit requires basic soldering skills. The microcontroller is already programmed.
The Super Servo Tester features two operating modes: Control/Manual and Measure/Inputs.
In Control/Manual mode the Super Servo Tester generates control signals on its outputs for up to four servos or for the flight controller or ESC. The signals are controlled by the four potentiometers.
In Measure/Inputs the Super Servo Tester measures the servo signals connected to its inputs. These signals may come from for instance an ESC, a flight controller, or the receiver or another device. The signals are also routed to the outputs to control the servos or the flight controller or ESC. The results are shown on the display.
Specifications
Operating modes
Control/Manual & Measure/Inputs
Channels
3
Servo signal inputs
4
Servo signal outputs
4
Alarm
Buzzer & LED
Display
0.96' OLED (128 x 32 pixels)
Input voltage on K5
7-12 VDC
Input voltage on K1
5-7.5 VDC
Input current
30 mA (9 VDC on K5, nothing connected to K1 and K2)
Dimensions
113 x 66 x 25 mm
Weight
60 g
Included
Resistors (0.25 W)
R1, R3
1 kΩ, 5%
R2, R4, R5, R6, R7, R9, R10
10 kΩ, 5%
R8
22 Ω, 5%
P1, P2, P3, P4
10 kΩ, lin/B, vertical potentiometer
Capacitors
C1
100 µF 16 V
C2
10 µF 25 V
C3, C4, C7
100 nF
C5, C6
22 pF
Semiconductors
D1
1N5817
D2
LM385Z-2.5
D3
BZX79-C5V1
IC1
7805
IC2
ATmega328P-PU, programmed
LED1
LED, 3 mm, red
T1
2N7000
Miscellaneous
BUZ1
Piezo buzzer with oscillator
K1, K2
2-row, 12-way pinheader, 90°
K5
Barrel jack
K4
1-row, 4-way pin socket
K3
2-row, 6-way boxed pinheader
S1
Slide switch DPDT
S2
Slide switch SPDT
X1
Crystal, 16 MHz
28-way DIP socket for IC2
Elektor PCB
OLED display, 0.96', 128 x 32 pixels, 4-pin I²C interface
Links
Elektor Magazine
Elektor Labs
Architecture, Programming and Applications
The MSP430 is a popular family of microcontrollers from Texas Instruments. In this book we will work with the smallest type, which is the powerful MSP430G2553. We will look at the capabilities of this microcontroller in detail, as it is well-suited for self-made projects because it is available in a P-DIP20 package.
We will take a closer look at the microcontroller and then build, step by step, some interesting applications, including a 'Hello World' blinking LED and a nice clock application, which can calculate the day of the week based on the date.
You also will learn how to create code for the MSP microcontroller in assembler. In addition to that, we will work with the MSP-Arduino IDE, which makes it quite easy to create fast applications without special in-depth knowledge of the microcontrollers.
All the code used in the book is available for download from the Elektor website.
Mehr als 50 Grundlagenprojekte mit MicroPython und dem RP2040-Mikrocontroller
Der Raspberry Pi Pico ist eine leistungsstarke Mikrocontroller-Platine, die speziell für das Physical Computing – also hardwarenahe Anwendungen – entwickelt wurde. Der Raspberry Pi Pico kann so programmiert werden, dass er eine einzelne Aufgabe sehr effizient ausführt und ermöglicht so schnelle Steuerungs- und Überwachungsanwendungen in Echtzeit. Der 'Pico', wie wir ihn nennen, basiert auf dem schnellen, effizienten und kostengünstigen Dual-Core ARM Cortex-M0+ RP2040 Mikrocontroller-Chip, der mit bis zu 133 MHz läuft und über 264 KB SRAM und 2 MB Flash-Speicher verfügt. Neben dem großen Speicher hat der Pico noch weitere attraktive Eigenschaften, darunter eine große Anzahl von GPIO-Pins sowie gängige Schnittstellen wie ADC, SPI, I²C, UART und PWM. Als Krönung bietet der Chip schnelle und genaue Timer, eine Hardware-Debug-Schnittstelle und einen internen Temperatursensor.
Zur Programmierung lassen sich leicht die gängigen Hochsprachen wie MicroPython oder C/C++ verwenden. Dieses Buch ist eine Einführung in die Verwendung des Pico mit der Programmiersprache MicroPython. In allen Projekten wird die Thonny-Entwicklungsumgebung (IDE) eingesetzt. Über 50 Projekte decken folgende Themen ab:
Installation von MicroPython auf dem Raspberry Pi Pico
Timer-Interrupts und externe Interrupts
Projekte mit Analog-Digital-Wandler (ADC)
Verwendung des internen sowie externer Temperatursensoren
Datenlogger
Projekte zur PWM, UART, I²C-Bus und SPI-Bus
Wi-Fi und Bluetooth für die Kommunikation mit Smartphones
Projekte mit dem Digital-Analog-Wandler (DAC)
Alle in diesem Buch vorgestellten Projekte wurden vollständig getestet und sind funktionsfähig. Es werden keine Programmier- oder Elektronikkenntnisse vorausgesetzt, um sie nachzuvollziehen. Für alle beschriebenen Projekte gibt es kurze Beschreibungen, Blockdiagramme, detaillierte Schaltpläne und vollständige MicroPython-Programmlistings. Die Listings sind auch auf der zum Buch gehörenden Elektor-Webseite zu finden.
Wie enigszins bekend is met moderne microprocessor systemen als Arduino, kent ongetwijfeld ook de problemen met dit soort kaarten. Ze zijn te duur om voor elk project een aparte kaart aan te schaffen en zijn bovendien nogal fors van formaat.
Het aardige van de ATtiny is dat de schijn bedriegt. Het lijkt een klein IC met een beperkt toepassingsgebied, maar het heeft een verbazingwekkend scala aan (speelse) mogelijkheden.
Dit boek beschrijft de enorme veelzijdigheid van de ATtiny microcontroller aan de hand van ongeveer vijftig leuke elektronica projecten, speciaal gericht op de beginner. De meeste ontwerpen zijn volledig uitgewerkt, enkele zijn meer als ontwerpidee gepresenteerd. De inhoudsopgave laat zien dat we ons op vele terreinen zullen begeven, van zonnevolger tot helling indicator. Dit boek is beslist geen theorieboek. Het is een boek dat gelezen zal worden met de soldeerbout in de hand.
Voor het programmeren van de ATtiny maken we dankbaar gebruik van een Arduino kaart. Als de Arduino ingesteld word als programmer, kunnen we er de meeste Arduino “sketches” mee overzetten naar de ATtiny. We wensen u veel plezier met het nabouwen van de schakelingen.
Zeitsteuerung, Scheduler, PIO und Zustandsmaschinen
Multitasking ist der Schlüssel zu leistungsfähigen Embedded-Systemen, und zugleich eine der größten Herausforderungen in der Mikrocontroller-Programmierung. Dieses Buch zeigt Ihnen Schritt für Schritt, wie Sie von einem einfachen Ein-Task-Programm zu einem strukturierten, reaktionsfähigen und skalierbaren System gelangen. Dabei steht nicht nur das Wie, sondern vor allem das Warum im Mittelpunkt.
Sie lernen:
warum scheinbare Parallelität entsteht
weshalb blockierende Programme instabil werden
wie Aufgaben effizient und kontrolliert parallel ablaufen
Ausgehend vom klassischen Superloop vermittelt das Buch moderne Multitasking-Strategien – von nicht-blockierender Programmierung und Tick-Systemen bis zu Task-Schedulern, Zustandsmaschinen und ereignisgesteuerten Konzepten.
Der Fokus liegt auf der Praxis: Sensoren, Displays, Kommunikation und reale Anwendungen werden Schritt für Schritt integriert und mit verständlich kommentierten Beispielprogrammen erklärt.
Fortgeschrittene Themen umfassen:
Multicore-Programmierung mit dem Raspberry Pi Pico
asynchrones Programmieren mit uasyncio
RTOS-Grundlagen mit FreeRTOS
die Kombination aus Multicore und RTOS
Dabei werden auch die Grenzen dieser Techniken, insbesondere unter MicroPython, klar aufgezeigt.
Das Buch richtet sich an ambitionierte Einsteiger und fortgeschrittene Entwickler, die Embedded-Systeme fundiert verstehen und robuste, wartbare Multitasking-Anwendungen entwickeln möchten.