beautypg.com

Example code 4.1 – Wavetronix Click 500 (programmable controller) (CLK-500) - Developer Guide User Manual

Page 48

background image

CHAPTER 4 • OPERATING FUNCTIONS AND MENU 47

Submenu 1 Selection

Active LED

Solid/flashing

1

1st Yellow LED

Solid

2

2nd Yellow LED

Solid

3

3rd Yellow LED

Solid

4

4th Yellow LED

Solid

5

1st Yellow LED

flashing

6

2nd Yellow LED

flashing

7

3rd Yellow LED

flashing

8

4th Yellow LED

flashing

Table 4.1 – Submenu 1 Selection LEDs

Submenu 2 Selection

Active LED

Solid/flashing

1

1st Red LED

Solid

2

2nd Red LED

Solid

3

3rd Red LED

Solid

4

4th Red LED

Solid

5

1st Red LED

flashing

6

2nd Red LED

flashing

7

3rd Red LED

flashing

8

4th Red LED

flashing

Table 4.2 – Submenu 2 Selection LEDs

Example Code 4.1

This example can be found in the Click500ExampleCode folder and is named

“ExampleCode4.1.c.” The purpose of this example is to demonstrate how to construct a

menu with modes and tasks. Setup1 and Mode1 will run upon startup and print the current

state of Selection1 and then the current mode continuously. Task A can be selected to run

using the push-button and LEDs.

Each mode and task performs a different function. TaskA allows you to select the text color

by using Selection1.