Macro programming

In this chapter we want to give an overview about the programmability of the module. From a simple if-then logic to calculations and integration of external sensors and actuators.


General macro information

Macro Overview

First steps to macro programming

Macro types

Overview about the different macro types

Process macros

Different possibilities of process macros

If statements

Conditional statements

Loops

Define and use different loops

StringRegister

Commands and calculations


Calculations

Mathematical functions

Register types and calculations

Array functions

Fill, sort


Macro Overview

First steps to macro programming:

- Defining a macro

- Connect a macro to a touch event

- Command syntax

- Help functionality

Macro types

Overview about the different macro types:

- Screen

- Normal macro

- Touchmacro

- Process macro

- I/O-Port macro

- I/O-Bit macro

- Analogue macro

- RS232 receive macro

- Second macro

- Gesture macro

Process macros

Different possibilities of process macros:

- Define macro process

- Conditional macro process

- Automatic macro process

- Process macro

- I/O-Port macro

- I/O-Bit macro

- Analogue macro

- RS232 receive macro

- Second macro

- Gesture macro

If statements

Conditional statements:

- Comparison between C-Code and uniTFT-Macrocode

- Highlighting commands #MFS, #MFJ, #MFE, #MRC

- Use of calculation ifte(), insideE(), insideU()#

Loops

Define and use different loops

- Do-while loop

- For loop

- While loop using call (#MFC, #MFR)

StringRegister

Commands and calculations:

- Set / replace string from index

- Copy sub-string

- String and date output

- Split string

- string length

- compare two strings

Mathematical functions

Register types and calculations:

- Float / Integer bit size

- Mathematical functions

- Increment/Decrement

Array functions

Create, fill and sort values in arrays

- Size

- Index read and write