User`s manual

Table Of Contents
5
5
Chapter 5 Programming Examples
The following examples are designed to ease application development on the UC-7400-CE
computer. Find and copy useful code segments to your C/C++ programs. In addition, to simplify
application development with the eVC4.0 tool, we provide you with a device library (mxdev.lib).
This library covers the APIs for the buzzer, LCM, function key, and digital I/O devices. To link
the library with your eVC4.0 compilation environment, perform the following steps from your
eVC4.0 environment:
y From the main tool bar, choose Project Æ Settings.
y From Project Settings, select the Link tab.
y Append “mxdev.lib” to the text field “Object/Library Modules:”.
y Click OK
Before you compile your application, please make sure that the header file and the library file in
the SDK directories are as shown. If any of them is not in the specified directory, find it on the
package CD and copy it to the specified directory.
“C:\Program Files\Windows CE Tools\wce500\UC7420CE1.0\Include\Armv4i\moxa\devices.h
“C:\Program Files\Windows CE Tools\wce500\UC7420CE1.0\lib\Armv4i\mxdev.lib“
There are 5 code samples in this chapter and cover:
Example #1MOXA UART Supporting RS-232/422/485
Example #2Buzzer
Example #3Digital I/O
Example #4LCM Display
Example #5Function Keys