Facebook EmaiInACirclel
Embedded/IoT

Embedded C: a language optimised for connected objects

PentaGuy
PentaGuy
Blogger

Although one of the oldest programming languages, C language is still widely used, especially in assembly coded applications, such as the UNIX operating system. C language has directly or indirectly influenced many subsequent programming languages, such as C#, D, Go, Java, JavaScript, Limbo, LPC, Perl, PHP, Python and C shell Unix. Despite their emergence, C remains a highly popular programming language.Embedded C consists of a set of language extensions for the C programming language, approved by the C Standards committee, which wanted to address in this way a series of issues related to attribute sharing among C extensions for different embedded systems.Embedded C uses most of the C language syntax and semantics, i.e. () main function, variable definition, datatype declaration, conditional statements (if, switch.case), loops (while, for), functions, arrays and strings, structures and union, bit operations, macros, unions, etc.For more exotic features such as fixed-point arithmetic, multiple distinct memory banks and basic I/O operations, embedded C programming requires nonstandard extensions to the C language.Despite the fact that embedded C is an extension of the C language, both languages are very much alike, with a few exceptions. In fact, C is generally used for desktop computers, while embedded C is rather integrated for microcontroller based applications. C can use the resources of a desktop PC such as memory, OS, etc., unlike embedded C, which has to use limited resources, such as RAM, ROM, I/Os on an embedded processor. Moreover, embedded C includes extra features over C, such as fixed point types (double, long, float), multiple memory areas, and I/O register mapping (routing). Compilers for C (ANSI C) usually generate OS dependent executables. On the other hand, embedded C requires compilers to create files to be downloaded to the micro-controllers/microprocessors where it needs to run.Although Java is equally used in various embedded systems, Java programs require a Java Virtual Machine (JVM), which consumes a lot of resources. This is why this language is not used for embedded devices with limited resources.Hence, what really changes in embedded C programming is the mindset: embedded applications require an optimal use of resources, efficient program coding and real-time constraint solving while using C basic constructions, syntaxes and feature libraries.In conclusion, embedded C is the perfect tool for implementing different algorithms on micro-controllers in various equipment such as connected objects, state-of-the-art medical electronics, robotics, geolocation, etc.Are you experiencing any embedded development or Proof of Concept (POC) issues for your connected objects? Let’s talk!


Leave a Reply

Your email address will not be published. Required fields are marked *