Skip to main content

+1 866 653-6233 LinkedIn Software Expert Witness Directory

About Us Contact Us

Barr Group Software Experts

Barr Group Software Experts

Main navigation

  • Expert Services
    • Consulting Experts in Software and Electronics
    • Expert Reports by Testifying Software Experts
    • Reverse Engineering and Forensic Analysis
    • Software Source Code Review and Analysis
  • Areas of Expertise
    • Left Side
      • Artificial Intelligence
      • Automotive Systems
      • Cloud Computing
      • Computer Security
      • Consumer Electronics
      • Electronic Circuits
      • Enterprise Software
      • Financial Technology
      • Firmware and IoT
    • Right Side
      • Industrial Controls
      • Mechanical Design
      • Medical Devices
      • Military & Aerospace
      • Mobile Devices & Apps
      • Optical Equipment
      • Renewable Energy
      • Signal Processing
      • Telecommunications
  • Matters & Venues
    • Patent Infringement and Invalidity Experts
    • Software Copyright and Trade Secrets Experts
    • Product Liability and Failure Analysis Experts
    • Contract Disputes and Software Project Failures
    • Venues and Clients
  • Directory
  • Case Studies
    • DirecTV Anti-Piracy
    • Samsung Software Copyright
    • Toyota Runaway Cars
  • Resources
    • Expert Witness Blog
    • Source Code Review in Litigation
    • Software Source Code Discovery

C

  1. Home
  2. C

C

How-to articles about the C programming language.

U.S. District Court Source Code Review Rules

Posted November 24, 2020

The U.S. District Court of Delaware's "Default Standard for Access to Source Code" follows many but not all recommended best practices for source code discovery.  This month we consider potential areas for improvement in the default rules of this important venue for patent infringement and software copyright litigation.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Embedded Control Systems in Practice

Posted October 31, 2017

An introduction to embedded control systems along with a practical example on the differences between open and closed loop systems.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Prioritize RTOS Tasks (and Why It Matters)

Posted January 18, 2017

This webinar examines best practices for assigning fixed priorities to a set of real-time operating systems (RTOS) tasks and interrupt service routines (ISRs). Viewers will learn how and why to use optimal methods to allow a critical set of tasks and interrupt service routines to meet all of their deadlines – even during transient overload periods. Lessons learned can be applied to the development of any priority-based preemptive RTOS, including real-time Linux.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Get Started with C++ in Embedded Systems

Posted June 07, 2016

C++ compilers are available for most modern embedded processors, yet the adoption rate remains low. Here we provide very practical advice to help you can get started with C++ immediately. The discussion moves quickly from dispelling common C++ myths and identifying key C++ benefits to a set of practical tips and tricks to help you put C++ to the most effective use in your "first month" and "first year."

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Top 10 Causes of Nasty Embedded Software Bugs

Posted May 05, 2016

Too often engineers give up trying to discover the cause of infrequent anomalies--because they can't be easily reproduced in the lab--dismissing them as "user errors" or "glitches." Yet these ghosts in the machine live on. So here's a guide to the most frequent root causes of difficult-to-reproduce firmware bugs.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Top 5 Causes of Nasty Embedded Software Bugs

Posted May 05, 2016

Too often engineers give up trying to discover the cause of infrequent anomalies--because they can't be easily reproduced in the lab--dismissing them as "user errors" or "glitches." Yet these ghosts in the machine live on. So here's a guide to the most frequent root causes of difficult-to-reproduce firmware bugs.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Allocate Dynamic Memory Safely

Posted May 04, 2016

Whether you're using only static memory, a simple stack, or dynamic allocation on a heap, you have to proceed cautiously. Embedded programmers can't afford to ignore the risks inherent in memory utilization.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Avoid Common Firmware Bugs

Posted May 04, 2016

Understanding software and hardware bugs in other embedded systems can help you identify, diagnose, and fix bugs in your own.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

State Machines for Event-Driven Systems

Posted May 04, 2016

State machines are perhaps the most effective method for developing robust event-driven code for embedded systems.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Introduction to Hierarchical State Machines

Posted May 04, 2016

The formalism of Hierarchical State Machines (aka statecharts) makes the state machine approach truly applicable to real-life embedded systems.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Design by Contract for Embedded C

Posted May 04, 2016

What is the Design by Contract programming philosophy, what can it do for you, and why should all embedded software developers care?

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Code a State Machine in C or C++

Posted May 04, 2016

A state machine is any object that behaves different based on its history and current inputs.  Many embedded systems consist of a collection of state machines at various levels of the electronics or software.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Have Polymorphism Without a Heap

Posted May 04, 2016

Rethinking basic programming techniques can avoid many of the problems that heap-based memory management poses for embedded real-time system designs.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Reduce Power Consumption by Writing Better Software

Posted May 04, 2016

The way you write software can affect the power consumption of the resulting product. Here are four approaches to minimizing power consumption through software.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Bug-Killing Coding Standard Rules for Embedded C

Posted May 04, 2016

A C coding standard can help keep bugs out of embedded software by leveraging common language features and development tools.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

More Bug-Killing Coding Standards for Embedded C

Posted May 04, 2016

This second article on enforceable coding standards for embedded systems adds a set of additional bug-killing rules for using certain C keywords and naming global variables.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Prevent Bugs in Embedded Software with TDD

Posted March 01, 2016

It’s a fact: When you create code, you create bugs. Listen in as we present the finer points of Test-Driven Development (TDD) - a game-changing approach to embedded software development that can greatly reduce bugs early in the development process. TDD is not a debugging technique but rather an approach to proactively preventing defects.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Make Embedded Software Smaller and Faster

Posted January 06, 2016

Many embedded systems have reliability, cost, and performance requirements that demand performance be designed into the system, from architecture to algorithms to data structures to coding guidelines.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Find and Fix the Most Common Embedded Software Bugs

Posted September 09, 2015

As if debugging traditional PC/server software or even smartphone apps wasn't hard enough, debugging embedded software adds significant challenges.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Secure Consumable Components of Medical Devices and Other Embedded Systems

Posted September 01, 2015

A number of embedded systems, such as medical devices and printers, feature replaceable components designed to be installed new, consumed through one or more cycles of product use, and ultimately disposed.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Mutexes and Semaphores Demystified

Posted May 13, 2015

What's the difference between a mutex and a semaphore? Misuse of these two distinct types of synchronization primitives can lead to difficult to debug defects with potentially severe consequences in safety-critical devices.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Top 10 Bug-Killing Coding Standard Rules

Posted June 03, 2014

To increase security and keep bugs out of medical devices and other safety-critical embedded systems, add these 10 bug-killing rules to your embedded C coding standard.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Minimize Interrupt Service Routine (ISR) Overhead

Posted January 01, 2007

With all the automation available today, it's easy for programmers to overlook costly overhead introduced into machine code by the compiler. Interrupt handlers are one key area worthy of a closer inspection.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

The Perils of Preemptive Multitasking

Posted January 01, 2006

Every commercial RTOS employs a priority-based preemptive scheduler. This despite the fact that real-time systems vary in their requirements and real-time scheduling doesn't have to be so uniform. Multitasking and meeting deadlines is certainly not a one-size-fits-all problem.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Use C's offsetof() Macro

Posted March 01, 2004

C's offsetof() macro can be a helpful addition to your bag of tricks, including for packing data structures and describing how EEPROM data are stored.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Portable Fixed-Width Integers in C

Posted January 01, 2004

For embedded software developers, the most significant improvements to the C programming language made in the ISO C99 standard update are in the new <stdint.h> header file. Learn the typedef names for the new fixed width integer data types, to make hardware interfacing in C easier. 

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Add-Ons for Graphical User Interfaces (GUIs)

Posted February 01, 2003

Should you integrate a GUI into an embedded system by adding a dedicated processor or upgrading the existing one? Here are some options and trade-offs.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Introduction to Finite Impulse Response Filters for DSP

Posted December 01, 2002

Finite impulse response (FIR) filters are the most popular type of filters implemented in software. This introduction will help you understand them both on a theoretical and a practical level.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Optimal C Constructs for 8051 Microcontrollers

Posted October 01, 2002

The limitations of an 8-bit microcontroller (MCU) can sometimes make conventional C constructs produce suboptimal code. In this article we look at common problems on the 8051 family and discuss workarounds in C.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

MISRA-C Guidelines for Safety Critical Software

Posted July 01, 2002

In 1998, the UK's Motor Industry Software Reliability Association established a set of 127 guidelines for the use of C in safety-critical systems. Here's a look at the rules, what they mean, and how they can work for you.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Use Lint for Static Code Analysis

Posted May 01, 2002

Language specifications, including those for C and C++, are often loosely written. A static analysis tool called lint can help you find dangerous and non-portable constructs in your code before your compiler turns them into run-time bugs.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Detect Memory Leaks

Posted February 01, 2002

Memory leaks can be particularly risky for long-running embedded systems. Here are some tools to identify, track, and analyze memory leaks in embedded C and C++ programs.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How Endianness Works: Big-Endian vs. Little Endian

Posted January 01, 2002

Some human languages are read and written from left to right; others from right to left. A similar issue arises in the field of computers, involving the representation of numbers.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Use C's volatile Keyword

Posted July 01, 2001

The proper use of C's volatile keyword is poorly understood by many programmers. This article will teach you the proper way to do it.

 

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Preserve Non-Volatile Data Across Software Versions

Posted June 01, 2001

The format of non-volatile data may change with a new version of software. Carefully planning data layouts and using data version numbers can make these upgrades easier.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Define Your Own assert() Macro for Embedded Systems

Posted April 01, 2001

Embedded systems programmers often value the assert() macro. This article explores the underlying definition of this handy macro, to show you how to roll your own.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How and When to Use C's assert() Macro

Posted March 01, 2001

The assert() macro is one of those simple tools that would not seem to merit an entire article, but I have come across an alarming number of engineers who have not heard of it or do not use it.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Use Strings to Internationalize C Programs

Posted February 01, 2001

Products destined for use in multiple countries often require user interfaces that support several human languages. Sloppy string management in your programs could result in unintelligible babble.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Implement Internet Protocol (IP) in C

Posted September 01, 2000

The Internet Protocol (IP) is the glue that holds an internet together. Here's a compact implementation of the IP layer for embedded C programmers.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Fast Accurate Memory Test Code in C

Posted July 01, 2000

If ever there was a piece of embedded software ripe for reuse it's the memory test. This article shows how to test for the most common memory problems with a set of three efficient, portable, public-domain memory test functions.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Calibrate Mechanical Inputs in Software

Posted May 01, 2000

Embedded software developers operate in a perfect digital environment but must interact with the imperfect analog real world. To do this it's essential to know how to perform calibration of inputs and sensors.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Implement TCP/IP and UDP/IP for Embedded Systems

Posted April 01, 2000

If your embedded system is on a network, the key question is not will you include TCP/IP but which subset of the Internet Protocol suite will be supported in your product.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Assembly vs. C: Which is Best for Microcontrollers?

Posted March 01, 2000

Given a particular programming problem, what language should you use to realize the solution? Your choice could very well affect the success or failure of the project. So you'd better choose wisely.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

CRC Series, Part 3: CRC Implementation Code in C/C++

Posted January 01, 2000

CRCs are among the best checksums available to detect and/or correct errors in communications transmissions. This article shows how to implement an efficient CRC in C or C++.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Use the C Preprocessor's #error Directive

Posted September 01, 1999

One of the least used but potentially most useful features of the C preprocessor is the ANSI-specified #error directive. Here's a look at a couple of clever uses for #error that have proven invaluable in embedded software development.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

RS-485 Transmit Enable Signal Control

Posted August 01, 1999

Quite a few embedded systems include multiple processors. Sometimes these processors stand in isolation, but more often they're required to communicate over a multidrop bus such as EIA RS-485 or RS-422.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Choose an Embedded C Compiler

Posted May 01, 1999

Let's face it, there's nothing sexy about the topic of cross compilers. Embedded programmers couldn't get the job done without one, but spend very little time thinking about how they work or how they could make our work easier.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

How to Create Jump Tables via Function Pointer Arrays in C and C++

Posted May 01, 1999

Jump tables, also called branch tables, are an efficient means of handling similar events in software. Here's a look at the use of arrays of function pointers in C/C++ as jump tables.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Efficient C Code for 8-bit Microcontrollers

Posted November 01, 1998

The 8051, 68HC11, and Microchip PIC are popular microcontrollers, but they aren't necessarily easy to program. This article shows how the use of ANSI C and compiler-specific constructs can help generate tighter code.

  • Read more
  • Share
  • Facebook
  • Twitter
  • LinkedIn

Request an Expert

(866) 653-6233

Barr Group logo
Call us

Expert Services

  • Source Code Review Services
  • Expert Witness Directory
  • Reverse Engineering Services
  • Expert Reports & Testimony
  • How-To Technical Articles
  • Engineering Services

Latest Insights

  • Payment Processing and e-Payments Fraud
  • Albert Einstein Expert Witness
  • Medical Device Litigation and FDA 510(k)
  • Personality Traits of the Best Expert Witnesses

Website contents copyright © 2012-2025 by Barr Group. | Barr Group's logo is a U.S.-registered ® trademark.

SITEMAP  |  PRIVACY