Programming - Send Commands
90
Modero G5 Touch Panels - Configuration and Programming
Button State Commands (Cont.)
^ENC
Set Text Encoding Method
Sets the text encoding method which is used for commands and strings sent from panel to master (the default
is UTF-8).
Syntax:
"'^ENC-<Encoding>'"
Variable:
Encoding:
0: UTF-8 (default)
1: Latin-1 (ISO 8859-1)
Example:
SEND_COMMAND Panel,"'^ENC-1'"
Sets the encoding method used for all strings to the Master to Latin-1.
Note: NetLinx Studio does not support UTF-8 at this time; therefore UTF-8-encoded characters cannot be
copied from TPD5 and pasted in Studio. To use NetLinx Studio to send UTF-8 encoded text, byte values must
be enumerated in the command.
For example, the following command sends a UTF-8 string to the panel, consisting of ASCII, extended ASCII
and Unicode (Chinese) characters:
"'^UTF-3,0,Hello',$C3,$A2,$C3,$A3,$E5,$9C,$B0,$E7,$9B,$A4,$E3,$83,$87"
Also note that in backwards compatibility mode (i.e. when the ^TXT command is sent or when the ^ENC-1
command has been sent), ISO-8859-1 is used for character encoding/decoding, since that is what G4 panels
used. ISO-8859-1 is different from the Windows-1252 character set in that characters in the range 128-159
(decimal) are non-printable control characters.
So in response to a ?TXT query, any characters in that range (assuming the ^ENC-1 was previously sent) will
be returned as AMX Hex quad-encoded values with Custom Event Flag=1, whereas the remainder of the
extended ASCII range (160-255) will be returned as Latin-1-encoded characters with Custom Event Flag=0
(see the
ISO-8859-1 Character Encoding/Decoding table
on page 95):
?JSB
Query Bitmap Justification Command.
Get the current bitmap justification.
Syntax:
"'?JSB-<vt addr range>,<button states range>,[index]'"
Variables:
variable text address range = 1 - 4000.
button states range = 1 - 256 for multi-state buttons (0 = All states, for General buttons 1 = Off state and
2 = On state).
Optional index = 0 - 5 The index of the bitmap to query. If not specified, the first valid bitmap is returned
excluding the chameleon image. The indexes are defined as:
0 - Chameleon Image (if present)
1 - Bitmap 1
2 - Bitmap 2
3 - Bitmap 3
4 - Bitmap 4
5 - Bitmap 5
The response returned is a custom event with the following syntax:
Custom.ID = Button Address Code
Custom.Type = 1005
Custom.Flag = 0
Custom.Value1 = Button state number
Custom.Value2 = Justification value
Note: Refer to the Button State Number Justification Value table on page 95
.
Custom.Value3 = Index of bitmap (0-5)
Custom.Text = String that represents the bitmap justification:
Note: Refer to the Query Bitmap Justification Command table table on page 95.
Summary of Contents for Modero G5
Page 58: ...Settings Menu 48 Modero G5 Touch Panels Configuration and Programming ...
Page 62: ...Gestures 52 Modero G5 Touch Panels Configuration and Programming ...
Page 66: ...MXA MP and MXA MPL Programming 56 Modero G5 Touch Panels Configuration and Programming ...
Page 138: ...Appendix B Bargraph Functions 128 Modero G5 Touch Panels Configuration and Programming ...