MP200 - Book 1 - Getting Started - v1.0
MP200 - Book 1 - Getting Started - v1.0
MP200 - Book 1 - Getting Started - v1.0
Book 1
Getting Started
Confidential
Version1.0
Feb 2015
1. Introduction .................................................................................................................... 5
1.1. Castles DVS SDK ................................................................................................... 5
1.2. What You Need ...................................................................................................... 5
2. Installation...................................................................................................................... 6
3. Building Your First Application ....................................................................................... 9
4. Loading Application To MP200 Mobile Pinpad ............................................................. 15
4.1. Signing Application ............................................................................................... 16
4.2. Download Application To MP200 Mobile Pinpad ................................................... 19
4.3. Execute Application On MP200 Mobile Pinpad ..................................................... 21
5. Console Debug ............................................................................................................ 22
This document is target for software engineers, who are new to the Castles development
environment.
In the following chapters, the document will guide you step by steps from setting up the
SDK till running your first application on Castles MP200 mobile pinpad.
If “Create a desktop icon” is selected, you will see one icon shown as below in your
desktop.
After successfully compiling your source code, you will find the output binary code file at
[Project folder] -> [dist] -> [MP200] -> [App].
MP200App_HelloWorld
[Project folder]
dist
MP200
App
MP200App_HelloWorld
[Binary code]
Note: The binary code file needs a signing process before being downloaded into MP200.
The application binary code file must be signed before being downloaded into
MP200 mobile pinpad. The signing process will convert the binary code file into
CAP file. CAP file format is defined by Castles to ensure the application data and
codes confidentiality and integrity.
ii
iii
v iv
iv
vii vi v
After the signing process, the CAP Generator will generate two files for
downloading, mci file and CAP files. The mci file is the list of CAP files.
MP200App_HelloWorld
[Project folder]
dist
MP200
output
App.mci
App.CAP
Steps:
i. Execute ULD Download Utility, located in C:\Program
Files\Castles\MP200\tools\Loader for MP200 mobile pinpad.
ii. Select Com Port.
iii. Select file (mci).
iv. Terminal enter download mode.
Press button [0] in Program Manager (PM).
Press button [1] to select “1. Download AP“.
Press button [1] again to select download via USB.
v. Start download.
v ii iii
Note: To download using USB cable, terminal must enable CDC mode.
[PM] →0[System Menu] → [4. Sys Settings] → [USB CDC Mode:] → [Y]
Program Manager
----------------01/01
1. 1.MP200App_HelloWorld
ENTER:Run
Loading AP......
Please wait.....
Note: To automatically run the application after MP200 mobile pinpad power on,
select AP in Program Manager, press [1] button to enable “Default Select”. To
stop the default application execution, keeping pressed and released [X] button
during “System Initializing” until enter Program Manager.
Console debug is a very useful tool during application development. It’s used to dump
messages out from MP200 mobile pinpad in real time. The messages are dumped
through USB and can be captured by console application like Hyper Terminal, TeraTerm
or Putty.
SYS SETTINGS Specify the serial port for output debug message.
Debug Mode :N
Debug Port :U Press[OK] followed by [3], the Debug Port can be
Mobile AutoON :Y set to be USB port.
Bklit Auto Off :N
Bklit Off Time :X Press [X] button to return, and can start to debug
PWR KEY OFF :Y while running AP.
1: Prev 2: Next
~ END ~