public final class I2CDisplay
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
I2CDisplay.HT16K33
enum HT16K33 defines the commanding and parameter options for the HOLTEK
HT16K33 chip.
|
Constructor and Description |
---|
I2CDisplay() |
Modifier and Type | Method and Description |
---|---|
static void |
displayClear(com.pi4j.io.i2c.I2CDevice adafruitFeather)
Clear the LED displayLED buffer--the four characters are blank
|
static com.pi4j.io.i2c.I2CDevice |
displayInit(Raspberry rpi,
I2CDisplay.HT16K33 blink,
I2CDisplay.HT16K33 brightness,
java.lang.String ledName)
displayInit: Turn on the HT16K33 chip, turn on the displayLED, set the blink
rate, and finally set displayLED brightness.
|
static void |
displayLED(com.pi4j.io.i2c.I2CDevice adafruitFeather,
java.lang.String displayString)
Display the passed four-character string on the LED Display
-- Adapted for my displays, a Lucky Light KW4-56NCWB
|
void |
displayOff(com.pi4j.io.i2c.I2CDevice adafruitFeather,
I2CDisplay.HT16K33 blink)
Turn off the LED displayLED.
|
static void |
displayOn(com.pi4j.io.i2c.I2CDevice adafruitFeather,
I2CDisplay.HT16K33 blink)
Turn on the LED displayLED
|
static void |
oscillatorOff(com.pi4j.io.i2c.I2CDevice adafruitFeather)
Turning off the oscillator has the effect of putting the HT16K33 into
standby mode.
|
static void |
oscillatorOn(com.pi4j.io.i2c.I2CDevice adafruitFeather)
Turning on the oscillator has the effect of taking the HT16K33 out of
standby mode.
|
static void |
setBlinkMode(com.pi4j.io.i2c.I2CDevice adafruitFeather,
I2CDisplay.HT16K33 blink)
Set the blink mode on the LED displayLED and turn the displayLED on.
|
static void |
setBrigtness(com.pi4j.io.i2c.I2CDevice adafruitFeather,
I2CDisplay.HT16K33 brightness)
Set the brightness level of the LED displayLED.
|
static void |
testLCD(Raspberry rpi,
java.lang.String led)
testLCD: this method test a LED display counting from 0 to 9 on every position
|
public static com.pi4j.io.i2c.I2CDevice displayInit(Raspberry rpi, I2CDisplay.HT16K33 blink, I2CDisplay.HT16K33 brightness, java.lang.String ledName)
rpi
- Object who represents the actual hardware.blink
- (HT16K33.BLINK_1HZ, HT16K33.BLINK_2HZ, BLINK_HALFHZ,
HT16K33.BLINK_OFF)brightness
- (HT16K33.DUTY_01 thru HT16K33.DUTY_16)ledName
- Name of the LED Displaypublic static void displayClear(com.pi4j.io.i2c.I2CDevice adafruitFeather)
adafruitFeather
- I2C Device who represent a Display controller.public static void displayOn(com.pi4j.io.i2c.I2CDevice adafruitFeather, I2CDisplay.HT16K33 blink)
adafruitFeather
- I2C Device who represent a Display controller.blink
- value.public void displayOff(com.pi4j.io.i2c.I2CDevice adafruitFeather, I2CDisplay.HT16K33 blink)
adafruitFeather
- I2C Device who represent a Display controller.blink
- Blink mode.public static void oscillatorOn(com.pi4j.io.i2c.I2CDevice adafruitFeather)
adafruitFeather
- I2C Device who represent a Display controller.public static void oscillatorOff(com.pi4j.io.i2c.I2CDevice adafruitFeather)
adafruitFeather
- I2C Device who represent a Display controller.public static void setBlinkMode(com.pi4j.io.i2c.I2CDevice adafruitFeather, I2CDisplay.HT16K33 blink)
adafruitFeather
- I2C Device who represent a Display controller.blink
- (HT16K33.BLINK_1HZ, HT16K33.BLINK_2HZ, BLINK_HALFHZ,
HT16K33.BLINK_OFF)public static void setBrigtness(com.pi4j.io.i2c.I2CDevice adafruitFeather, I2CDisplay.HT16K33 brightness)
adafruitFeather
- I2C Device who represent a Display controller.brightness
- (HT16K33.DUTY_01 thru HT16K33.DUTY_16)public static void displayLED(com.pi4j.io.i2c.I2CDevice adafruitFeather, java.lang.String displayString)
adafruitFeather
- I2C Device who represent a Display controller.displayString
- - must be a 4 character string.public static void testLCD(Raspberry rpi, java.lang.String led)
rpi
- Object who represents the actual hardware.led
- String with the name of the led display to test.