This class controls the status LEDs.
See class VIB::Led in the VisionBox Interface Library for a detailed description.
- Examples
-
|
void | ConfigureGenerator (UInt32 GeneratorIndex, UInt32 BlinkCount, UInt32 ms_ton, UInt32 ms_toff, UInt32 ms_tpause) |
| Configures the LED signal generator. More...
|
|
| Led () |
| Default constructor for the device object More...
|
|
void | Reset () |
| Resets the device to default settings. More...
|
|
void | Set (UInt32 Val, UInt32 BitMask) |
| Sets the state of the LEDs. More...
|
|
void | SetLED (UInt32 LEDIndex, Boolean OnOff) |
| Sets the state of one LED. More...
|
|
void | SetMode (UInt32 LEDIndex, eLED_MODE Mode) |
| Sets the mode of one LED. More...
|
|
void | Close () |
| Closes a device More...
|
|
bool | isOpen () |
| Returns the open state of a device object More...
|
|
void | Open () |
| Opens a device More...
|
|
void | Open (unsigned int Index) |
| Opens a device More...
|
|
◆ eLED_MODE
LED mode definitions
The mode is used with SetMode() to specify the source signal for the LED.
Enumerator |
---|
OFF | LED off.
|
ON | LED on.
|
GEN0 | LED Signal generator 0.
|
GEN1 | LED Signal generator 1.
|
RESET | Reset.
|
SATA | SATA activity.
|
CF | CF (IDE) activity.
|
SATA_CF | SATA or CF activity.
|
PCI | PCI bus activity
|
SUN | Internal RTCC bus activity.
|
RS232 | RS-232 activity.
|
RS422 | RS-422 activity.
|
◆ Led()
Default constructor for the device object
The device must be opened with Open() before it can be used.
◆ ConfigureGenerator()
void VIB_NET::Led::ConfigureGenerator |
( |
UInt32 |
GeneratorIndex, |
|
|
UInt32 |
BlinkCount, |
|
|
UInt32 |
ms_ton, |
|
|
UInt32 |
ms_toff, |
|
|
UInt32 |
ms_tpause |
|
) |
| |
Configures the LED signal generator.
Two signal generators can be used to create a periodic sequence of pulsed. The LED on time, off time and the pause time between each sequence can be adjusted. The resolution is a multiple of 100 ms.
In order to use a generator, SetMode() has to be called with eLED_MODE::GEN0 / eLED_MODE::GEN1.
- Parameters
-
GeneratorIndex | Generator index, 0 or 1 |
BlinkCount | Number of pulses for each sequence, 1 ... 16 |
ms_ton | LED on time in milliseconds, 100 ... 6400 |
ms_toff | LED off time in milliseconds, 100 ... 6400 |
ms_tpause | Pause time in milliseconds, 0 ... 6400 |
- Example:
- C#: Led_Example.cs
Visual Basic: Led_Example.vb
◆ Reset()
void VIB_NET::Led::Reset |
( |
| ) |
|
◆ Set()
void VIB_NET::Led::Set |
( |
UInt32 |
Val, |
|
|
UInt32 |
BitMask |
|
) |
| |
Sets the state of the LEDs.
- Parameters
-
Val | Binary representation of the LEDs. The actual number of available LEDs is hardware dependent. |
BitMask | Mask bits can be used to change only certain outputs, LSB is LED0 |
- Example:
- C#: Led_Example.cs
Visual Basic: Led_Example.vb
◆ SetLED()
void VIB_NET::Led::SetLED |
( |
UInt32 |
LEDIndex, |
|
|
Boolean |
OnOff |
|
) |
| |
◆ SetMode()
void VIB_NET::Led::SetMode |
( |
UInt32 |
LEDIndex, |
|
|
eLED_MODE |
Mode |
|
) |
| |
◆ NumberOfLEDs
VIB_NET::Led::NumberOfLEDs |
|
get |
Holds number of LEDs.
Mostly the LEDs are physical implemented as dual color LEDs.
A function result of two indicates one LED with green and red light.
- Example:
- C#: Led_Example.cs
Visual Basic: Led_Example.vb
◆ Type
Returns the device type for the current instance, see eDEVICE_TYPE