Microcontrollers with little available resources, such as programmemory, RAM and speed, are in most cases programmed in low level languages such as Assembly, C and C++, these languages can be hard to learn for new programmers and therefore hold them away from microcontroller programming. Because high level languages is easier to learn at a basic level, and more and more non-programmers tend to draw against microcontrollers, this thesis presents a high level programming language called ThingML developed at SINTEF. ThingML can generate code for different platforms, both high and low level, and can run on resource constrained devices such as microcontrollers. In order to find out if ThingML is suitable to become a leading microcontroller programming language, it is compared against three other microcontroller programming languages.In order to find areas that the users are not satisfied with in today's microcontroller languages, research have been conducted to find areas of improvement to bring on to ThingML.From the data obtained in this research a suggestion on how to lowercomplexity in state machines, through the use of factorized cross-cutting transitions in general and a implementation in the ThingML language, is presented. The factorized cross-cutting transitions is also compared and evaluated against theoretical state machines, real state machines and a case study is conducted to verify that factorized cross-cutting transitions gives the developers less complexity, better maintainability and overall less code.