java.lang.Object | |
↳ | com.datalogic.extension.selfshopping.led.SelfshoppingLedManager |
The LED Manager used in the Selfshopping Extension SDK. It allows to
command the different LEDs available on the device, using specific
APIs dependent on the type of LED in use.
The currently available types of LED are the standard Led
,
that can blink or be turned ON/OFF, and the DimmingLed
,
in which is also possible to set the brightness and start a
dimming sequence.
It is also possible to command the LEDs through specific
LedAction
objects.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | EVENT_ID_BATTERY_CHARGING | ID for the battery charging event. | |||||||||
int | EVENT_ID_BOOT_ANIMATION | ID for the boot animation event. | |||||||||
int | EVENT_ID_END_OF_CHARGE | ID for the end of charge event. | |||||||||
int | EVENT_ID_SHUTDOWN | ID for the shutdown event. | |||||||||
int | LED_ID_BOTTOM | ID of the bottom LED. | |||||||||
int | LED_ID_LEFT | ID of the left LED. | |||||||||
int | LED_ID_LEFT_AND_RIGHT | ID of the left and right LEDs. | |||||||||
int | LED_ID_LEFT_AND_RIGHT_ALTERNATE | ID of the left and right alternative LEDs. | |||||||||
int | LED_ID_RIGHT | ID of the right LED. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Acquires a LED given its ID and the current application context.
| |||||||||||
Applies a
LedAction , corresponding to a method
invocation on a specific LED. | |||||||||||
Returns a list of all available LED events, being them predefined or
created by applications.
| |||||||||||
Returns a list of all available LEDs on this device.
| |||||||||||
Returns an instance of the
SelfshoppingLedManager . | |||||||||||
Retrieves a LED given its ID.
| |||||||||||
Retrieves a LED event given its ID.
| |||||||||||
Releases a previously acquired LED by specifying its id and the
current application context.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
ID for the battery charging event.
ID for the boot animation event.
ID for the end of charge event.
ID for the shutdown event.
ID of the bottom LED.
ID of the left LED.
ID of the left and right LEDs. In this configuration the two LEDs will be commanded simultaneously.
ID of the left and right alternative LEDs. In this configuration only one of the two LEDs will be on while blinking and they will alternate.
ID of the right LED.
Acquires a LED given its ID and the current application context.
The LED acquired will be locked and cannot be controlled by other
applications or by LED events. The method will return
null
in case the ID is not correct or the LED is
already used by another application or a LED event.
id | The ID of the LED to retrieve. |
---|---|
context | The application context. |
Led
instance associated with this ID if it
exists and is not in use, null
otherwise.
Returns a list of all available LED events, being them predefined or created by applications.
Returns a list of all available LEDs on this device.
Returns an instance of the SelfshoppingLedManager
.
Retrieves a LED given its ID. This method always returns the given LED if the ID is correct, however any control on the LED is not guaranteed to work if the LED is already used for other operations, such as running LED events.
id | The ID of the LED to retrieve. |
---|
Led
instance associated with this ID if it
exists, null
otherwise.
Retrieves a LED event given its ID.
id | The ID of the LED event to retrieve. |
---|
LedEvent
instance associated with this ID if it exists,
null
otherwise.
Releases a previously acquired LED by specifying its id and the current application context.
id | The ID of the LED to retrieve. |
---|---|
context | The application context. |