HAL

All MCU vendors will deliver some C code they call “HAL”, while I call that Low Level Drivers (or BSP – Board Support Package) and implement my own HAL (Hardware Abstraction Layer). A proper HAL need to abstract from hardware and secure portability of code. But, most important is that I want to write source code in C++11.

StarUML cost a few bucks, but I like it and it’s the only alternative I have found to do decent UML class diagrams. The class diagrams makes it easier to maintain overview and as such they improve quality of software architecture and documentation + they don’t take much time to draw.

I started learning C back in 1983 and coming from languages like Jovial, Fortran, Basic and Pascal it felt like heaven in comparison. Later in 1994 I learned OMT and C++ that was a good fit and I have been a C++ fan ever since. Yes I use C# and Java as well, but only if I can’t avoid it.

This blog have so far been more about electronics than source code, but I have stated a few times already that this will change. The starting point is 3 libraries that will form the basis of all we do.

The first is HAL – Hardware Abstraction Layer. A library that systematically encapsulate hardware in a functional, abstracted way.

The second library is EFC – Embedded Foundation Classes, a library of tightly written C++ targeting embedded MCU’s. This library was started years ago and have been mentioned before because as soon as I move on functionality I also need building blocks.

I will return to the 3rd library/tool later.

Leave a Reply