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 [...]
Reduce Energy Use via Power Debugging
Monday, January 10th, 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 [...]
Most Popular Embedded Gurus Blog Posts of 2010
Wednesday, December 29th, 2010 by Michael Barr
Below are the top 10 most read blog posts from the Embedded Gurus in 2010. #1: Take the Mutual Exclusion Challenge (Mutexes vs. Semaphores) #2: Toyota’s Embedded Software Image Problem #3: Setting a Bad Example, Part 1 #4: 3 Things Every Programmer Should Know About RMA #5: A Tutorial on Lookup Tables in C #6: [...]
Top 10 Causes of Nasty Firmware Bugs
Wednesday, December 15th, 2010 by Michael Barr
Finding and killing latent bugs in embedded software is a difficult business. Heroic efforts and expensive tools are often required to trace backward from an observed crash, hang, or other unplanned run-time behavior to the root cause. In the worst case scenario, the root cause damages the code or data in a subtle way such [...]
Most Popular Embedded Gurus Blog Posts of 2009
Monday, November 8th, 2010 by Michael Barr
The top 10 most read blog posts from the Embedded Gurus in 2009.
| Coding Standards |
|
Combining C’s volatile and const Keywords
Barr Code on 1/24/2012 by Michael Barr
Does it ever make sense to declare a variable in C or C++ as both volatile (i.e., “ever-changing”) and const (“read-only”)? If so, why? And how should you combine volatile and const properly? One of the most consistently popular articles on the Netrino website is about C’s volatile keyword. The volatile keyword, like const, is [...]
Most Popular Embedded Gurus Blog Posts of 2011
Embedded Gurus - Experts on Embedded Software on 1/6/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 [...]
Don’t Follow These 5 Dangerous Coding Standard Rules
Barr Code on 8/30/2011 by Michael Barr
Over the summer I happened across a brief blog post by another firmware developer in which he presented ten C coding rules for better embedded C code. I had an immediate strong negative reaction to half of his rules and later came to dislike a few more, so I’m going to describe what I don’t [...]
How to Enforce Coding Standards Using PC-Lint
Barr Code on 6/16/2011 by Michael Barr
In an earlier blog post, I introduced the concept of automatic enforcement of coding standards by stating that: Enforcement of coding standards too often depends on programmers already under deadline pressure to be disciplined while they code and/or to make time to perform peer code reviews. … To ensure your selected coding standard is followed, [...]
Is “(uint16_t) -1″ Portable C Code?
Barr Code on 6/2/2011 by Michael Barr
Twice recently, I’ve run across third-party middleware that included a statement of the form: uint16_t variable = (uint16_t) -1; which I take as the author’s clever way of coding: 0xFFFF I’m not naturally inclined to like the obfuscation, but wondered if “(uint16_t) -1″ is even portable C code? And, supposing it is portable, is there [...]
|
| Efficient C/C++ |
|
Combining C’s volatile and const Keywords
Barr Code on 1/24/2012 by Michael Barr
Does it ever make sense to declare a variable in C or C++ as both volatile (i.e., “ever-changing”) and const (“read-only”)? If so, why? And how should you combine volatile and const properly? One of the most consistently popular articles on the Netrino website is about C’s volatile keyword. The volatile keyword, like const, is [...]
Don’t Follow These 5 Dangerous Coding Standard Rules
Barr Code on 8/30/2011 by Michael Barr
Over the summer I happened across a brief blog post by another firmware developer in which he presented ten C coding rules for better embedded C code. I had an immediate strong negative reaction to half of his rules and later came to dislike a few more, so I’m going to describe what I don’t [...]
Protothreads versus State Machines
State Space on 6/9/2011 by Miro Samek
For a number of years I’ve been getting questions regarding Protothreads and comparisons to state machines. Here is what I think. Protothreads are an attempt to write event-driven code in a sequential way. To do so, protothreads introduce a concept of “blocking abstraction” to event-driven programming–something that event-driven programming is trying to get rid of [...]
Embedded Software Training in a Box
Barr Code on 5/6/2011 by Michael Barr
I am beaming with pride. I think we have finally achieved the holy grail of firmware training: Embedded Software Training in a Box. Priced at just $599, the kit includes Everything-You-Need-to-Know-to-Develop-Quality-Reliable-Firmware-in-C, including software for real-time safety-critical systems such as medical devices. In many ways, this product is the culmination of about the last fifteen years [...]
Efficient C Tip #13 – use the modulus (%) operator with caution
Stack Overflow on 2/8/2011 by Nigel Jones
This is the thirteenth in a series of tips on writing efficient C for embedded systems. As the title suggests, if you are interested in writing efficient C, you need to be cautious about using the modulus operator. Why is this? Well a little thought shows that C = A % B is equivalent to [...]
|
| Firmware Bugs |
|
Building Reliable and Secure Embedded Systems
Barr Code on 3/13/2012 by Michael Barr
In this era of 140 characters or less, it has been well and concisely stated that, “RELIABILITY concerns ACCIDENTAL errors causing failures, whereas SECURITY concerns INTENTIONAL errors causing failures.” In this column I expand on this statement, especially as regards the design of embedded systems and their place in our network-connected and safety-concious modern world. [...]
Combining C’s volatile and const Keywords
Barr Code on 1/24/2012 by Michael Barr
Does it ever make sense to declare a variable in C or C++ as both volatile (i.e., “ever-changing”) and const (“read-only”)? If so, why? And how should you combine volatile and const properly? One of the most consistently popular articles on the Netrino website is about C’s volatile keyword. The volatile keyword, like const, is [...]
Firmware Forensics: Best Practices in Embedded Software Source Code Discovery
Barr Code on 9/27/2011 by Michael Barr
Software has become ubiquitous, embedded as it is into the fabric of our lives in literally billions of new (non-computer) products per year, from microwave ovens to electronic throttle controls. When products controlled by software are the subject of litigation, whether for infringement of intellectual property rights or product liability, it is imperative to analyze [...]
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 [...]
Don’t Follow These 5 Dangerous Coding Standard Rules
Barr Code on 8/30/2011 by Michael Barr
Over the summer I happened across a brief blog post by another firmware developer in which he presented ten C coding rules for better embedded C code. I had an immediate strong negative reaction to half of his rules and later came to dislike a few more, so I’m going to describe what I don’t [...]
|
| 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 |
|
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 [...]
Is an RTOS really the best way to design embedded systems?
State Space on 6/7/2011 by Miro Samek
Recently I’ve been involved in a discussion on the LinkedIn Real-Time Embedded Engineering group, which I started with the question “Is an RTOS really the best way to design embedded systems?”. The discussion, which has swollen to over 0xFF comments by now, has sometimes low signal to noise ratio, but I believe it is still [...]
Embedded Software Training in a Box
Barr Code on 5/6/2011 by Michael Barr
I am beaming with pride. I think we have finally achieved the holy grail of firmware training: Embedded Software Training in a Box. Priced at just $599, the kit includes Everything-You-Need-to-Know-to-Develop-Quality-Reliable-Firmware-in-C, including software for real-time safety-critical systems such as medical devices. In many ways, this product is the culmination of about the last fifteen years [...]
Most Popular Embedded Gurus Blog Posts of 2010
Embedded Gurus - Experts on Embedded Software on 12/29/2010 by Michael Barr
Below are the top 10 most read blog posts from the Embedded Gurus in 2010. #1: Take the Mutual Exclusion Challenge (Mutexes vs. Semaphores) #2: Toyota’s Embedded Software Image Problem #3: Setting a Bad Example, Part 1 #4: 3 Things Every Programmer Should Know About RMA #5: A Tutorial on Lookup Tables in C #6: [...]
|
|