User manual

RC200/203 Manual
www.celoxica.com Page 41
Parameters: Index: LED index, of type unsigned 1.
Value: Boolean control value, of type unsigned 1.
Timing: 1 clock cycle.
Description:
Turns the
Index number LED either on or off. A Value of 1
means ON, and 0 means OFF.
5.4.2 RC200LED*Write() macros
extern macro proc RC200LED0Write (Value);
extern macro proc RC200LED1Write (Value);
Parameters: Value: Boolean control value, of type unsigned 1
Timing: 1 clock cycle
Description:
Controls LED 0 or LED1. A
Value of 1 means ON, and 0
means OFF.
5.4.3 RC200LEDWriteMask()
extern macro proc RC200LEDWriteMask (Value);
Parameters: Value: Bitmask control value, of type unsigned 2.
Timing: 1 clock cycle.
Description:
Controls both LEDs simultaneously. Bit 0 of
Value controls
LED 0, and bit 1 controls LED 1.
5.5 Push button macros
To test whether the buttons on or off, you can either use RC200ButtonRead() and set
Index to 0 to test Button0 or to 1 to test Button1, or you can use one of the
RC200Button*Read()
macros to target a specific button. If you want to control both
buttons at once, use
RC200ButtonReadMask().
5.5.1 RC200ButtonRead()
extern macro expr RC200ButtonRead (Index);