This TechTip is about using languages on Weintek HMI. Languages are controlled by a local word, LW9134.
YouTube video of a demo project:
Setting LW 9134 to 0 selects “Language 1“, setting to 1 selects “Language 2“, and so on.
As usual, we’ve included a basic example program using the language setting. We’ll break down some of the key elements in our demo program so you can follow it.
We’re using four languages in our demo, these are English, French, German and Italian. To select these, we’ll set LW 9134 to 0, 1, 2, or 3 respectively. The demo is using a “Set Word” object…
Add further buttons for the other languages setting to 1, 2, 3 respectively.
Using The Label Library
Use different language labels for an object, tick the box “Use label library” (on objects other than a text object, this will appear under the “Label” tab). If the label has been defined, then it can be selected from the “Label tag“, otherwise, it will need to be defined by clicking “Label Library“.
Creating a Label
Give the label a name, or leave as default, choose the number of states, and click OK.
This label is called “Hello”…
We can now add the translations for the label…
A useful tool is the language selection enabling you to preview the layout appearance with different languages. In our example, “Hello”, “Bonjour”, “Hallo”, and “Ciao” are different lengths, so using the L1, L2 etc buttons is a useful tool to check before committing to downloading and adjusting the text size as necessary. If your label is multi-state, such as for a Bit Lamp, Word Lamp or Toggle Switch, it is worth checking the appearance of the different states using S0, S1 etc. for each language.
As usual, we have an example demo program for you to take a look at. This can be downloaded from here.
**Please note the translations used within the demo were Google translations, we would always advise where possible to use professional translations, especially where safety is at stake.