Design Challenge:
When designing an HMI, it may be desirable to create multiple Text I/O objects that all show the same text strings.
Best Practice:
One design approach to achieve matching text strings is to rename the animations on the Text I/O objects such that the animation names are all identical. With this approach, a single call to the altiaSendText API will affect all the Text I/O objects using the same animation names.
When utilizing this approach, it is important to remove the "_integer" and "_float" animations from the affected Text I/O objects. To remove them, delete the animations from the Animation Panel in the Altia Design Editor. This minimizes CPU load when sending text strings to the "_text" animation.
If you do not wish to delete them (for example, because they are actually used), rename the "_integer" and "_float" animations. If there are just two Text I/O objects with the same animation names, rename the "_integer" and "_float" animations for one of the Text I/O objects so they are unique. If there are more than two Text I/O objects with the same "_integer" and "_float" animations, also rename the animations for the additional Text I/O objects.
Rationale:
The "_integer" and "_float" animations are both inputs and outputs.
When used as an input, with the altiaSendEvent API, the animation value will be used to change the display text in the Text I/O object.
The animations are also used as an output when a number string is sent to the "_text" animation with the altiaSendText API. In this case, the text string is converted to a number using atoi() and atof(). The number is routed on the "_integer" and "_float" animations.
When multiple Text I/O objects share animation names, the integer and float outputs from each Text I/O object will also feed the integer and float inputs for the matching Text I/O objects. This causes excessive text processing, including shaping, justification, and draw region calculations.