embedded software boot camp

Recent Posts by Category

2016 Survey of Embedded Systems Design Trends
Thursday, January 14th, 2016 by
According to a recent survey, there are “10” types of people in this world: those who understand binary and those who don’t. As you are presumably (by nature of being reading this niche blog) one of the former and also experienced in the art of embedded systems design, won’t you please participate in a quick […]

Most Popular Embedded Gurus Blog Posts of 2015
Thursday, January 14th, 2016 by
Below are the top 10 most read blog posts from the Embedded Gurus in 2015. #1: A Tutorial on Signed and Unsigned Integers #2: Don’t Follow These 5 Dangerous Coding Standard Rules #3: Efficient C Tip #13: Use the Modulus (%) Operator with Caution #4: Embedded C Programming with ARM Cortex-M Video Course #5: A […]

Most Popular Embedded Gurus Blog Posts of 2013
Tuesday, December 17th, 2013 by Michael Barr
Below are the top 10 most read blog posts from the Embedded Gurus in 2013. #1: An Update on Toyota and Unintended Acceleration #2: Efficient C Tip #13: Use the Modulus (%) Operator with Caution #3: A Tutorial on Signed and Unsigned Integers #4: A Tutorial on Lookup Tables in C #5: Embedded C Programming […]

Most Popular Embedded Gurus Blog Posts of 2012
Wednesday, December 26th, 2012 by Michael Barr
Below are the top 10 most read blog posts from the Embedded Gurus in 2012. #1: Efficient C Tip #13: Use the Modulus (%) Operator with Caution #2: A Tutorial on Lookup Tables in C #3: Combining C’s volatile and const Keywords #4: A Tutorial on Signed and Unsigned Integers #5: What Belongs in a […]

Most Popular Embedded Gurus Blog Posts of 2011
Friday, January 6th, 2012 by Michael Barr
Below are the top 10 most read blog posts from the Embedded Gurus in 2011. #1: Efficient C Tip #13: Use the Modulus (%) Operator with Caution #2: A Tutorial on Lookup Tables in C #3: Unintended Acceleration and Other Embedded Software Bugs #4: Don’t Follow These 5 Dangerous Coding Standard Rules #5: Protothreads versus […]

Coding Standards

Apple’s #gotofail SSL Security Bug was Easily Preventable
Barr Code on 3/3/2014 by Michael Barr

If programmers at Apple had simply followed a couple of the rules in the Embedded C Coding Standard, they could have prevented the very serious `Gotofail` SSL bug from entering the iOS and OS X operating systems. Here’s a look at the programming mistakes involved and the easy-to-follow coding standard rules that could have easily […]

Most Popular Embedded Gurus Blog Posts of 2013
Embedded Gurus - Experts on Embedded Software on 12/17/2013 by Michael Barr

Below are the top 10 most read blog posts from the Embedded Gurus in 2013. #1: An Update on Toyota and Unintended Acceleration #2: Efficient C Tip #13: Use the Modulus (%) Operator with Caution #3: A Tutorial on Signed and Unsigned Integers #4: A Tutorial on Lookup Tables in C #5: Embedded C Programming […]

What’s in your main() header?
Stack Overflow on 2/2/2013 by Nigel Jones

One of the consequences of being in the consulting business is that I get to look at a lot of code written by other people. Usually it is necessary for me to get up to speed on the code as quickly as possible, and so to this end, one of the first things I do […]

How to Combine Volatile with Struct
Barr Code on 11/9/2012 by Michael Barr

C’s volatile keyword is a qualifier that can be used to declare a variable in such a way that the compiler will never optimize away any of the reads and writes. Though there are several important types of variables to declare volatile, this obscure keyword is especially valuable when you are interacting with hardware peripheral […]

What does 0x47u mean anyway?
Stack Overflow on 7/21/2012 by Nigel Jones

In the last couple of years I have had a large number of folks end up on this blog as a result of search terms such as “what does 0X47u mean?” In an effort to make their visit more productive, I’ll explain and also offer some thoughts on the topic. Back in the mists of […]

Efficient C/C++

Peak detection of a time series
Stack Overflow on 9/18/2015 by Nigel Jones

I’ve been doing embedded work for so long now that it’s rare that I come across a need that I haven’t run into before. Well, it happened the other day, so I thought I’d share it with you. Here’s the situation. I have a transducer whose role is to determine a binary condition (essentially X […]

Fast, Deterministic, and Portable Counting Leading Zeros
State Space on 9/8/2014 by Miro Samek

Counting leading zeros in an integer number is a critical operation in many DSP algorithms, such as normalization of samples in sound or video processing, as well as in real-time schedulers to quickly find the highest-priority task ready-to-run. In most such algorithms, it is important that the count-leading zeros operation be fast and deterministic. For […]

Are We Shooting Ourselves in the Foot with Stack Overflow?
State Space on 2/17/2014 by Miro Samek

In the latest Lesson #10 of my Embedded C Programming with ARM Cortex-M Video Course I explain what stack overflow is and I show what can transpire deep inside an embedded microcontroller when the stack pointer register (SP) goes out of bounds. You can watch the YouTube video to see the details, but basically when the […]

Most Popular Embedded Gurus Blog Posts of 2013
Embedded Gurus - Experts on Embedded Software on 12/17/2013 by Michael Barr

Below are the top 10 most read blog posts from the Embedded Gurus in 2013. #1: An Update on Toyota and Unintended Acceleration #2: Efficient C Tip #13: Use the Modulus (%) Operator with Caution #3: A Tutorial on Signed and Unsigned Integers #4: A Tutorial on Lookup Tables in C #5: Embedded C Programming […]

Dual Targeting and Agile Prototyping of Embedded Software on Windows
State Space on 4/12/2013 by Miro Samek

When developing embedded code for devices with non-trivial user interfaces, it often pays off to build a prototype (virtual prototype) of the embedded system of a PC. The strategy is called “dual targeting”, because you develop software on one machine (e.g., Windows PC) and run it on a deeply embedded target, as well as on […]

Firmware Bugs

Boeing Dreamliner ‘Bug’
Stack Overflow on 5/1/2015 by Nigel Jones

There’s an all too familiar story in the press today. The headline at the Guardian reads “US aviation authority: Boeing 787 bug could cause ‘loss of control’. As usual with these kinds of stories, it’s light on technical details other than to reveal that the Dreamliner’s generators will fall into a fail safe mode if […]

A Look Back at the Audi 5000 and Unintended Acceleration
Barr Code on 3/14/2014 by Michael Barr

I was in high school in the late 1980’s when NHTSA (pronounced “nit-suh”), Transport Canada, and others studied complaints of unintended acceleration in Audi 5000 vehicles. Looking back on the Audi issues, and in light of my own recent role as an expert investigating complaints of unintended acceleration in Toyota vehicles, there appears to be […]

Lethal Software Defects: Patriot Missile Failure
Barr Code on 3/13/2014 by Michael Barr

During the Gulf War, twenty-eight U.S. soldiers were killed and almost one hundred others were wounded when a nearby Patriot missile defense system failed to properly track a Scud missile launched from Iraq. The cause of the failure was later found to be a programming error in the computer embedded in the Patriot’s weapons control […]

Apple’s #gotofail SSL Security Bug was Easily Preventable
Barr Code on 3/3/2014 by Michael Barr

If programmers at Apple had simply followed a couple of the rules in the Embedded C Coding Standard, they could have prevented the very serious `Gotofail` SSL bug from entering the iOS and OS X operating systems. Here’s a look at the programming mistakes involved and the easy-to-follow coding standard rules that could have easily […]

Are We Shooting Ourselves in the Foot with Stack Overflow?
State Space on 2/17/2014 by Miro Samek

In the latest Lesson #10 of my Embedded C Programming with ARM Cortex-M Video Course I explain what stack overflow is and I show what can transpire deep inside an embedded microcontroller when the stack pointer register (SP) goes out of bounds. You can watch the YouTube video to see the details, but basically when the […]

Low Power Design

Reduce Energy Use via Power Debugging
Embedded Gurus - Experts on Embedded Software on 1/10/2011 by Michael Barr

According a recent study by the European Union, approximately 10% of electricity used in homes and offices is ‘vampire power’. That is to say that even when many products, especially embedded systems, are turned “off” they are still consuming power! The same report puts the total amount of energy wasted in this way, within Europe […]

Tools to help lower power consumption
Stack Overflow on 6/29/2010 by Nigel Jones

Regular readers will know that low power designs are an interest of mine. Indeed one of the very first blog posts I made lamented how difficult it is to ascertain how much energy it takes to perform various tasks typical to an embedded system. Thus it was a pleasant surprise to receive an IAR newsletter […]

Lowering power consumption tip #4 – transmitting serial data
Stack Overflow on 5/20/2010 by Nigel Jones

This is the fourth in a series of tips on lowering power consumption in embedded systems. For this post I thought I’d delve into the common task of transmitting serial data. I compare polling and interrupting and show you how a hybrid approach can sometimes be optimal. Almost every embedded system I have ever worked […]

Lowering power consumption tip #3 – Using Relays
Stack Overflow on 11/2/2009 by Nigel Jones

This is the third in a series of tips on lowering power consumption in embedded systems. Today’s topic concerns relays. It may be just the markets that I operate in, but relays seem to crop up in a very large percentage of the designs that I work on. If this is true for you, then […]

Lowering power consumption tip #2 – modulate LEDs
Stack Overflow on 9/22/2009 by Nigel Jones

This is the second in a series of tips on lowering power consumption in embedded systems. LEDs are found on a huge percentage of embedded systems. Furthermore their current consumption can often be a very large percentage of the overall power budget for a system. As such reducing the power consumption of LEDs can have […]

RTOS Multithreading

Beyond the RTOS: A Better Way to Design Real-Time Embedded Software
State Space on 4/27/2016 by Miro Samek

An RTOS (Real-Time Operating System) is the most universally accepted way of designing and implementing embedded software. It is the most sought after component of any system that outgrows the venerable “superloop”. But it is also the design strategy that implies a certain programming paradigm, which leads to particularly brittle designs that often work only […]

Idling along, (or what to do in the idle task)
Stack Overflow on 4/14/2013 by Nigel Jones

If you are using an RTOS in your latest design then no doubt you have an idle task. (Most of the time, the idle task is explicit and is the user task with the lowest priority; sometimes it’s built into the RTOS). It’s been my experience that the idle task is an interesting beast. On […]

RTOS, TDD and the “O” in the S-O-L-I-D rules
State Space on 6/11/2012 by Miro Samek

In Chapter 11 of the “Test-Driven Development for Embedded C” book, James Grenning discusses the S-O-L-I-D rules for effective software design. These rules have been compiled by Robert C. Martin and are intended to make a software system easier to develop, maintain, and extend over time. The acronym SOLID stands for the following five principles: S: […]

ESD closes shop. What’s next in store for embedded programming?
State Space on 4/29/2012 by Miro Samek

The demise of the ESD Magazine marks the end of an era. In his recent post “Trends in Embedded Software Design“, the magazine insider Michael Barr commemorates this occasion by looking back at the early days and offering a look ahead at the new emerging trends. As we all enjoy predictions, I’d also like to […]

What’s the state of your Cortex?
State Space on 9/26/2011 by Miro Samek

Recently, I’ve been involved in a fascinating bug hunt related to a very peculiar behavior of the ARM Cortex-M3 core. Given the incredible popularity of this core, I thought that digging a little deeper into the mysteries of ARM Cortex could be interesting and informative. First, I need to provide some background. So, the bug […]