Barr Group FacebookBarr Group TwitterBarr Group LinkedInBarr Group Vimeo

Course Overview

Course Length: 
2 Days
CEUs: 
1.5
Format: 
Hands-on/Lecture

When it comes to writing multithreaded code, there is a dangerous mix of vendor propaganda and programmer misunderstanding in the embedded systems design community. Those who sell tools, such as real-time operating systems (RTOSes), too often fail to educate their customers in the subtleties of their proper use. And in an industry dominated by self-taught programmers who were formally educated in electrical engineering, there is typically insufficient knowledge of necessary portions of computer science. This combination reduces product reliability and sometimes also puts human life and limb at risk.

Barr Group's Reliable Multithreaded Programming course is an advanced, efficient, and cost-effective hands-on training program for embedded software architects and developers. In just 2-days and through a mix of lectures and programming exercises on actual embedded hardware, attendees learn how to architect and implement multithreaded software for reliable and safe operation. Back at the office, attendees will be able to immediately put the principles learned in this class to use whether their current architecture is based on cooperative or preemptive multithreading and with any OS from Linux to none-at-all.

Syllabus

The following is a summary of the major course topics and are not the section-by-subsection lecture breakdown.

  • Introduction
    • Types of Threads
    • Reasons to Multithread
    • Reliability/Safety Risks
  • Cooperative Multithreading
    • Syncing main() with ISRs
    • Timing & Cyclic Executives
    • Function Queues
  • Real-Time Operating Systems
    • How Preemption Works
    • Mutual Exclusion
    • Intertask Communication
  • Preventing Starvation and Deadlock
    • Ensuring Deadlines are Met
    • Avoiding Priority Inversion
    • Managing Dynamic Memory
    • Watchdog Supervisor Design
  • Multithreading in Linux
    • Processes vs. Threads
    • Inter-Process Communications
    • Kernel Threads and ISRs
    • Real-Time Linux
  • Pros and Cons of Preemption
    • Top 3 Advantages
    • The 10 Risks/Costs
  • Event-Driven Programming
    • The Event-Reaction Model
    • Managing Event Queues
    • Implementing State Machines
    • Run-to-Completion Steps
    • Cooperating Active Objects
  • Key Takeaways

Audience

  • Embedded software developers
  • Embedded software architects

Prerequisites

Attendees should already be familiar with the C or C++ programming language before taking this course. Prior experience programming for one or more operating systems may be beneficial but is not necessary.

Requirements

Each student will need a computer, such as a laptop, running XP or a newer version of Windows with an available USB port and administrator privileges. (Windows over Mac OS X generally works.)

Exercises

During the course, attendees will independently complete approximately half a dozen hands-on programming exercises. These exercises are interspersed with the lectures. Attendees will use their computer to compile their programs and then download them for execution on an embedded target board with its own processor, memory, and peripherals.

Related Courses

Find out More

To find out more about our upcoming public trainings, go to our Training Calendar.

Contact Us to find out more about this course or to enquire about an on-site training at your company.

Recording Policy

All Barr Group Training Public and On-site courses may not be audiotaped, videotaped or photographed without consent from Barr Group's executive team.  Barr Group reserves the right to record portions or all of a training course for instructional purposes.  As a result, attendees present may also appear on the recording.