Welcome on PLAY Embedded

On PLAY Embedded you can find useful resources to get started with embedded systems: media, examples and accurate descriptions are also provided. Come on, learn by doing!

Wide box Tiny box List
Ascent Descent

Using STM32’s ADC with ChibiOS ADC Driver

A microcontroller is a system which works on bits and bit streams more than analog signals, anyway those signals are still widely used in many fields especially in audio and power applications. An Analog to Digital Converter (or ADC) is a system that converts such kind of signals in a sequence of discrete values directly interpretable by the microcontroller. Such kind of converter is widely used in embedded systems to deal with those peripherals which works with analog signals like potentiometers, analog microphones or sensors.

Some examples?

Analog sensors which continue reading...

ChibiOS/HAL design: an object-oriented approach

The C programming language is clearly an imperative programming language not designed to be object-oriented. Anyway, the object-oriented approach remains something much more related to the design and mindset more than to syntax. The ChibiOS/HAL is an Hardware Abstraction Layer which design could be considered very object-oriented. We encountered it in almost every article related to ChibiOS but we often ignored its design as it comes with a series of demos which allow to use it easily without a deep knowledge of its internal mechanisms.

This article is dedicated to people continue reading...

Using STM32’s USART with ChibiOS Serial Driver

The serial communication in asynchronous mode is one of the simplest and most used method to exchange data between microcontroller and other devices. Such kind of communication can be achieved through a Universal Synchronous/Asynchronous Receiver Transmitter (or USART) as well as UART peripheral which actually is a subset of USART. Each STM32 microcontroller is equipped with multiple instances of these peripherals (from 2 up to 8) depending on the microcontroller model.

In this article we are going to take an overview of serial communication protocols and peripherals continue reading...

Dealing with LEDs using a STM32

This first collection of examples and exercises is focused on LEDs. This article is mainly related to the article about STM32 GPIO peripheral. To understand this article you should be able to create, build and run a custom project for STM32 development board using ChibiOS. In what follows I will not add downloadable projects because putting examples to work is actually part of the exercise.

The following concepts could be easily applied to every STM32 development board. If you have any question ask support commenting this article or subscribing to our forum.

Create a continue reading...

Using STM32’s GPIO with ChibiOS’ PAL Driver

The STM32 is equipped with an extremely flexible General Purpose Input Output (or GPIO) peripheral allowing to configure each Input/Output independently. The IO is the simplest interface between the STM32 and the outside world.

As we said in the article “From 0 to STM32“, there are many versions of the same peripherals across the various STM32’s sub-families and this is way each sub-family usually has its own Reference Manual. In this document it is possible to find all the functional information about GPIO and reading many RM we can notice that GPIO peripheral has three continue reading...