PhidgetTextLCD

PhidgetTextLCD

A class for controlling a PhidgetTextLCD.  See your product manual for more specific API details, supported functionality, units, etc.

Summary
PhidgetTextLCDA class for controlling a PhidgetTextLCD.
Constants
Screen SizesThese are the Screen sizes supported by the various PhidgetTextLCDs.
Properties
ScreenCountGets the number of screens available on the LCD.
RowCountGets the number of rows available on the LCD.
ColumnCountGets the number of columns available per row on the LCD.
BacklightGets tha state of the backlight.
CursorGets the visible state of the cursor.
CursorBlinkGets the blinking state of the cursor.
ContrastGets the last set contrast value.
BrightnessGets the last set brightness value.
ScreenSizeGets the screen size.
ScreenGets the active screen.
BacklightSets the backlight state.
CursorSets the cursor (visible) state.
CursorBlinkSets the cursor blink state.
ContrastSets the contrast (0-255).
BrightnessSets the brightness of the backlight (0-255).
ScreenSizeSets the screen size.
ScreenSets the active screen.
Functions
setDisplayStringSets the display string for a row.
setDisplayCharacterSets the character at a row and column.
setCustomCharacterCreates a custom character.
initializeInitializes a screen.

Constants

Screen Sizes

These are the Screen sizes supported by the various PhidgetTextLCDs.  These constants are used with <getScreenSize> and <setScreenSize>.

PHIDGET_TEXTLCD_SCREEN_NONEno screen attached
PHIDGET_TEXTLCD_SCREEN_1x81 row, 8 column screen
PHIDGET_TEXTLCD_SCREEN_2x82 row, 8 column screen
PHIDGET_TEXTLCD_SCREEN_1x161 row, 16 column screen
PHIDGET_TEXTLCD_SCREEN_2x162 row, 16 column screen
PHIDGET_TEXTLCD_SCREEN_4x164 row, 16 column screen
PHIDGET_TEXTLCD_SCREEN_2x202 row, 20 column screen
PHIDGET_TEXTLCD_SCREEN_4x204 row, 20 column screen
PHIDGET_TEXTLCD_SCREEN_2x242 row, 24 column screen
PHIDGET_TEXTLCD_SCREEN_1x401 row, 40 column screen
PHIDGET_TEXTLCD_SCREEN_2x402 row, 40 column screen
PHIDGET_TEXTLCD_SCREEN_4x404 row, 40 column screen (special case, requires both screen connections)
PHIDGET_TEXTLCD_SCREEN_UNKNOWNScreen size is unknown

Properties

ScreenCount

public function get ScreenCount():int

Gets the number of screens available on the LCD.

RowCount

public function get RowCount():int

Gets the number of rows available on the LCD.

ColumnCount

public function get ColumnCount():int

Gets the number of columns available per row on the LCD.

Backlight

public function get Backlight():Boolean

Gets tha state of the backlight.

Cursor

public function get Cursor():Boolean

Gets the visible state of the cursor.

CursorBlink

public function get CursorBlink():Boolean

Gets the blinking state of the cursor.

Contrast

public function get Contrast():int

Gets the last set contrast value.

Brightness

public function get Brightness():int

Gets the last set brightness value.

ScreenSize

public function get ScreenSize():int

Gets the screen size.

Screen

public function get Screen():int

Gets the active screen.  This is the screen that will respond to all commands.

Backlight

public function set Backlight(val: Boolean):void

Sets the backlight state.

Parameters

valbacklight state

Cursor

public function set Cursor(val: Boolean):void

Sets the cursor (visible) state.

Parameters

valcursor state

CursorBlink

public function set CursorBlink(val: Boolean):void

Sets the cursor blink state.

Parameters

valcursor blink state

Contrast

public function set Contrast(val: int):void

Sets the contrast (0-255).

Parameters

valcontrast

Brightness

public function set Brightness(val: int):void

Sets the brightness of the backlight (0-255).

Parameters

valbrightness

ScreenSize

public function set ScreenSize(val: int):void

Sets the screen size.  Choose from one of the defined screen size constants.  Note that not all PhidgetTextLCDs support setting screen size.

Parameters

valscreen size

Screen

public function set Screen(val: int):void

Sets the active screen.  This is the screen that subsequent commands will target.

Parameters

valscreen

Functions

setDisplayString

public function setDisplayString(index: int,
val: String):void

Sets the display string for a row.

Parameters

indexrow
valdisplay string

setDisplayCharacter

public function setDisplayCharacter(row: int,
column: int,
val: String):void

Sets the character at a row and column.  Send a one character string.

Parameters

rowrow
columncolumn
valcharacter

setCustomCharacter

public function setCustomCharacter(index: int,
val1: int,
val2: int):void

Creates a custom character.  See the product manual for more information.

Parameters

indexcharacter index (8-15)
val1character data 1
val2character data 2

initialize

public function initialize():void

Initializes a screen.  This should be called after setting the screen size.

Base Phidget class from which all specific device classes inherit.
public function get ScreenCount():int
Gets the number of screens available on the LCD.
public function get RowCount():int
Gets the number of rows available on the LCD.
public function get ColumnCount():int
Gets the number of columns available per row on the LCD.
public function get Backlight():Boolean
Gets tha state of the backlight.
public function get Cursor():Boolean
Gets the visible state of the cursor.
public function get CursorBlink():Boolean
Gets the blinking state of the cursor.
public function get Contrast():int
Gets the last set contrast value.
public function get Brightness():int
Gets the last set brightness value.
public function get ScreenSize():int
Gets the screen size.
public function get Screen():int
Gets the active screen.
public function setDisplayString(index: int,
val: String):void
Sets the display string for a row.
public function setDisplayCharacter(row: int,
column: int,
val: String):void
Sets the character at a row and column.
public function setCustomCharacter(index: int,
val1: int,
val2: int):void
Creates a custom character.
public function initialize():void
Initializes a screen.
Close