UML Modelling and Codegeneration related discussions » Modelling with UML » Q: Are there UML constructs that should not be used in embedded systems?


Q: Are there UML constructs that should not be used in embedded systems?

3650 Betrachtungen
Seite: 1
Wally
avatar
Community Member
1 Beiträge

Q: Are there UML constructs that should not be used in embedded systems?

The UML was originally created for use in "native" systems.
Are there constructs that can not be used on embedded systems? or constructs that must be used in a specific way?

MichaelKamsties
avatar
Administrator
75 Beiträge

Re: Q: Are there UML constructs that should not be used in embedded systems?

One important thing is, to avoid dynamic allocation. A better way is to use static allocation. To achieve this you should not use "*" associations on Associations for multiplicity. Better is, to use a fixed size of elements. In Rhapsody for example leads this to static allocation if there a linked associations between objects.

See also: How to create static object with multiplicity (a simple example in Rhapsody)

Walter
avatar
Moderator
29 Beiträge

Re: Q: Are there UML constructs that should not be used in embedded systems?

Also important is to avoid too many state-chart constructs like history connectors. This will generate more code.
Also try to let the OO principles do the work for you. Similar Classes can often be mixed if you think about it carefully. An example: I recently saw a model where somebody had 2 classes: com1 and com2. The programmer hadn't realize that com ports are just classes that have run-time objects that must be mapped on physical addresses (volatile) and then the ports are equal. Saved a lot of code.
Another example is a menu system where the progarmmer created a class for every menu item. We rewrote it to a more general "menu" class that was linked to itself and save a massive amount of code. So the advice is: Be aware of the constructs that you use but do not be afraid of them!

Seite: 1

Currently Online:

There is nobody online.

Welcome to our latest member: lammils