C Development

C Development is generally done for deeply embedded systems. The reasons for this are:

  • The language representation maps very well onto peripheral hardware control registers.
  • Interrupt handlers are well represented using pointers to functions.
  • Bit manupulations required for control registers are fast and clearly defined.
  • Weak typing so that it is easy to use one type as another to deal with hardware issues.
  • Run time polymorphism via function pointers.
  • ANSI standardization and portability - move it to a processor of your choice.
  • Conditional compilation - an excellent feature for debugging as well as developing product variants.
  • Low level memory access - arrays accessed as pointers plus offset for example.
  • A small set of keywords and relative simplicity.
  • A large number of compound operators for compact code.
  • Elimination of checking for faster performance.
  • Implementation of string manipulation, math functions and I/O as library calls allowing the addition of these.
  • Complex structure support. for C development.

Through years of experience, it is clear that C is the correct mix for implementation of deeply embedded systems.  Add on libraries for embedded operating systems are the norm as are the use of cross development tools to deal with it.

The limitations are mainly related to the lack of language support for abstract data types or object orientation.  Originally C++ was intended to overcome this as was Objective C.  The additional complexity of C++  made it unsuitable for many embedded jobs while Objective C fell by the wayside due to the early popularity of C++.

C Development is here to syay for MCUs, MPUs,  DSCs and DSPs.