EmbeddedRelated.com
Memfault Beyond the Launch

Working with Microchip PIC 8-bit GPIO

Luther Stanton

The third in a series of five posts looks at GPIO with PIC 8-bit microcontrollers. After a detailed review of the registers for configuring and managing GPIO on the PIC18F47Q10 processor, a basic application is stood up programming those registers to blink external LEDs at 0.5Hz.


Blinkenlights 2.0

Ido Gendel

Nothing spells old movie computers like a panel of randomly blinking lights, but in fact, these so-called "blinkenlights" can be valuable indicators - especially in embedded systems where the user interface must be minimal, small and cheap. Control of these lights can be achieved using a very simple, real-time interpreted script, and this kind of solution may be extended to other and more complex embedded tasks.


The volatile keyword

Colin Walls

Although the C keyword volatile is very useful in embedded applications, care is needed to use it correctly and vigilance is required to ensure its correct implementation by compilers.


When a Mongoose met a MicroPython

Sergio R Caprile

This is more a framework than an actual application, with it you can integrate MicroPython and Cesanta's Mongoose.
Mongoose runs when called by MicroPython and is able to run Python functions as callbacks for the events you decide in your event handler. The code is completely written in C, except for the example Python callback functions, of course. To try it, you can just build this example on a Linux machine, and, with just a small tweak, you can also run it on any ESP32 board.


Getting Started With CUDA C on an Nvidia Jetson: GPU Architecture

Mohammed Billoo

In the previous blog post (Getting Started With CUDA C on Jetson Nvidia: Hello CUDA World!) I showed how to develop applications targeted at a GPU on a Nvidia Jetson Nano. As we observed in that blog post, performing a calculation on a 1-D array on a GPU had no performance benefit compared to a traditional CPU implementation, even on an array with many elements. In this blog post, we will learn about the GPU architecture to better explain the behavior and to understand the applications where a GPU shines (hint: it has to do with graphics).


Understanding Microchip 8-bit PIC Configuration

Luther Stanton

The second post of a five part series picks up getting started developing with Microchip 8-bit PIC Microcontroller by examining the how and why of processor configuration. Topics discussed include selecting the oscillator to use during processor startup and refining the configuration once the application starts. A walk through of the code generated by the Microchip IDE provides a concrete example of the specific Configuration Word and SFR values needed to configure the project specific clock configuration.


C to C++: Templates and Generics – Supercharging Type Flexibility

Jacob Beningo

"C to C++: Templates and Generics – Supercharging Type Flexibility" illuminates the rigidity of C when managing multiple types and the confusion of code replication or macro complexity. In contrast, C++ offers templates, acting as type-agnostic blueprints for classes and functions, which allows for the creation of versatile and reusable code without redundancy. By using templates, developers can define operations like add once and apply them to any data type, simplifying codebases significantly. Generics further this concept, enabling a single code structure to handle diverse data types efficiently—a boon for embedded systems where operations must be performed on varying data, yet code efficiency is critical due to resource limitations. The blog walks through practical applications, showcasing how templates streamline processes and ensure type safety with static_assert, all while weighing the pros and cons of their use in embedded software, advocating for careful practice to harness their full potential.


Simple C++ State Machine Engine

Massimiliano Pagani

When implementing state machines in your project it is an advantage to rely on a tried and tested state machine engine. This component is reused for every kind of application and helps the developer focus on the domain part of the software. In this article, the design process that turns a custom C++ code into a finite-state machine engine is fully described with motivations and tradeoffs for each iteration.


Memfault Beyond the Launch