Catch 2, quick and dirty setting up in Linux

Download Catch 2 Download it from here and decompress it wherever you want. Create a test file Create a folder wherever you want.Inside the folder create a test.cpp file (without the main() function). For example: // test.cpp #define CATCH_CONFIG_MAIN #include "catch2/catch.hpp" int square( int a ) { return a*a; } // more functions to be …

Some ways to make an embedded system safer, (III)

This is the 3rd and final part of this series. Some of the advices in this post are little more complicated than the others that I've presented. But I encourage you to give them a try, you won't regret. Remember why we are here. If you've missed the first two parts, you can reach them …

Some ways to make an embedded system safer in the Covid-19’s times (II).

In the previous post I started a serie of advices about how to make our embedded systems safer and more reliables. In this post we will discuss another 5 hints. 6 Use a watchdog A program might get stuck in a block of instructions for a variety of reasons. Some of them are: Memory gets …

Arduino, FreeRTOS and shared resources

The Arduino’s analog to digital converter is built upon a single ADC module with 6 or more channels (inputs) and only one channel can be active at any given time. When we are programming in a sequential fashion (without an operating system) it’s easy to read from all channels, one after another. However, when we …

Tareas estáticas en FreeRTOS y porqué debemos preferirlas.

Los sistemas de tiempo real no sólo tienen que entregar un resultado correcto, también deben hacerlo a tiempo. Por esta razón deberíamos evitar el uso de la memoria dinámica. Y a pesar de que los expertos en sistemas embebidos (por ejemplo) respaldan esta afirmación la forma tradicional de crear tareas en FreeRTOS (xTaskCreate()) implica indirectamente …

Arduino Day 21/03/20

Arduino Day, CDMX, 21/03/20 Fui invitado a dar una charla en el evento Arduino Day en la CDMX. Tenía dos temas potenciales: Arduino desde la línea de comandos, o Arduino y FreeRTOS. Me decanté por este último. Arduino Arduino no es un sistema embebido de tiempo real; los desarrolladores no pensaron en esto cuando iniciarion …

Static tasks in FreeRTOS

Static tasks in FreeRTOS Before release 9.0 of FreeRTOS all tasks were created using dynamic memory, using one of five memory schemes (aka malloc() versions). However, since release 9.0 the programmer can create tasks in a static manner too. Even better, all mechanisms in FreeRTOS (tasks, timers, semaphores, queues) can be created now in a …