STM32Java UI Extension STM32JavaF4 - Keil uVision Reference Manual

STM32Java
UI Extension
STM32JavaF4 - Keil uVision
Reference Manual
Reference:
Revision:
Architecture:
Compiler:
Product Version:
TLT-0613-REF-STM32JavaF4
C
STM32JavaF4
Keil uVision
4.0.3
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Confidentiality & Intellectual Property
All right reserved. Information, technical data and tutorials contained in this document are
confidential, secret and IS2T S.A. Proprietary under Copyright Law. Without any written permission
from IS2T S.A., copying or sending parts of the document or the entire document by any means to
third parties is not permitted including but not limited to electronic communication, photocopies,
mechanical reproduction systems. Granted authorizations for using parts of the document or the entire
document do not mean they give public full access rights.
IceTea®, IS2T®, MicroJvm®, MicroEJ®, S3™, SNI™, SOAR®, Drag Emb'Drop™, IceOS®,
Shielded Plug™ and all associated logos are trademarks or registered trademarks of IS2T S.A. in
France, Europe, United States or others Countries.
Java™ is Sun Microsystems' trademark for a technology for developing application software and
deploying it in crossplatform, networked environments. When it is used in this documentation without
adding the ™ symbol, it includes implementations of the technology by companies other than Sun.
Java™, all Java-based marks and all related logos are trademarks or registered trademarks of Sun
Microsystems Inc, in the United States and other Countries.
Other trademarks are proprietary of their authors.
2
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Table of Contents
1. Bibliography ........................................................................................................................... 5
2. Introduction ............................................................................................................................ 6
2.1. Scope .......................................................................................................................... 6
2.2. Intended Audience ....................................................................................................... 6
2.3. Related Documents ...................................................................................................... 6
3. Edition – Name – Version ...................................................................................................... 7
4. Features .................................................................................................................................. 8
4.1. Required Resources ...................................................................................................... 8
4.2. Standard Libraries ........................................................................................................ 8
4.3. Domain Specific Libraries & API ................................................................................. 8
5. MicroUI ................................................................................................................................. 9
5.1. Java properties ............................................................................................................. 9
5.2. Error Messages ............................................................................................................ 9
5.3. Configuration ............................................................................................................. 10
6. Inputs ................................................................................................................................... 11
6.1. Low Level API: LLINPUT ......................................................................................... 11
6.2. Java Event Generators ................................................................................................ 12
6.3. MicroUI Initialization ................................................................................................. 12
6.4. Configuration ............................................................................................................. 15
7. Display ................................................................................................................................. 16
7.1. Low Level API: LLDISPLAY .................................................................................... 16
7.2. MicroUI Initialization ................................................................................................. 18
8. Image Generator ................................................................................................................... 20
8.1. Configuration File ...................................................................................................... 20
8.2. Error Messages .......................................................................................................... 20
9. Font Generator ...................................................................................................................... 21
9.1. Configuration File ...................................................................................................... 21
9.2. Custom Range ............................................................................................................ 21
9.3. Known Range ............................................................................................................ 21
9.4. Error Messages .......................................................................................................... 28
10. LEDs .................................................................................................................................. 29
10.1. Low Level API: LLLEDS ......................................................................................... 29
11. MWT Implementation ......................................................................................................... 30
11.1. Error Messages ......................................................................................................... 30
12. Front Panel ......................................................................................................................... 31
12.1. FP File ..................................................................................................................... 31
13. Document History ............................................................................................................... 34
3
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
List of Figures
6.1. Event Generators Description .............................................................................................. 13
8.1. Images Static Configuration File Grammar .......................................................................... 20
9.1. Fonts Configuration File Grammar ...................................................................................... 21
List of Tables
3.1. Pack references .................................................................................................................... 7
4.1. Required resources ............................................................................................................... 8
4.2. Standard libraries ................................................................................................................. 8
4.3. Specific libraries .................................................................................................................. 8
5.1. MicroUI Java properties ....................................................................................................... 9
5.2. MicroUI error messages ....................................................................................................... 9
5.3. MicroUI configuration variables .......................................................................................... 10
6.1. LLINPUT API for predefined event generators .................................................................... 11
6.2. Event Generators Static Definition ...................................................................................... 13
6.3. LLINPUT configuration variables ....................................................................................... 15
7.1. Display Static Initialization XML tags definition ................................................................. 18
8.1. Static image generator error messages ................................................................................. 20
9.1. Ranges ............................................................................................................................... 21
9.2. Static Font Generator error messages .................................................................................. 28
11.1. MWT error messages ....................................................................................................... 30
12.1. FP File Specification ........................................................................................................ 31
4
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
1 Bibliography
[MUI]
[CMREF]
[MWT]
[U61]
Micro User Interface: ESR 002, 2009, http://www.e-s-r.net
STM32JavaF4 ARMCCv4 Reference Manual (TLT-0611-REF-STM32JavaF4)
Micro Widgets Toolkit: ESR 011, 2010, http://www.e-s-r.net
The Unicode Standard, Version 6.1, 2012
5
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
2 Introduction
2.1 Scope
The STM32JavaF4 ARMCCv4 User Interface Extension is the extension for embedded Java, dedicated
to the STM32JavaF4 ARMCCv4 line of products. As an extension, it requires a platform to run. It
features a complete thread-safe UI software stack, which is highly and easily configurable, and comes
with tools related to User Interface design: font designer, virtual device front panel designer, smart image
rendering, fast font rendering engine, fast 2D drawing, along with low resource consumption and haptic
sensor event management. It targets all major graphical display buffer organizations (zero, one or two
buffers modes, and pixel ordering), is ready for monochrome and full color displays.
This reference manual describes all the functionality of the UI extension. It is concise, but attempts to be
exact and complete. The semantics of the implemented standard libraries are described in their respective specifications. This reference manual only includes specific APIs related to porting UI extension
modules to a hardware device.
2.2 Intended Audience
The audience for this document is software engineers who need to understand the details of the JPF User
Interface Extension components, including their APIs, error codes and options.
2.3 Related Documents
Please refer to [CMREF] for details of the core JPF components.
6
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
3 Edition – Name – Version
Editions
Name
Version
MCU
Compiler
EVAL / DEV
UI
4.0.3
STM32JavaF4
Keil uVision
Table 3.1. Pack references
7
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
4 Features
4.1 Required Resources
Resource
Embedded Characteristics
MicroUI
51KB of Flash (max)
MWT
9KB of Flash (max)
NLS
0.5K of Flash (max)
PNG decoder
12 KB of Flash
Table 4.1. Required resources
4.2 Standard Libraries
Library
Reference
EmbJPF Versions SimJPF Versions
MUI
[MUI]
1.4
1.4
MWT
[MWT]
1.0
1.0
User Configurable
●
Table 4.2. Standard libraries
4.3 Domain Specific Libraries & API
Library
Reference
EmbJPF Versions SimJPF Versions
User Configurable
LLDISPLAY
This document
1.0
n/a
●
LLINPUT
This document
1.0
n/a
●
LLLEDS
This document
1.0
n/a
●
Table 4.3. Specific libraries
8
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
5 MicroUI
This user interface extension provides a thread-safe implementation of the [MUI] specification. This
implementation supports displays, inputs (buttons, joysticks, etc.), haptic (touch) sensors and LEDs.
It provides several graphical display buffer modes (double-buffer, direct, custom) as well as several
display memory layouts.
5.1 Java properties
Property
Value
ej.microui.vendor
IS2T
ej.microui.vendor.url
www.is2t.com
ej.microui.version
1.4.1
ej.microui.autostart
true | false.
See configuration variable MUI_01
Table 5.1. MicroUI Java properties
The properties are optionally loaded at runtime.
5.2 Error Messages
When an exception is thrown by the implementation of the MicroUI API, the error message
MUI:E=<messageId>
is issued, where the meaning of <messageId> is defined in Table 5.2.
Message ID
Description
1
Deadlock. Cannot wait for an event in the same thread that runs events.
Display.waitForEvent() must not be called in the display pump thread (e.g. in
paint methods).
2
Out of memory. The image limit is reached because too many images are opened
at the same time. Try to remove references on useless images and retry to open
the new image.
3
Out of memory. Not enough memory to allocate the Image's buffer.
4
A polygon cannot have more than 16 sides.
5
The platform cannot allocate memory to create a dynamic image.
6
Image's
7
The platform cannot decode this kind of image.
8
Another EventGenerator cannot be added into the system pool (max 254).
9
Font's path is limited to 100 characters.
10
Invalid font's path: cannot load this font.
15
FIFOPump
17
Out of memory. There is not enough memory to open a new FlyingImage.
18
There is not enough memory to add a new font.
19
Font's path must be relative to the classpath
20
Unknown event generator class name.
path is limited to 100 characters.
size must be positive
Table 5.2. MicroUI error messages
Note: the exception message is preceded by a call to MicroUI.beep() method, which outputs in the
default System.out stream the four letters 'b' 'e' 'e' 'p'.
9
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
5.3 Configuration
The library implementation has application-specific configuration variables:
Variable
MUI_01
Meaning
When set to true, automatically invoke MicroUI.start() at the end of MicroUI
static initialization [MUI].
Table 5.3. MicroUI configuration variables
10
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
6 Inputs
6.1 Low Level API: LLINPUT
LLINPUT
API is composed of the following files:
• the file LLINPUT_impl.h that defines the functions to be implemented
• the file LLINPUT.h that provides the functions for sending events
6.1.1 Implementation
is the first function called by the input stack and may be used to initialize
the underlying devices and bind them to event generator IDs.
LLINPUT_IMPL_initialize
LLINPUT_IMPL_enterCriticalSection and LLINPUT_IMPL_exitCriticalSection need to provide the
stack with a critical section mechanism for synchronizing devices when sending events to the internal
event queue. The mechanism used to implement the synchronization will depend on the platform configuration (with or without RTOS), and whether or not events are sent from an interrupt context.
allows the input stack to get the current state for devices connected to MicroUI States event generator, such as switch selector, coding wheels, etc.
LLINPUT_IMPL_getInitialStateValue
6.1.2 Sending Events
The LLINPUT API provides two generic functions for a C driver to send data to its associated Java event
generator:
• LLINPUT_sendEvent: sends a 32 bit encoded event to a specific event generator, specified by its ID.
If the input buffer is full the event is not added and the function returns 0, otherwise it returns 1.
• LLINPUT_sendEvents: sends event data to a specific event generator, specified by its ID. If the input
buffer cannot receive the whole data, the event is not added and the function returns 0, otherwise it
returns 1.
Events will be dispatched to the associated Java event generator that will be responsible for decoding
it (see Section 6.2).
The UI extension provides an implementation for each of MicroUI's built-in event generators. Each one
has dedicated functions that allows a driver to send them structured data without needing to understand
the underlying protocol to encode/decode the data. Table 6.1 shows the functions provided to send
structured events to the predefined event generators:
Function name
Default
event generator kinda
Comments
LLINPUT_sendCommandEvent
Command
Constants are provided that define all the
standard MicroUI commands [MUI].
LLINPUT_sendButtonPressedEvent
Buttons
In case of chronological sequences (such
as a RELEASE may only occur after a
PRESSED), it is the responsibility of the
driver to ensure the integrity of such sequences.
Pointer
In case of chronological sequences (such
as a RELEASE may only occur after a
LLINPUT_sendButtonReleasedEvent
LLINPUT_sendButtonRepeatedEvent
LLINPUT_sendPointerPressedEvent
LLINPUT_sendPointerReleasedEvent
11
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Function name
Default
event generator kinda
PRESSED), it is the responsibility of the
driver to ensure the integrity of such sequences. Depending on whether a button
of the pointer is pressed while moving, a
DRAG and/or a MOVE MicroUI event is
generated.
LLINPUT_sendPointerMovedEvent
LLINPUT_sendStateEvent
Comments
States
The initial value of each state machine
(of a States) is retrieved by a call to
LLINPUT_IMPL_getInitialStateValue
that needs to be implemented by the device. Alternatively, the initial value can be
specified in the XML static configuration.
LLINPUT_sendTouchPressedEvent
Pointer
LLINPUT_sendTouchReleasedEvent
LLINPUT_sendTouchMovedEvent
In case of chronological sequences (such
as a RELEASE may only occur after a
PRESSED), it is the responsibility of
the driver to ensure the integrity of such
sequences. These APIs will generate a
DRAG MicroUI event instead of a MOVE
while they represent a touch pad over a
display.
a
The implementation class is a subclass of the MicroUI class of the column.
Table 6.1. LLINPUT API for predefined event generators
6.1.3 Event buffer
The maximum usage of the internal event buffer may be retrieved at runtime using
LLINPUT_getMaxEventsBufferUsage function. This is useful for tuning the size of the buffer.
6.2 Java Event Generators
On the Java side, the UI extension provides an abstract class EventGenerator (package
com.is2t.microui.io) that must be implemented by clients who want to define their own event generators. Two abstract methods need to be implemented by subclasses:
• eventReceived: the event generator received an event from a C driver through the low level API
sendEvent function.
• eventsReceived: the event generator received an event made of several ints.
• setProperty: handle a generic property (key/value pair) set from the static initialization file (see
Section 6.3)
The event generator is responsible for converting incoming data to a MicroUI event and sending it to
its listener.
6.3 MicroUI Initialization
The XML file used as input by the MicroUI Static Initialization Tool may contain tags related to the
Input component as described below.
12
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
6.3.1 XML Description
<eventgenerators>
<!-- Generic Event Generators -->
<eventgenerator name="GENERIC" class="foo.bar.Zork">
<property name="PROP1" value="3"/>
<property name="PROP2" value="aaa"/>
</eventgenerator>
<!-- Predefined Event Generators -->
<command name="COMMANDS"/>
<buttons name="BUTTONS" extended="3"/>
<buttons name="JOYSTICK" extended="5"/>
<pointer name="POINTER" width="1200" height="1200"/>
<touch name="TOUCH" display="DISPLAY"/>
<states name="STATES" numbers="NUMBERS" values="VALUES"/>
</eventgenerators>
<array name="NUMBERS">
<elem value="3"/>
<elem value="2"/>
<elem value="5"/>
</array>
<array name="VALUES">
<elem value="2"/>
<elem value="0"/>
<elem value="1"/>
</array>
Figure 6.1. Event Generators Description
6.3.2 File Specification
Tag
Attributes
Description
The list of event generators
eventgenerators
priority
Optional. An integer value. Defines the priority of the
MicroUI dispatch thread (also called Input Pump). Default value is 5.
Describes a custom event generator. See also Section 6.2.
eventgenerator
name
The logical name
class
The event generator class (must extend
class). This
class must be available in the Java application classpath.
com.is2t.microui.io.EventGenerator
listener
Optional. Default listener's logical name. Only a display is a valid listener. If no listener is specified the listener is the default display.
A generic event generator property. The generic event
generator will receive this property at startup via the
method setProperty
property
name
The property key
value
The property value
The default event generator Command
command
name
The logical name
13
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Tag
Attributes
listener
Description
Optional. Default listener's logical name. Only a display is a valid listener. If no listener is specified the listener is the default display.
The default event generator Buttons.
buttons
name
The logical name
extended
Optional. An integer value. Defines the number of
buttons which support the MicroUI extended features
(elapsed time, click and double-click).
listener
Optional. Default listener's logical name. Only a display is a valid listener. If no listener is specified the listener is the default display.
The default event generator Pointer.
pointer
name
The logical name
width
An integer value. Defines the pointer area width.
height
An integer value. Defines the pointer area height.
extended
Optional. An integer value. Defines the number of
pointer buttons (right click, left, click etc.) which support the MicroUI extended features (elapsed time, click
and double-click).
listener
Optional. Default listener's logical name. Only a display is a valid listener. If no listener is specified the listener is the default display.
The default event generator Touch.
touch
name
The logical name
display
Logical name of the Display with which the touch is
associated.
listener
Optional. Default listener's logical name. Only a display is a valid listener. If no listener is specified the listener is the default display.
An event generator that manages a group of state machines. The state of a machine is changed by sending
an event using LLINPUT_sendStateEvent.
states
name
The logical name
numbers
The logical name of the array which defines the number of state machines for this States generator, and
their range of state values. The ids of the state machines start at 0. The number of state machines managed by the States generator is equal to the size of the
numbers array, and the value of each entry in the array is the number of different values supported for that
state machine. State machine values for state machine i
can be in the range 0 to numbers[i]-1.
values
Optional. The logical name of the array which defines the initial state values of the state machines
for this States generator. The values array must be
the same size as the numbers array. If initial state
values are specified using a values array then the
LLINPUT_IMPL_getInitialStateValue function is not
14
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Tag
Attributes
listener
Description
called, otherwise that function is used to establish the
initial valuesa.
Optional. Default listener's logical name. Only a display is a valid listener. If no listener is specified the listener is the default display.
An array of values.
array
name
The logical name
A value
elem
value
An integer value.
a
Except when using EmbJPF, where there is no equivalent to the LLINPUT_IMPL_getInitialStateValue function. If no values array is provided and the EmbJPF is being used, all state machines take 0 as their initial state
value.
Table 6.2. Event Generators Static Definition
6.4 Configuration
The library implementation has application-specific configuration variables:
Variable
INPUT_01
Meaning
Set the internal events queue size, in number of 32 bit events. (See also
LLINPUT_getMaxEventsBufferUsage function).
Table 6.3. LLINPUT configuration variables
15
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
7 Display
7.1 Low Level API: LLDISPLAY
7.1.1 Principle & Naming Convention
Each display stack provides a low level API in order to connect a display driver. The files
LLDISPLAY_[MODE]_impl.h define the API headers to be implemented, where MODE is one of the buffer
modes SWITCH, COPY, DIRECT, CUSTOM. For the APIs themselves, the naming convention is that their
names match the *_IMPL_* pattern when the functions need to be implemented.
7.1.2 Initialization
Each display stack gets initialized the same way:
• first, the function LLDISPLAY_[MODE]_IMPL_initialize is called: it asks its display driver to initialize
itself.
• second, the functions LLDISPLAY_[MODE]_IMPL_getWidth and LLDISPLAY_[MODE]_IMPL_getHeight
are called to retrieve the size of the physical screen.
7.1.3 Display characteristics
Functions LLDISPLAY_[MODE]_IMPL_isColor and LLDISPLAY_[MODE]_IMPL_getNumberOfColors directly implement the methods from the MicroUI Display class of the same names.
7.1.4 Color conversions
LLDISPLAY_[MODE]_IMPL_convertRGBColorToDisplayColor is called to convert a 24 bit RGB MicroUI
color in 0x00RRGGBB format into the "driver" display color.
LLDISPLAY_[MODE]_IMPL_convertDisplayColorToRGBColor is called to convert a display color to a 24
bit RGB MicroUI color.
7.1.5 Contrast
LLDISPLAY_[MODE]_IMPL_setContrast and DISPLAY_[MODE]_IIMPL_getContrast are called to set/get
the current display contrast intensity.
7.1.6 Font alpha adjustment
is called to get the adjustment to apply when
blending font pixels. A positive value makes blended pixels appear lighter, a negative value makes them
appear darker. A value of zero indicates no adjustment.
LLDISPLAY_[MODE]_IMPL_getFontAlphaAdjustment
7.1.7 BackLight
LLDISPLAY_[MODE]_IMPL_hasBackLight
indicates whether the display has backlight capabilities.
and DISPLAY_[MODE]_IIMPL_getBackLight are called to set/
get the current display backlight intensity.
LLDISPLAY_[MODE]_IMPL_setBackLight
LLDISPLAY_DIRECT_IMPL_backlightOn
the backlight
and LLDISPLAY_DIRECT_IMPL_backlightOff enable/disable
7.1.8 Working buffer
The display driver needs to allocate a runtime memory buffer for creating dynamic images when using
MicroUI Image.createImage() methods that explicitly create mutable images.
The display driver may choose to return an empty buffer. Thus, calling MicroUI Image.createImage()
methods will result in a java.lang.OutOfMemoryError exception.
16
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
LLDISPLAY_[MODE]_getWorkingBufferStartAddress
returns
LLDISPLAY_[MODE]_getWorkingBufferEndAddress returns the next
is the buffer length).
the
buffer
start
address.
address after the buffer (end-start
7.1.9 LLDISPLAY_SWITCH
This section describes additional functions to be implemented for the switch buffer mode. The file
LLDISPLAY_SWITCH_impl.h defines the whole set of functions to be implemented.
Function LLDISPLAY_SWITCH_getDisplayBufferAddress returns the address of the display
buffer and LLDISPLAY_SWITCH_getBackBufferAddress returns the address of the back
buffer for the very first drawing. These buffers will be swapped by the function
LLDISPLAY_SWITCH_setDisplayBufferAddress.
LLDISPLAY_SWITCH_synchronize
is called before any new drawing.
7.1.10 LLDISPLAY_COPY
This section describes additional functions to be implemented for the copy buffer mode. The file
LLDISPLAY_COPY_impl.h defines the whole set of functions to be implemented.
returns the back buffer address. The content of this buffer is
copied to the external display memory by the function LLDISPLAY_COPY_copyBuffer. The parameters
define the rectangular area of the content which has changed during the last drawing action and that
must be copied to the display buffer.
LLDISPLAY_COPY_getBackBufferAddress
LLDISPLAY_COPY_synchronize is called before the next drawing after a call to the copy method to avoid
flickering on the display device.
7.1.11 LLDISPLAY_DIRECT
This section describes additional functions to be implemented for the direct buffer mode. The file
LLDISPLAY_DIRECT_impl.h defines the whole set of functions to be implemented.
LLDISPLAY_DIRECT_getDisplayBufferAddress returns the display buffer address which is used simul-
taneously by the stack to draw and the display driver to refresh.
7.1.12 LLDISPLAY_CUSTOM
This section describes additional functions to be implemented for the custom buffer mode. The file
LLDISPLAY_CUSTOM_impl.h defines the whole set of functions to be implemented.
7.1.12.1 Display characteristics
Functions
LLDISPLAY_CUSTOM_getBPP,
LLDISPLAY_CUSTOM_isColor,
LLDISPLAY_CUSTOM_getNumberOfColors and LLDISPLAY_CUSTOM_isDoubleBuffered directly implement the methods from the MicroUI Display class of the same names.
7.1.12.2 Images allocations
Display buffers and images each have a unique ID. LLDISPLAY_CUSTOM_getDisplayBufferIdentifier
returns the integer which uniquely identifies the display.
LLDISPLAY_CUSTOM_allocateImage allocates a buffer for a dynamic image to store
LLDISPLAY_CUSTOM_allocateStaticImageDescriptor only allocates the descriptor
its content, while
for an image that
has been processed by the static images generator. A descriptor is composed of the image width, the
image height and the address of the encoded data content in (read-only) memory. Both functions return
an integer that uniquely identifies the allocated image. LLDISPLAY_CUSTOM_closeImage frees all associated resources to the given image identifier, so that identifier may be reused for future allocations.
7.1.12.3 Drawing primitives
A custom stack has to implement the following basic drawing actions:
17
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
• LLDISPLAY_CUSTOM_drawPixel,
• LLDISPLAY_CUSTOM_readPixel
• LLDISPLAY_CUSTOM_copyPixel
• LLDISPLAY_CUSTOM_drawRect
• LLDISPLAY_CUSTOM_fillRect
• LLDISPLAY_CUSTOM_copyArea
7.1.12.4 Synchronization
After the drawing actions, the display stack calls LLDISPLAY_CUSTOM_flush to flush the content of the
back buffer to the display buffer. The parameters define the rectangular area of the content which has
changed during last drawing action and that must be sent to the display buffer.
The display stack calls the method LLDISPLAY_CUSTOM_synchronize to wait for the display device to
refresh before any new drawing may occur.
7.1.12.5 Termination
LLDISPLAY_CUSTOM_dispose
the display driver.
is called at the end of the execution to free all resources associated with
7.2 MicroUI Initialization
The display component augments the static initialization file with:
• the configuration of each display
• fonts that are implicitly embedded within the application (also called system fonts). Applications can
also embed their own fonts.
7.2.1 XML Description
<display name="DISPLAY"/>
<fonts>
<font file="resources\fonts\myfont.ejf">
<range name="LATIN" sections="0-2"/>
<customrange start="0x21" end="0x3f"/>
</font>
<font file="C:\data\myfont.ejf"/>
</fonts>
7.2.2 File Specification
Tag
Attributes
Description
Display element describes one display.
display
name
The logical name of the display.
queueSize
Optional. Size of the internal events queue, as number
of 32 bit MicroUI events. Default value is 100.
timeout
Optional. Time in milliseconds. Handling an event cannot exceed this time, otherwise an internal exception is
thrown. -1 means no timeout (default value).
dropOnFull
Optional. true or false. When the internal events
queue is full the next event can be dropped or the oldest
18
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Tag
Attributes
Description
event available in the FIFO is removed. Default value is
true.
priority
Optional. An integer value. Defines the internal display
thread priority. Default value is 5.
default
Optional. true or false. Defines this display to be the
default display. By default the very first display described in the XML file is the default display.
fonts
The list of system fonts. The system fonts are available
for all displays.
font
A system font.
file
The font file path. The path may be absolute or relative
to the XML file.
A font generic range
range
name
The generic range name (LATIN, HAN etc.)
sections
Optional. Defines one or several sub parts of the generic range.
"1": add only the part 1 of the range
"1-5": add the parts 1 to 5
"1,5": add the parts 1 and 5
The combinations are allowed:
"1,5,6-8" add the parts 1, 5 and 6 to 8
By default all range's parts are embedded.
A font specific range
customrange
start
UTF16 value of the very first character to embed
end
UTF16 value of the very last character to embed
Table 7.1. Display Static Initialization XML tags definition
19
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
8 Image Generator
8.1 Configuration File
ConfigFile ::=
Line ::=
ImagePath
::=
ImageOption ::=
Identifier ::=
Letter ::=
LetterOrDigit ::=
Line [ 'EOL' Line ]*
ImagePath [ ':' ImageOption ]*
Identifier [ '/' Identifier ]*
[^:]*
Letter [ LetterOrDigit ]*
'a-zA-Z_$'
'a-zA-Z_$0-9'
Figure 8.1. Images Static Configuration File Grammar
8.2 Error Messages
ID
Type
0
Error
The static image generator has encountered an unexpected internal error.
1
Error
Images list file has not been specified.
2
Error
The static image generator cannot create the final raw file.
3
Error
The static image generator cannot read the images list file. Ensure the system allows reading of this file.
4
5
Description
Warning The static image generator has found no image to generate.
Error
The static image generator cannot load the images list file.
6
Warning The specified image path is invalid: the image will be not converted.
7
Warning There are too many or too few options for the desired format.
8
Error
Static image generator extension class is unknown.
9
Error
The static image generator has encountered an unexpected internal error.
10
Warning The specified output format is unknown: the image will be not converted.
11
Warning The specified format is not managed by the static image generator: the image will be not converted.
12
Warning The specified alpha level is invalid: the image will be not converted.
13
Warning The specified alpha level is not compatible with the specified format: the
image will be not converted.
14
Warning Specified attribute is undefined for the specified format.
Table 8.1. Static image generator error messages
20
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
9 Font Generator
9.1 Configuration File
ConfigFile ::= Line [ 'EOL' Line ]*
Line
::= FontPath [ ':' [ Ranges ] [ ':' BitsPerPixel ] ]
FontPath
::= Identifier [ '/' Identifier ]*
Ranges
::= Range [ ';' Range ]*
Range
::= CustomRangeList | KnownRange
CustomRangeList ::= CustomRange [ ',' CustomRange ]*
CustomRange
::= Number | Number '-' Number
KnownRange
::= Name [ SubRangeList ]?
SubRangeList ::= '(' SubRange [ ',' SubRange ]* ')'
SubRange
::= Number | Number - Number
Identifier
::= 'a-zA-Z_$' [ 'a-zA-Z_$0-9' ]*
Number
::= Number16 | Number10
Number16
::= '0x' [ Digit16 ]+
Number10
::= [ Digit10 ]+
Digit16
::= 'a-fA-F0-9'
Digit10
::= '0-9'
BitsPerPixel ::= '1' | '2' | '4' | '8'
Figure 9.1. Fonts Configuration File Grammar
9.2 Custom Range
Allows the selection of raw Unicode character ranges.
Examples:
• myfont:0x21-0x49: embed all characters from 0x21 to 0x49 (included).
• myfont:0x21-0x49,0x55: embed all characters from 0x21 to 0x49 and character 0x55
• myfont:0x21-0x49;0x55: same as previous, but by declaring two ranges.
9.3 Known Range
A known range is a range available in the following table. Each range is composed of sub-ranges that
have a unique id.
Examples:
• myfont:latin: embed all latin characters
• myfont:latin(5): embed all latin characters of sub range 5 (0xD8 to 0xF6)
• myfont:latin(1-5): embed all latin characters of sub ranges 1 to 5
• myfont:latin(1-5,7): embed all latin characters of sub ranges 1 to 5 and 7
• myfont:latin(1-5);latin(7): same as previous, but by declaring two ranges.
• myfont:latin(1-5);han: embed all latin characters of sub ranges 1 to 5 and all han characters
Table 9.1 describes the available list of ranges and sub-ranges (processed from the "Unicode Character
Database" available on the official unicode website [http://www.unicode.org/]).
[1] Arabic
0: 0x0600 to 0x0604
6: 0x0656 to 0x065E
12: 0x08A2 to 0x08AC 18: 0xFDF0 to 0xFDFC
1: 0x0606 to 0x060B
7: 0x066A to 0x066F
13: 0x08E4 to 0x08FE
2: 0x060D to 0x061A
8: 0x0671 to 0x06DC
14: 0xFB50 to 0xFBC1 20: 0xFE76 to 0xFEFC
3: 0x061E
9: 0x06DE to 0x06FF
15: 0xFBD3 to 0xFD3D
21
19: 0xFE70 to 0xFE74
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
4: 0x0620 to 0x063F
10: 0x0750 to 0x077F
16: 0xFD50 to 0xFD8F
5: 0x0641 to 0x064A
11: 0x08A0
17: 0xFD92 to 0xFDC7
0: 0x0531 to 0x0556
2: 0x0561 to 0x0587
4: 0x058F
1: 0x0559 to 0x055F
3: 0x058A
5: 0xFB13 to 0xFB17
[2] Armenian
[3] Balinese
0: 0x1B00 to 0x1B4B
1: 0x1B50 to 0x1B7C
[4] Bengali
0: 0x0981 to 0x0983
4: 0x09AA to 0x09B0
8: 0x09C7 to 0x09C8
12: 0x09DF to 0x09E3
1: 0x0985 to 0x098C
5: 0x09B2
9: 0x09CB to 0x09CE
13: 0x09E6 to 0x09FB
2: 0x098F to 0x0990
6: 0x09B6 to 0x09B9
10: 0x09D7
3: 0x0993 to 0x09A8
7: 0x09BC to 0x09C4
11: 0x09DC to 0x09DD
1: 0x3105 to 0x312D
2: 0x31A0 to 0x31BA
[5] Bopomofo
0: 0x02EA to 0x02EB
[6] Braille
0: 0x2800 to 0x28FF
[7] Buginese
0: 0x1A00 to 0x1A1B
1: 0x1A1E to 0x1A1F
[8] Buhid
0: 0x1740 to 0x1753
[9]
Canadian_Aboriginal
0: 0x1400 to 0x167F
1: 0x18B0 to 0x18F5
[10] Cherokee
0: 0x13A0 to 0x13F4
[11] Coptic
0: 0x03E2 to 0x03EF
1: 0x2C80 to 0x2CF3
2: 0x2CF9 to 0x2CFF
0: 0x0400 to 0x0484
2: 0x1D2B
4: 0x2DE0 to 0x2DFF
1: 0x0487 to 0x0527
3: 0x1D78
5: 0xA640 to 0xA697
0: 0x0900 to 0x0950
2: 0x0966 to 0x0977
4: 0xA8E0 to 0xA8FB
1: 0x0953 to 0x0963
3: 0x0979 to 0x097F
[14] Cyrillic
6: 0xA69F
[16] Devanagari
[17] Ethiopic
0: 0x1200 to 0x1248
9: 0x12B8 to 0x12BE
18: 0x2D80 to 0x2D96
1: 0x124A to 0x124D
10: 0x12C0
19: 0x2DA0 to 0x2DA6 28: 0xAB09 to 0xAB0E
2: 0x1250 to 0x1256
11: 0x12C2 to 0x12C5
20: 0x2DA8 to 0x2DAE 29: 0xAB11 to 0xAB16
3: 0x1258
12: 0x12C8 to 0x12D6
21: 0x2DB0 to 0x2DB6 30: 0xAB20 to 0xAB26
22
27: 0xAB01 to 0xAB06
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
4: 0x125A to 0x125D
13: 0x12D8 to 0x1310
22: 0x2DB8 to 0x2DBE 31: 0xAB28 to 0xAB2E
5: 0x1260 to 0x1288
14: 0x1312 to 0x1315
23: 0x2DC0 to 0x2DC6
6: 0x128A to 0x128D
15: 0x1318 to 0x135A
24: 0x2DC8 to 0x2DCE
7: 0x1290 to 0x12B0
16: 0x135D to 0x137C
25: 0x2DD0 to 0x2DD6
8: 0x12B2 to 0x12B5
17: 0x1380 to 0x1399
26: 0x2DD8 to 0x2DDE
0: 0x10A0 to 0x10C5
3: 0x10D0 to 0x10FA
6: 0x2D27
1: 0x10C7
4: 0x10FC to 0x10FF
7: 0x2D2D
2: 0x10CD
5: 0x2D00 to 0x2D25
[18] Georgian
[19] Glagolitic
0: 0x2C00 to 0x2C2E
1: 0x2C30 to 0x2C5E
[21] Greek
0: 0x0370 to 0x0373
8: 0x03A3 to 0x03E1
16: 0x1F20 to 0x1F45
24: 0x1FB6 to 0x1FC4
1: 0x0375 to 0x0377
9: 0x03F0 to 0x03FF
17: 0x1F48 to 0x1F4D
25: 0x1FC6 to 0x1FD3
2: 0x037A to 0x037D
10: 0x1D26 to 0x1D2A 18: 0x1F50 to 0x1F57
26: 0x1FD6 to 0x1FDB
3: 0x0384
11: 0x1D5D to 0x1D61 19: 0x1F59
27: 0x1FDD to 0x1FEF
4: 0x0386
12: 0x1D66 to 0x1D6A 20: 0x1F5B
28: 0x1FF2 to 0x1FF4
5: 0x0388 to 0x038A
13: 0x1DBF
21: 0x1F5D
29: 0x1FF6 to 0x1FFE
6: 0x038C
14: 0x1F00 to 0x1F15
22: 0x1F5F to 0x1F7D
30: 0x2126
7: 0x038E to 0x03A1
15: 0x1F18 to 0x1F1D
23: 0x1F80 to 0x1FB4
[22] Gujarati
0: 0x0A81 to 0x0A83
4: 0x0AAA to 0x0AB0 8: 0x0AC7 to 0x0AC9
12: 0x0AE6 to 0x0AF1
1: 0x0A85 to 0x0A8D
5: 0x0AB2 to 0x0AB3
9: 0x0ACB to 0x0ACD
2: 0x0A8F to 0x0A91
6: 0x0AB5 to 0x0AB9
10: 0x0AD0
3: 0x0A93 to 0x0AA8
7: 0x0ABC to 0x0AC5
11: 0x0AE0 to 0x0AE3
0: 0x0A01 to 0x0A03
5: 0x0A32 to 0x0A33
10: 0x0A47 to 0x0A48
1: 0x0A05 to 0x0A0A
6: 0x0A35 to 0x0A36
11: 0x0A4B to 0x0A4D
2: 0x0A0F to 0x0A10
7: 0x0A38 to 0x0A39
12: 0x0A51
3: 0x0A13 to 0x0A28
8: 0x0A3C
13: 0x0A59 to 0x0A5C
4: 0x0A2A to 0x0A30
9: 0x0A3E to 0x0A42
14: 0x0A5E
0: 0x2E80 to 0x2E99
3: 0x3005
6: 0x3038 to 0x303B
9: 0xF900 to 0xFA6D
1: 0x2E9B to 0x2EF3
4: 0x3007
7: 0x3400 to 0x4DB5
10: 0xFA70 to 0xFAD9
2: 0x2F00 to 0x2FD5
5: 0x3021 to 0x3029
8: 0x4E00 to 0x9FCC
0: 0x1100 to 0x11FF
4: 0x3260 to 0x327E
8: 0xD7CB to 0xD7FB 12: 0xFFD2 to 0xFFD7
1: 0x302E to 0x302F
5: 0xA960 to 0xA97C
9: 0xFFA0 to 0xFFBE
2: 0x3131 to 0x318E
6: 0xAC00 to 0xD7A3
10: 0xFFC2 to 0xFFC7
[23] Gurmukhi
15: 0x0A66 to 0x0A75
[24] Han
[25] Hangul
23
13: 0xFFDA to
0xFFDC
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
3: 0x3200 to 0x321E
7: 0xD7B0 to 0xD7C6
11: 0xFFCA to 0xFFCF
0: 0x0591 to 0x05C7
3: 0xFB1D to 0xFB36
6: 0xFB40 to 0xFB41
1: 0x05D0 to 0x05EA
4: 0xFB38 to 0xFB3C
7: 0xFB43 to 0xFB44
2: 0x05F0 to 0x05F4
5: 0xFB3E
8: 0xFB46 to 0xFB4F
[26] Hanunoo
0: 0x1720 to 0x1734
[27] Hebrew
[28] Hiragana
0: 0x3041 to 0x3096
1: 0x309D to 0x309F
[29] Kannada
0: 0x0C82 to 0x0C83
4: 0x0CAA to 0x0CB3
8: 0x0CCA to 0x0CCD 12: 0x0CE6 to 0x0CEF
1: 0x0C85 to 0x0C8C
5: 0x0CB5 to 0x0CB9
9: 0x0CD5 to 0x0CD6
2: 0x0C8E to 0x0C90
6: 0x0CBC to 0x0CC4
10: 0x0CDE
3: 0x0C92 to 0x0CA8
7: 0x0CC6 to 0x0CC8
11: 0x0CE0 to 0x0CE3
0: 0x30A1 to 0x30FA
2: 0x31F0 to 0x31FF
4: 0x3300 to 0x3357
1: 0x30FD to 0x30FF
3: 0x32D0 to 0x32FE
5: 0xFF66 to 0xFF6F
13: 0x0CF1 to 0x0CF2
[30] Katakana
6: 0xFF71 to 0xFF9D
[32] Khmer
0: 0x1780 to 0x17DD
2: 0x17F0 to 0x17F9
1: 0x17E0 to 0x17E9
3: 0x19E0 to 0x19FF
[33] Lao
0: 0x0E81 to 0x0E82
5: 0x0E94 to 0x0E97
10: 0x0EAA to
0x0EAB
15: 0x0EC8 to 0x0ECD
1: 0x0E84
6: 0x0E99 to 0x0E9F
11: 0x0EAD to 0x0EB9 16: 0x0ED0 to 0x0ED9
2: 0x0E87 to 0x0E88
7: 0x0EA1 to 0x0EA3
12: 0x0EBB to 0x0EBD 17: 0x0EDC to 0x0EDF
3: 0x0E8A
8: 0x0EA5
13: 0x0EC0 to 0x0EC4
4: 0x0E8D
9: 0x0EA7
14: 0x0EC6
0: 0x0041 to 0x005A
8: 0x1D00 to 0x1D25
16: 0x2090 to 0x209C
24: 0xA790 to 0xA793
1: 0x0061 to 0x007A
9: 0x1D2C to 0x1D5C
17: 0x212A to 0x212B
25: 0xA7A0 to
0xA7AA
2: 0x00AA
10: 0x1D62 to 0x1D65
18: 0x2132
26: 0xA7F8 to 0xA7FF
3: 0x00BA
11: 0x1D6B to 0x1D77 19: 0x214E
27: 0xFB00 to 0xFB06
4: 0x00C0 to 0x00D6
12: 0x1D79 to 0x1DBE 20: 0x2160 to 0x2188
28: 0xFF21 to 0xFF3A
5: 0x00D8 to 0x00F6
13: 0x1E00 to 0x1EFF
21: 0x2C60 to 0x2C7F
29: 0xFF41 to 0xFF5A
6: 0x00F8 to 0x02B8
14: 0x2071
22: 0xA722 to 0xA787
7: 0x02E0 to 0x02E4
15: 0x207F
23: 0xA78B to 0xA78E
0: 0x1900 to 0x191C
2: 0x1930 to 0x193B
4: 0x1944 to 0x194F
1: 0x1920 to 0x192B
3: 0x1940
[34] Latin
[35] Limbu
24
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
[36] Malayalam
0: 0x0D02 to 0x0D03
3: 0x0D12 to 0x0D3A
6: 0x0D4A to 0x0D4E
9: 0x0D66 to 0x0D75
1: 0x0D05 to 0x0D0C
4: 0x0D3D to 0x0D44
7: 0x0D57
10: 0x0D79 to 0x0D7F
2: 0x0D0E to 0x0D10
5: 0x0D46 to 0x0D48
8: 0x0D60 to 0x0D63
0: 0x1800 to 0x1801
2: 0x1806 to 0x180E
4: 0x1820 to 0x1877
1: 0x1804
3: 0x1810 to 0x1819
5: 0x1880 to 0x18AA
[37] Mongolian
[38] Myanmar
0: 0x1000 to 0x109F
1: 0xAA60 to 0xAA7B
[39] New_Tai_Lue
0: 0x1980 to 0x19AB
2: 0x19D0 to 0x19DA
1: 0x19B0 to 0x19C9
3: 0x19DE to 0x19DF
[40] Nko
0: 0x07C0 to 0x07FA
[41] Ogham
0: 0x1680 to 0x169C
[42] Oriya
0: 0x0B01 to 0x0B03
4: 0x0B2A to 0x0B30
8: 0x0B47 to 0x0B48
12: 0x0B5F to 0x0B63
1: 0x0B05 to 0x0B0C
5: 0x0B32 to 0x0B33
9: 0x0B4B to 0x0B4D
13: 0x0B66 to 0x0B77
2: 0x0B0F to 0x0B10
6: 0x0B35 to 0x0B39
10: 0x0B56 to 0x0B57
3: 0x0B13 to 0x0B28
7: 0x0B3C to 0x0B44
11: 0x0B5C to 0x0B5D
[44] Phags_Pa
0: 0xA840 to 0xA877
[46] Runic
0: 0x16A0 to 0x16EA
1: 0x16EE to 0x16F0
[48] Sinhala
0: 0x0D82 to 0x0D83
3: 0x0DB3 to 0x0DBB
6: 0x0DCA
9: 0x0DD8 to 0x0DDF
1: 0x0D85 to 0x0D96
4: 0x0DBD
7: 0x0DCF to 0x0DD4
10: 0x0DF2 to 0x0DF4
2: 0x0D9A to 0x0DB1
5: 0x0DC0 to 0x0DC6
8: 0x0DD6
1: 0x070F to 0x074A
2: 0x074D to 0x074F
[49] Syloti_Nagri
0: 0xA800 to 0xA82B
[50] Syriac
0: 0x0700 to 0x070D
[51] Tagalog
0: 0x1700 to 0x170C
1: 0x170E to 0x1714
[52] Tagbanwa
0: 0x1760 to 0x176C
1: 0x176E to 0x1770
2: 0x1772 to 0x1773
25
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
[53] Tai_Le
0: 0x1950 to 0x196D
1: 0x1970 to 0x1974
[54] Tamil
0: 0x0B82 to 0x0B83
5: 0x0B9C
10: 0x0BBE to 0x0BC2 15: 0x0BE6 to 0x0BFA
1: 0x0B85 to 0x0B8A
6: 0x0B9E to 0x0B9F
11: 0x0BC6 to 0x0BC8
2: 0x0B8E to 0x0B90
7: 0x0BA3 to 0x0BA4
12: 0x0BCA to
0x0BCD
3: 0x0B92 to 0x0B95
8: 0x0BA8 to 0x0BAA 13: 0x0BD0
4: 0x0B99 to 0x0B9A
9: 0x0BAE to 0x0BB9
14: 0x0BD7
0: 0x0C01 to 0x0C03
4: 0x0C2A to 0x0C33
8: 0x0C4A to 0x0C4D
12: 0x0C66 to 0x0C6F
1: 0x0C05 to 0x0C0C
5: 0x0C35 to 0x0C39
9: 0x0C55 to 0x0C56
13: 0x0C78 to 0x0C7F
2: 0x0C0E to 0x0C10
6: 0x0C3D to 0x0C44
10: 0x0C58 to 0x0C59
3: 0x0C12 to 0x0C28
7: 0x0C46 to 0x0C48
11: 0x0C60 to 0x0C63
[55] Telugu
[56] Thaana
0: 0x0780 to 0x07B1
[57] Thai
0: 0x0E01 to 0x0E3A
1: 0x0E40 to 0x0E5B
[58] Tibetan
0: 0x0F00 to 0x0F47
2: 0x0F71 to 0x0F97
4: 0x0FBE to 0x0FCC
1: 0x0F49 to 0x0F6C
3: 0x0F99 to 0x0FBC
5: 0x0FCE to 0x0FD4
1: 0x2D6F to 0x2D70
2: 0x2D7F
6: 0x0FD9 to 0x0FDA
[59] Tifinagh
0: 0x2D30 to 0x2D67
[61] Yi
0: 0xA000 to 0xA48C
1: 0xA490 to 0xA4C6
[62] Common
0: 0x0000 to 0x0040
22: 0x0E3F
44: 0x214F to 0x215F
1: 0x005B to 0x0060
23: 0x0FD5 to 0x0FD8 45: 0x2189
67: 0x3358 to 0x33FF
2: 0x007B to 0x00A9
24: 0x10FB
46: 0x2190 to 0x23F3
68: 0x4DC0 to 0x4DFF
3: 0x00AB to 0x00B9
25: 0x16EB to 0x16ED 47: 0x2400 to 0x2426
69: 0xA700 to 0xA721
4: 0x00BB to 0x00BF
26: 0x1735 to 0x1736
48: 0x2440 to 0x244A
70: 0xA788 to 0xA78A
5: 0x00D7
27: 0x1802 to 0x1803
49: 0x2460 to 0x26FF
71: 0xA830 to 0xA839
6: 0x00F7
28: 0x1805
50: 0x2701 to 0x27FF
72: 0xFD3E to 0xFD3F
7: 0x02B9 to 0x02DF
29: 0x1CD3
51: 0x2900 to 0x2B4C
73: 0xFDFD
8: 0x02E5 to 0x02E9
30: 0x1CE1
52: 0x2B50 to 0x2B59
74: 0xFE10 to 0xFE19
9: 0x02EC to 0x02FF
31: 0x1CE9 to 0x1CEC 53: 0x2E00 to 0x2E3B
75: 0xFE30 to 0xFE52
10: 0x0374
32: 0x1CEE to 0x1CF3 54: 0x2FF0 to 0x2FFB
76: 0xFE54 to 0xFE66
11: 0x037E
33: 0x1CF5 to 0x1CF6
55: 0x3000 to 0x3004
77: 0xFE68 to 0xFE6B
12: 0x0385
34: 0x2000 to 0x200B
56: 0x3006
78: 0xFEFF
13: 0x0387
35: 0x200E to 0x2064
57: 0x3008 to 0x3020
79: 0xFF01 to 0xFF20
26
66: 0x327F to 0x32CF
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
14: 0x0589
36: 0x206A to 0x2070
58: 0x3030 to 0x3037
80: 0xFF3B to 0xFF40
15: 0x060C
37: 0x2074 to 0x207E
59: 0x303C to 0x303F
81: 0xFF5B to 0xFF65
16: 0x061B
38: 0x2080 to 0x208E
60: 0x309B to 0x309C
82: 0xFF70
17: 0x061F
39: 0x20A0 to 0x20B9
61: 0x30A0
83: 0xFF9E to 0xFF9F
18: 0x0640
40: 0x2100 to 0x2125
62: 0x30FB to 0x30FC
84: 0xFFE0 to 0xFFE6
19: 0x0660 to 0x0669
41: 0x2127 to 0x2129
63: 0x3190 to 0x319F
85: 0xFFE8 to 0xFFEE
20: 0x06DD
42: 0x212C to 0x2131
64: 0x31C0 to 0x31E3
86: 0xFFF9 to 0xFFFD
21: 0x0964 to 0x0965
43: 0x2133 to 0x214D
65: 0x3220 to 0x325F
0: 0x0300 to 0x036F
5: 0x0951 to 0x0952
10: 0x1CF4
1: 0x0485 to 0x0486
6: 0x1CD0 to 0x1CD2
11: 0x1DC0 to 0x1DE6 16: 0x3099 to 0x309A
2: 0x064B to 0x0655
7: 0x1CD4 to 0x1CE0
12: 0x1DFC to 0x1DFF 17: 0xFE00 to 0xFE0F
3: 0x065F
8: 0x1CE2 to 0x1CE8
13: 0x200C to 0x200D
4: 0x0670
9: 0x1CED
14: 0x20D0 to 0x20F0
[63] Inherited
[64] Sundanese
0: 0x1B80 to 0x1BBF
1: 0x1CC0 to 0x1CC7
[65] Lepcha
0: 0x1C00 to 0x1C37
1: 0x1C3B to 0x1C49
2: 0x1C4D to 0x1C4F
[66] Ol_Chiki
0: 0x1C50 to 0x1C7F
[67] Vai
0: 0xA500 to 0xA62B
[68] Saurashtra
0: 0xA880 to 0xA8C4
1: 0xA8CE to 0xA8D9
[69] Kayah_Li
0: 0xA900 to 0xA92F
[70] Rejang
0: 0xA930 to 0xA953
1: 0xA95F
[71] Cham
0: 0xAA00 to 0xAA36
2: 0xAA50 to 0xAA59
1: 0xAA40 to 0xAA4D 3: 0xAA5C to 0xAA5F
[72] Tai_Tham
0: 0x1A20 to 0x1A5E
2: 0x1A7F to 0x1A89
1: 0x1A60 to 0x1A7C
3: 0x1A90 to 0x1A99
4: 0x1AA0 to 0x1AAD
[73] Tai_Viet
0: 0xAA80 to 0xAAC2 1: 0xAADB to
0xAADF
[74] Samaritan
0: 0x0800 to 0x082D
1: 0x0830 to 0x083E
27
15: 0x302A to 0x302D
18: 0xFE20 to 0xFE26
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
[75] Lisu
0: 0xA4D0 to 0xA4FF
[76] Bamum
0: 0xA6A0 to 0xA6F7
[77] Javanese
0: 0xA980 to 0xA9CD
1: 0xA9CF to 0xA9D9
2: 0xA9DE to 0xA9DF
[78] Meetei_Mayek
0: 0xAAE0 to 0xAAF6 1: 0xABC0 to 0xABED 2: 0xABF0 to 0xABF9
[79] Batak
0: 0x1BC0 to 0x1BF3
1: 0x1BFC to 0x1BFF
[80] Mandaic
0: 0x0840 to 0x085B
1: 0x085E
Table 9.1. Ranges
9.4 Error Messages
ID
Type
0
Error
The static font generator has encountered an unexpected internal error.
1
Error
Fonts list file has not been specified.
2
Error
The static font generator cannot create the final raw file.
3
Error
The static font generator cannot read the fonts list file.
4
5
Description
Warning The static font generator has found no font to generate.
Error
The static font generator cannot load the fonts list file.
6
Warning The specified font path is invalid: the font will be not converted.
7
Warning There are too many arguments on a line: the current entry is ignored.
8
Error
The static font generator has encountered an unexpected internal error.
9
Error
The static font generator has encountered an unexpected internal error.
10
Warning The specified entry is invalid: the current entry is ignored.
11
Warning The specified entry does not contain a list of characters: the current entry is
ignored.
12
Warning The specified entry does not contain a list of identifiers: the current entry is
ignored.
13
Warning The specified entry is an invalid width: the current entry is ignored.
14
Warning The specified entry is an invalid height: the current entry is ignored.
15
Warning The specified entry does not contain the characters addresses: the current
entry is ignored.
16
Warning The specified entry does not contain the characters bitmaps: the current entry is ignored.
17
Warning The specified entry bits-per-pixel value is invalid: the current entry is ignored.
18
Warning The specified range is invalid: the current entry is ignored.
Table 9.2. Static Font Generator error messages
28
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
10 LEDs
10.1 Low Level API: LLLEDS
10.1.1 Principle
The LEDs stack provides a low level API for connecting LED drivers. The file LLLEDS_impl.h, which
comes with the LEDs stack, defines the API headers to be implemented.
10.1.2 Naming convention
The Low Level API relies on functions that need to be implemented. The naming convention for such
functions is that their names match the *_IMPL_* pattern.
10.1.3 Initialization
The first function called is LLLEDS_IMPL_initialize which allows the driver to initialize all LED devices. This method must return the number of LEDs available.
Each LED has a unique identifier. The first LED has the ID 0 and the last one the ID NbLEDs – 1.
This UI extension provides support to efficiently implement the set of methods that interact with the
LEDs provided by a device. Below are the relevant C functions:
• LLLEDS_IMPL_getIntensity: get the intensity of a specific LED using its ID.
• LLLEDS_IMPL_setIntensity: set the intensity of a LED using its ID.
29
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
11 MWT Implementation
11.1 Error Messages
When an exception is thrown by the runtime, the error message
MWT=<messageId>
is issued, where <messageId> meaning is defined in the next table:
Message ID
1
Description
A widget cannot be at two places within one widget hierarchy.
Table 11.1. MWT error messages
30
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
12 Front Panel
12.1 FP File
12.1.1 XML Schema
<?xml version="1.0"?>
<frontpanel
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://xml.is2t.com/ns/1.0/frontpanel"
xsi:schemaLocation="http://xml.is2t.com/ns/1.0/frontpanel .fp1.0.xsd">
<description file="widgets.desc"/>
<device name="example" skin="example-device.png">
<body>
<init class="[fully-qualified-class-name]"/> (optional)
<[widget-type] id="0" x="54" y="117" [widget-attributes] />
<[widget-type] id="1" x="266" y="115" [widget-attributes] />
...
</body>
</device>
</frontpanel>
12.1.2 File Specification
Tag
Attributes
The root element
fp
xmlns:xsi
Invariant taga
xmlns
Invariant tagb
xsi:schemaLocation
Invariant tagc
Defines the widgets descriptions file (which is automatically generated)
description
file
The widgets descriptions filed
The device root element
device
name
The device logical name
skin
Refers to a PNG file which defines the device
background
Defines the device's body. It contains the elements that define the widgets that make up the
front panel.
body
init
Description
class
Optional tag that defines a class to be loaded at
startup. The class can contain a static initializer to
initiate required behavior. The body tag can contain several init tags; the classes will be loaded
in the order of the init tags.
Defines the widget "display with pixels"
pixelatedDisplay
id
The unique widget ID
x
The widget x-coordinate
y
The widget y-coordinate
width
The display's width in pixels
height
The display's height in pixels
31
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Tag
Attributes
Description
realWidth
The logical display's width (the width returned to
MicroUI application)
realHeight
The logical display's height (the height returned
to MicroUI application)
initialColor
The default display background color
extensionClass
The extension class which defines the display
characteristics
Defines the widget "basic push button"
push
id
The unique widget ID
x
The widget x-coordinate
y
The widget y-coordinate
skin
The image to show when the button is released.
pushedSkin
The image to show when the button is pressed.
filter
The image which defines the button active area
listenerClass
The class which implements the button listener
interface
Defines the widget "repeat push button"
repeatPush
id
The unique widget ID
x
The widget x-coordinate
y
The widget y-coordinate
skin
The image to show when the button is released.
pushedSkin
The image to show when the button is pressed.
repeatPeriod
The time in milliseconds which defines the period
of the repeat action
filter
The image which defines the button active area
listenerClass
The class which implements the repeat button listener interface
Defines the widget "joystick"
joystick
id
The unique widget ID
x
The widget x-coordinate
y
The widget y-coordinate
skin
The image to show when the joystick is released.
mask
The image which defines the joystick active area
upSkin
The image to show when the button UP is pressed
downSkin
The image to show when the button DOWN is
pressed
leftSkin
The image to show when the button LEFT is
pressed
rightSkin
The image to show when the button RIGHT is
pressed
enterSkin
The image to show when the button ENTER is
pressed (the central button)
disableEnter
true to disable the ENTER button
32
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
Tag
Attributes
Description
repeatPeriod
The time in milliseconds which defines the period
of the repeat action
listenerClass
The class which implements the joystick listener
interface
Defines the widget "pointer"
pointer
id
The unique widget ID
x
The widget x-coordinate
y
The widget y-coordinate
width
The pointer area's width
height
The pointer area's height
touch
true means the pointer simulates a touch
listenerClass
The class which implements the pointer listener
interface
Defines the widget "2-states LED " (light on or
light off)
led2states
id
The unique widget ID
x
The widget x-coordinate
y
The widget y-coordinate
ledOff
The image to show when the LED is off
ledOn
The image to show when the LED is on
overlay
true means the LED can be overlaid by another
LED (transparency management)
a
Must be "http://www.w3.org/2001/XMLSchema-instance"
Must be "http://xml.is2t.com/ns/1.0/frontpanel"
c
Must be "http://xml.is2t.com/ns/1.0/frontpanel .fp1.0.xsd"
d
Must be "widgets.desc"
b
Table 12.1. FP File Specification
33
STM32Java UI Extension: - STM32JavaF4 - Keil uVision [Reference Manual]
13 Document History
Date
Revision
Description
January 11th 2013
A
First release
July 11th 2013
B
Update for STM32Java 2.0.0
June 19th 2014
C
Update for STM32Java 3.0.0
34