EmbeddedRelated.com
The 2024 Embedded Online Conference

Already 3000+ Attendees Registered for the Upcoming Embedded Online Conference

Stephane Boucher February 14, 2020

Chances are you already know, through the newsletter or banners on the Related sites, about the upcoming Embedded Online Conference.

Chances are you also already know that you have until the end of the month of February to register for free. 

And chances are that you are one of the more than 3000 pro-active engineers who have already registered.

But If you are like me and have a tendency to do tomorrow what can be done today, maybe you haven't registered yet.  You may...


Racing to Sleep

Jason Sachs December 30, 2019

Today we’re going to talk about low-power design.

Suppose I’m an electrical engineer working with wildlife biologists who are gathering field data on the Saskatchewan ringed-neck mountain goat. My team has designed a device called the BigBrotherBear 2000 (BBB2000) with a trip cable and a motor and a camera and a temperature sensor and a hot-wire anemometer and a real-time clock and an SD card and a battery and a LoRa transceiver. The idea is something like...


Jaywalking Around the Compiler

Jason Sachs December 9, 20193 comments

Our team had another code review recently. I looked at one of the files, and bolted upright in horror when I saw a function that looked sort of like this:

void some_function(SOMEDATA_T *psomedata) { asm volatile("push CORCON"); CORCON = 0x00E2; do_some_other_stuff(psomedata); asm volatile("pop CORCON"); }

There is a serious bug here — do you see what it is?


Shibboleths: The Perils of Voiceless Sibilant Fricatives, Idiot Lights, and Other Binary-Outcome Tests

Jason Sachs September 29, 2019

AS-SALT, JORDAN — Dr. Reza Al-Faisal once had a job offer from Google to work on cutting-edge voice recognition projects. He turned it down. The 37-year-old Stanford-trained professor of engineering at Al-Balqa’ Applied University now leads a small cadre of graduate students in a government-sponsored program to keep Jordanian society secure from what has now become an overwhelming influx of refugees from the Palestinian-controlled West Bank. “Sometimes they visit relatives...


Embedded Programming Video Course Shows How OOP Works Under the Hood

Miro Samek September 29, 2019

If you'd like to understand how Object-Oriented Programming (OOP) really works under the hood, here is a free video course for you:

OOP part-1: Encapsulation: This first lesson on Object-Oriented Programming (OOP) introduces the concept of Encapsulation, which is the ability to package data and functions together into classes. You'll see how you can emulate Encapsulation in C, what kind of code is generated, and how to debug such code. Next, you will translate the C design into C++ using...


Round-robin or RTOS for my embedded system

Manuel Herrera June 9, 20198 comments

First of all, I would like to introduce myself. I am Manuel Herrera. I am starting to write blogs about the situations that I have faced over the years of my career and discussed with colleagues.

To begin, I would like to open a conversation with a dilemma that is present when starting a project ... must I use or not any operating system?

I hope it helps you to form your own criteria and above all that you enjoy it.

Does my embedded system need an...


Watchdog Timer Anti-patterns

Alexandru Lazar June 8, 2019

The humble watchdog timer has been an essential part of our reliability tool chest for decades now. The way it works is straightforward and easy to understand, and most practical designs are easy to interface with.

There is a wealth of reference material that covers both the theory behind watchdog timers and practical design tips. But what we'll talk about today is of a slightly different nature.

Despite its straightforward operation and long history, the watchdog timer does occasionally get...


Mutex vs. Semaphores – Part 2: The Mutex & Mutual Exclusion Problems

Niall Cooling May 15, 20197 comments

Part 1 of this series we looked at the history of the binary and counting semaphore, and then went on to discuss some of the associated problem areas. In this posting I aim to show how a different RTOS construct, the mutex, may overcome some, if not all, of these weaknesses.

To address the problems associated with semaphore, a new concept was developed during the late 1980’s. I have struggled to find it’s first clear definition, but the major use of the term mutex (another...


Designing Communication Protocols, Practical Aspects

Fotis Chatzinikolaou May 14, 20192 comments

For most embedded developers always comes the time when they have to make their embedded MCU talk to another system. That other system will be a PC or a different embedded system or a smartphone etc. For the purpose of this article I am assuming that we are in the control of the protocol between the two ends and we don’t have to follow something that is already in place on one side.

So let’s say that we have our embedded MCU, we have implemented and configured the USB stack (or just...


C to C++: Bridging the Gap from C Structures to Classes

Jacob Beningo May 23, 20238 comments

In our last post, C to C++: Proven Techniques for Embedded Systems Transformation, we started to discuss the different ways that C++ can be used to write embedded software. You saw that there is no reason to be overwhelmed by trying to adopt complex topics like metaprogramming out of the gate. An important concept to understand is that you can make the transition gradually into C++ while still receiving the many benefits that C++ has to offer.

One of the first concepts that a C...


The Other Kind of Bypass Capacitor

Jason Sachs January 3, 20173 comments

There’s a type of bypass capacitor I’d like to talk about today.

It’s not the usual power supply bypass capacitor, aka decoupling capacitor, which is used to provide local charge storage to an integrated circuit, so that the high-frequency supply currents to the IC can bypass (hence the name) all the series resistance and inductance from the power supply. This reduces the noise on a DC voltage supply. I’ve...


Jaywalking Around the Compiler

Jason Sachs December 9, 20193 comments

Our team had another code review recently. I looked at one of the files, and bolted upright in horror when I saw a function that looked sort of like this:

void some_function(SOMEDATA_T *psomedata) { asm volatile("push CORCON"); CORCON = 0x00E2; do_some_other_stuff(psomedata); asm volatile("pop CORCON"); }

There is a serious bug here — do you see what it is?


How to make a heap profiler

Yossi Kreinin May 23, 20141 comment

We'll see how to make a heap profiler. Example code for this post makes up heapprof, a working 250-line heap profiler for programs using malloc/free.

It works out of the box on Linux (tested on "real" programs like gdb and python). The main point though is being easy to port and modify to suit your needs. The code, build and test scripts are at github.

Why roll your own heap profiler?

  • It's easy! And fun, if you're that sort of person. What, not reasons enough? OK, how...

Stairway to Thévenin

Jason Sachs December 31, 2011

This article was inspired by a recent post on reddit asking for help on Thévenin and Norton equivalent circuits.

(With apologies to Mr. Thévenin, the rest of the e's that follow will remain unaccented.)

I still remember my introductory circuits class on the subject, roughly as follows:

(NOTE: Do not get scared of what you see in the rest of this section. We're going to point out the traditional approach for teaching linear equivalent circuits first. If you have...


Tolerance Analysis

Jason Sachs May 31, 2020

Today we’re going to talk about tolerance analysis. This is a topic that I have danced around in several previous articles, but never really touched upon in its own right. The closest I’ve come is Margin Call, where I discussed several different techniques of determining design margin, and ran through some calculations to justify that it was safe to allow a certain amount of current through an IRFP260N MOSFET.

Tolerance analysis...


Metal detection: beat frequency oscillator

Fabien Le Mentec January 30, 20161 comment
Plan Introduction Theory Electronics Software Tests ReferencesNext part: building the detector 1. Introduction

This article discusses the implementation of a beat frequency oscillator (BFO) stage for metal detector. While they are mentioned here and there, the article does not detail other important electronic stages such as the power supply, and user interface, the coil or the detector frame. I may write other articles on these topics, and other detection methods.Before...


Little to no benefit from C based HLS

Christopher Felton April 4, 2014

Last updated 07-Nov-2015

As I write this I am on a plane and my destination is EELive 2014 where I am going to give a talk hardware design: the grunge era.  It is a shotgun introduction to three alternative hardware description languages (alt.hdl). The three languages briefly introduced in the talk are: bsv, chisel, and myhdl.  The goal of the talk is simply to raise awareness of the three...


A wireless door monitor based on the BANO framework

Fabien Le Mentec June 10, 20145 comments
Introduction

I have been thinking for a while about a system to monitor the states of my flat and my garage doors from a remote place. Functionnaly, I wanted to monitor the state of my doors from a remote place. A typical situation is when I leave for holidays, but it can also be useful from the work office. To do so, I would centralize the information on a server connected on the Internet that I could query using a web browser. The server itself would be located in the appartement, where...


The 2024 Embedded Online Conference