C Programming for Embedded Applications

C Programming for Embedded Applications

English | MP4 | AVC 1280×720 | AAC 48KHz 2ch | 2h 5m | 353 MB

Learn to write embedded software in C and deliver applications that are small, efficient, and fast. In this course, instructor Eduardo Corpeño explains how C programming and the Internet of Things combine in embedded applications—software that permanently resides on a device. He reviews the challenges involved in this type of programming, ranging from memory, storage, and power limitations to hardware awareness. He explains how different data types can affect the performance of your app and reviews bit manipulation—an area where C shines. Eduardo shows how to manipulate bit-level data using bit masking and bit fields, demonstrating the strengths of both techniques with an Arduino controller. Then learn how to use the volatile and const variables to enforce data correctness and read-only access, and explore alternatives to traditional functions, which may take too long to run, and floating-point math, which consumes CPU.

Table of Contents

Introduction
1 Getting started in embedded systems
2 What you should know
3 Using the exercise files

Embedded Systems
4 Applications OS vs. embedded
5 Memory
6 Storage
7 Energy consumption
8 Processing power
9 Hardware awareness
10 C vs. Embedded C

Data Types
11 Integral types
12 Floating-point types
13 A quick analysis of memory usage with Keil
14 Checking memory usage with Arduino

Bit Manipulation
15 Masking
16 Bit masking with Arduino
17 Bit fields
18 A bit field example with Keil

Qualifiers
19 The volatile qualifier
20 The const qualifier
21 Protect variables using volatile
22 Don’t let the optimizer remove your while loop

Function Alternatives
23 Lookup tables
24 Macro functions
25 Inline functions
26 LUT vs. function example in Arduino
27 LUT vs. function example in Keil
28 Inline function example in Keil

Floating-Point Unit Alternatives
29 Software implementation of float
30 Fixed-point math
31 Float-point vs. fixed-point example
32 Float-point unit example in Keil

Conclusion
33 Next steps

Homepage