Archive for September, 2019

Embedded Programming Video Course Shows How OOP Works Under the Hood

Sunday, September 29th, 2019 Miro Samek

If you’d like to understand how Object-Oriented Programming (OOP) really works under the hood, here is a free video course for you:

OOP part-1: Encapsulation: This first lesson on Object-Oriented Programming (OOP) introduces the concept of Encapsulation, which is the ability to package data and functions together into classes. You’ll see how you can emulate Encapsulation in C, what kind of code is generated, and how to debug such code. Next, you will translate the C design into C++ using a class and again you inspect the generated code to compare it with C. Finally, you will see how Encapsulation relates to concurrent programming with an RTOS.


OOP part-2: Inheritance: This second lesson on Object-Oriented Programming (OOP) introduces the concept of Inheritance, which is a mechanism for reusing common attributes and operations among classes. You’ll see how you can emulate Iheritance in C, what kind of code is generated, and how to debug such code. Next, you will translate the C design into C++ using a class and again you inspect the generated code to compare it with C. Finally, you will see how to *think* about inheritance and not to confuse it with class composition.


OOP part-3: Polymorphism in C++: This third lesson on Object-Oriented Programming (OOP) introduces the concept of Polymorphism, which is a uniquely object-oriented concept that has no direct analog in a traditional procedural language like C. Therefore the plan for this lesson is reversed compared to previous two lessons in that you will first see what poloymorphism is and you will reverse-engineer its inner workins in C++. You will see the benefits of polymorphism and understand its overheads. You will put this knowledge to the test in the next lesson, where you will implement polymorphism in C.