- Name:
-
keyled
- Syntax:
-
KEYLED mask Mask - is a variable/constant which specifies the LEDs to use.
- Description:
-
This command is deprecated, please consider using the kbled command instead.
Set/clear the keyboard LEDs This command is used to control the LEDs on a computer keyboard (connected directly to the PICAXE - not the keyboard used whilst programming). The mask value sets the operation of the LEDs. Mask is used as follows:
| Bit 0 |
Scroll Lock (1=on, 0=off) |
| Bit 1 |
Num Lock (1=on, 0=off) |
| Bit 2 |
Caps Lock (1=on, 0=off) |
| Bit 3-6 |
Not Used |
| Bit 7 |
Disable Flash (1=no flash, 0=flash) |
On reset mask is set to 0, and so all three LEDs will flash when the 'keyin' command detects a new key hit. This provides the user with feedback that the key press has been detected by the PICAXE.
This flashing can be disabled by setting bit 7 of mask high. In this case the condition of the three LEDs can be manually controlled by setting/clearing bits 2-0.
Effect of Increased Clock Speed
This command will only function at 4MHz.