ViSi-Genie Magic: Three State Momentary Button
Introduction
This codebase example demonstrates the implementation of a custom three-state momentary button in ViSi-Genie. The custom three-state momentary button is created using a user button object with three frames. The behaviour of the user button in response to touch is then modified using the following magic objects:
- Magic Move
- Magic Release
- Magic Touch
The state of the custom button is sent to the serial port as a REPORT_OBJ message.
In the standard ViSi-Genie environment, the above is not possible since the behaviour of a user button is internally managed by a ViSi-Genie program. The magic objects in Workshop Pro however allow the user to have more control of a ViSi-Genie program.
Note
Worskhop 4 PRO is needed for this codebase example.
Prerequisites
This codebase example assumes the reader can program the 4D Systems display module using Workshop4 IDE ViSi-Genie environment. Beginners are advised to read the following aplication notes.
- ViSi-Genie: Getting Started with PICASO Displays
- ViSi-Genie: Getting Started with DIABLO-16 Displays
- ViSi-Genie: Getting Started with PIXXI Displays
- ViSi-Genie: User Button
Instructions
-
Compile the project and upload it to any 4D Systems displays with PICASO, DIABLO-16, PIXXI-28 and PIXXI-44 graphics processors in this codebase example we are using uLCD-32PTU. Copy the supporting files to a uSD mounted to the PC. Properly unmount the uSD card from the PC and mount it to the target display.
-
Open GTX Tool from Tools > GTX to show the behaviour of the user button in response to the touch.