User Tools

Site Tools

한국어

cubloc:about_clcd_module:index

CLCD Module

CLCD is Serial LCD display module with I2c/RS232C interface.

On the back of the CLCD, a control board is attached. This control board receives I2C(CuNet) signals and prints to the CLCD.

The CLCD can also communicate using RS-232. There are two RS-232 connectors, one for 3-pin 5V level signals and the other for 4-pin +/- 12V level signals.

Use the CLCD DIP switches to set the I2C slave address. The 4th DIP switch is not used.

CuNET and RS-232 communication can both be used. If both are connected, please make sure when one of them is processing, the other is not.

The following is the CLCD command table:

Command Example(hex)BytesExecution TimeExplanation
ESC 'C' 1B 43 2 15mS Clear screen. A 15ms delay must be executed after this command.
ESC 'S' 1B 53 2 Cursor On (Default)
ESC 's' 1B 73 2 Cursor Off
ESC 'B' 1B 42 2 Backlight On (Default)
ESC 'b' 1B 62 2 Backlight Off
ESC 'H' 1B 48 2 Locate 0,0
ESC 'L' X Y 1B 4C xx yy 4 100 uS Change the position of the cursor.
ESC 'D' 8byte 1B 44 Code 8 bytes 11 Character codes 8 through 15 are 8 custom characters that the user is free to create and use.
1 01 1 Move to beginning of row 1
2 02 1 Move to beginning of row 2
3 03 1 Move to beginning of row 3
4 04 1 Move to beginning of row 4

data received is not a command, the CLCD will display it on the screen.

When using RS-232, the maximum baud rate settings for 12V(4-pin) levels is 38400. For TTL 5V levels (3-pin), a baud rate up to 115200 can be used.

CLCD with I2C

The following is an example of code using the CB280 to connect to a CLCD module using the CUNET(I2C) protocol. When you execute this program, the CLCD will display incrementing numbers.

Const Device = CB280
Set Display 2,0,1,50          ' Set the SLAVE ADDRESS to 1 by manipulating the DIP switch.
Dim i As Integer
Delay 100                     ' Delay for start up of CLCD
Cls
Delay 200                     ' Delay for initializing and clearing CLCD
CsrOff
Locate 5,2
Print "Start!!!"
Delay 500
Cls
Delay 100
Do
   Incr i
   Locate 0,0
   Print "COMFILE"
   Locate 1,3
   Print "CUBLOC ", Dec i
   Delay 100
Loop
  • The slave address specified in the Set Display command should match that of the CLCD .

CLCD with RS232C

The following is an example code when using the CB220 to connect to the CLCD module through RS232 protocol. When you execute this program, the CLCD will display increment of numbers.

The baud rate of CLCD and SET DISPLAY command should match. Otherwise you will get garbage values on the LCD when trying to print to it.

Const Device = CB220
'Make sure to set all the DIP switches on
'the back of the CLCD to ON
‘Connect P11 (TX) of CB220 to RX pin of the CLCD.
'Set Display to CLCD/CVFD, 115200 bps, and 128 bytes of buffer
Set Display 2,1,115200,128
Dim ct As Long
ct=0
Do
  Locate 0,0
  Print Dec ct
  Incr ct
Loop 
  • Make sure GND is shared among the power supply for the display and the CB220, otherwise you will get garbage values on the LCD.
  • The internal regulator of CB220 does not have enough power to supply both the CB220 and the LCD module, so you will need a separate power supply or regulator to power the LCD.
cubloc/about_clcd_module/index.txt · Last modified: 2020/09/14 08:51 by COMFILE Technology