btSetLED (Function)

Top  Previous  Next

Architecture:

X32 / NX32

Device support:

MX2 pro, DX4 pro, AX9 pro, MX2 turbo/encore/warp, AX9 turbo

Firmware version:

1.08


This function is used to set the status LED on the Bluetooth smart antenna.

 

Input:

color

The color of the LED.

0

- LED off.

1

- Green.

2

- Red.

3

- Orange.

 

Return: INT

0

- Success.

-1

- Bluetooth library is not open.

 

Declaration:

FUNCTION btSetLED : INT;
VAR_INPUT
  color : SINT;
END_VAR;

 

Example:

INCLUDE rtcu.inc
 
PROGRAM test;
 
...
// Set the LED
btSetLED(color := 1);
...
 
END_PROGRAM;