Crate embedded_multi_page_hmi[−][src]
Expand description
Embedded Multi-Page HMI
The embedded multi-page HMI combines a resource constraint display output and a constraint fixed button input by an interaction model.
Input
Input is limited to a small set of buttons.
Depending on the amount of buttons several interaction models are predominant. The buttons get a semantic meaning, and allow for certain interaction models. The more buttons there are the more convenient the interaction model is.
Button | Semantics | Assigned activity |
---|---|---|
first | action | activate, confirm, trigger, modify, … |
second | next | select the next item |
third | previous | select the previous item in list |
fourth | back | navigate to the previous position |
fifth | home | go to home page, reset |
A rotary knop can be modelled as three buttons (action, next, previous).
Output
Display
The output is on one single display. The display can be
- alphanumerical,
- or graphical display.
Pages
The output is organized in pages. Exactly one page is displayed at a time on the display.
Every page has a lifetime.
Page | Meaning |
---|---|
Home | Is Mandatory; Is the fallback Page, Start point for all navigation |
Startup | Optional; Shown during init; no interaction; replaced by Home |
Shutdown | Optional; Shown during de-init; no interaction |
Pages have the following properties:
- Can handle input interactions.
- this can be used to capture input e.g. of numbers, flags that get delegated to a data model underneath
- Have a lifetime: How long are they displayed w/o input
- If the lifetime is over, automatically the home page or next page is activated.
- Pages can have dynamic content (like current time, temperature, etc) that is updated on a regular base
Interaction Models
Between pages can be navigated, triggered by an interaction or automatically triggered by events (from timer or value change)
One Button - Sequence of Pages
- The
action
interaction activates the next page. - Inside the pages no activity is possible
Two Button/ Three Button - Sequence of Pages
More than one button input allows inter-page interaction.
Three button interaction is like two button interaction, except that
previous
is a shortcut for iterating with next
through a looped list of
items.
There are information pages and setting pages.
Information pages:
- purely display (dynamic) information
- do not allow for internal interaction
Setting pages:
-
Allow to select items or enter values
-
The
next
interaction activates the next info page. -
The
action
interaction activates the setting page(s). -
Inside the info pages no activity is possible
-
Inside the setting page(s) it is possible to
- select items with
next
interaction - activate items with
action
interaction - Go back to home (info) page could be item to select and activate
- select items with
Modules
Home of several general purpose page implementations
Structs
A setting implemented using Cell
Any error a page update my run into
PageLifetime enables a page to automatically switch to another page after a certain time.
The PageManager is responsible for switching among pages while pages do not know about other pages. The PageManager also dispatches events and updates the current page.
Enums
Possible Interactions derived from the input
Page navigation events dispatched by pagemanager
Traits
Data structures that implement the Page trait are Pages and can be handled by the PageManager type
A page is responsible to implement user interaction
Data structures that implement the Page trait are Pages and can be handled by the PageManager type
A setting can be set and get