Appendix d: programming the lcm, Appendix d, Programming the lcm – Lanner FW-7610 User Manual
Page 41
38
Programming the LCM
Appendix D
Network Application Platforms
Appendix D:
Programming the LCM
The LCD panel module (LCM) is designed to provide real-
time operating status and configuration information for
the system. For sample LCM code, see LCM foler in the
Driver and Manual CD. The driver and the program library
can also be found in the folder.
The system supports the following kind of LCM:
Parallel Text-based LCM: The LCM connects to the
•
motherboard’s parallel port. The LCD screen can
display 2 lines, 16 (or 20) characters per line.
For Parallel Text-based LCM
Build
To build program source code on Linux platform, use the
following steps as a guideline:
Copy the proper makefile from the Driver and Manual
1.
CD to your system: Makefile.linux
Type make to build source code:
2.
make Makefile (Note: omit the file extensions)
After compiled, the executable programs
(plcm_test,
plcm_cursor_char, Test) and the driver (plcm_drv.ko or
plcm_drv.o) will appear in the program’s folder.
Note: The OS supported by Lanner Bypass
function include platforms based on Linux Kernel
series 2.4.x and Linux Kernel series 2.6.x.
Install
Install the driver and create a node in the /dev directory
by:
#insmod plcm_drv.ko
#mknod /dev/plcm_drv c 241 0
Note: If you cannot install the driver, check
whether you have enabled the parallel port in the
BIOS setting .
Execution
This section contains sample executable programs that
you could test on your platform. It demonstrates some
useful functionality that the LCM provides.
To execute, type:
#./plcm_test
Plcm_cursor_char. This program provides a menu to
demonstrate the following functions:
Insert line (set the starting line to either line 1 or line 2)
Move Cursor right (select to move the cursor to the
right)
Move Cursor Left (select to move the cursor to the left)
Add a char (select to display a character on the LCM
screen)
Clear (select to clear the LCM display)
Leave (select to leave the program)
To execute, type:
#./ plcm_cursor_char
Note: For descriptions of the command, refer to
the Readme file contained within the program’s
folder.