Inverting a Bit (ON/OFF)

Touch the Switch and the specified bit will turn ON. (Even if you release the switch, it will remain ON.)

Touch the same Switch again, and the specified bit will now be turned OFF. (The bit remains off until the next touch.)

The switch alternates between ON/OFF each time it is touched.

Example Operation

Setting Workflow

  1. Add Variables
  2. Set up Parts

Add Variables

Project Explorer : [Variables] ➞ [All Variables]

Add the below variable(s).

Variables property:

[Name] [Data Type]

Var1

[BOOL]

Set up Parts

Project Explorer : [Screen Design] ➞ [Screens] ➞ [Screen1]

Drag and drop the following objects from the [Tool Chest] to the screen.

Switch object (Name: Switch1) properties:

Tab Sub Tab Property Value
[Function] [Touch] [Operation] [Type] [Bit]
[Operation] [Toggle]
[Destination] [Variable] [Name]: Var1