You are on page 1of 10

TelePower SDK

--Development Guide for Linux

Release Date Author Modification
2013-08-17 Mai Yongqi irst Release
1 Summary
1.1 Introduction
!his article is for !"#300 financial "$# ter%inal #D& 'ased de(elo)%ent guide*
1.2 History
Date Version Remark
2013-08-17 1*0 irst release

2 Development Environment
+,M a'o(e ra%- 200M a(aila'le hard dri(e s)ace
.indo/s2000 and a'o(e $#
Compiler ar%-'rc%-linu0-gnuea'i-gcc
API Header !" #D& Headers
API library li't)sd1*a
1 5asically /e edit source code on .indo/s syste%- co%)ile in 6inu0 syste%* or this
reason- /e reco%%ended de(elo)er to use 7irtual %achine /ith a .indo/s host 8 6inu0 guest*
5elo/ /e /ill ta1e .indo/s 9" 8 :'untu 10*0, as e0a%)le*
2"$# ter%inal connect /ith .indo/s "; 'y <thernet- )lease %a1e sure they are in the sa%e
6A3* 6inu0 7M connects /ith .indo/s 'y using 3A! =Default connection setting in 7M>*
?enerally s)ea1ing /e only need to u)grade se(eral file in the syste% in %ost cases- in those case
/e don@t need to use <thernet- Aust serial )ort is enough*
3 Compiler Setup
.e use Bar%-'rc%-linu0-gnuea'i-gccC co%)ile tool-chains- it /ill 'een )ro(ide /ith the #D&*
"lease follo/ 'elo/ instructions to setu) the co%)iler*

Step 1" Extra t#e $ompiler pa$ka%e to a folder
or e0a%)le- first /e co)y the B'rc%-ar%tools-322'it2%od*tar*'DC to
B8ho%e8tel)o85;ME8F2C- then /e run 'elo/ co%%ands4
cd 8ho%e8tel)o85;ME8F2
tar G0A(f 'rc%-ar%tools-322'it2%od*tar*'D2

Step 2" Confi%ure environment varia&le
Run sudo (i 8etc8en(iron%ent to o)en en(iron%ent for editing* A))end 'elo/ )ath
Run Bcat 8etc8en(iron%ent C to chec1 the result- if you :'untu is a fresh one- you should get
the result as sa%e as the follo/ed one4

Step 3" Re&oot Linux system

Step '" C#e$k if t#e installation (as su$$ess
$)en !er%inal /indo/- ty)e Bar%-'rc%-linu0-gnuea'i-gccC- then )ress <nter to run the
Jf you get Bco%%and not foundC- this %eans the installation is failed* "lease chec1 the file
/as e0tracted successfully* !hen chec1 the en(iron%ent (aria'le is correct or not*
Jf you get Bno in)ut filesC this %eans the installation is success* !his error sho/s 'ecause /e
didn@t gi(e it an source file to co%)ile*
' )uild *ro+e$t
Here /e )ro(ide a de%o to sho/ ho/ to 'uild a )roAect*
=1> ;hange directory to BDe%o2"roAectC*
=2> .rite code /ith /hat you need=Here /e ha(e )ro(ide the code of de%o>*
=3> .rite %a1e file=Here /e ha(e )ro(ide the %a1efile in directory BDe%o2"roAect8'uildC>*
=,> <0ecute the %a1efile*
=E> inish* Jn this de%o- a)) is under the directory BDe%o2"roAect8'uild8i%age8a))C
, )urnin% -pp
5.1 How to Sign to the Application
:nless 'e signed- a))lication could not run in this %achine* "lease follo/ the ste)s 'elo/ for
a))lication signature*
.irst/ %odify A))Msg*t0t according to /hat you need* "lease note that the a))lication na%e in
file A))Msg*t0t could 'e changed* Jt is suggested that the length of the a))lication na%e should 'e
the sa%e as the e0a%)le*
or e0a%)le- the a))lication na%e is 332+de%o- so the content of A))Msg*t0t is sho/n as 'elo/4
332+de%o 332+de%o 1*0 7ie/A! 1 7"$#30+-#A""
Se$ond/ sign to the a))lication* After co%)iling the a))lication- use the co%%and 'elo/ to sign*
eg4 cat A))Msg*t0t KK 332+de%o
After these ste)s- the signature is done*
5.2 How o !oad Application into PS"##
1! Conne$t t#e *C and 0*S311
:sing the loading ca'le to connect the "$# to ";
2! Enter Do(nload 2nterfa$e
"o/er on the de(ice- it /ill enter do/nload interface*
3! Run load tools
Running the LoadTools.exe;
Viewing application information of terminal. ;onnecting the loading 6ine 'et/een "; and
!"#300* ;lic1 the 3Reflus#4 5utton to (ie/ all a))lication files in !"#300*

'! Load appli$ation
Select the APP file : *****.bin;
Click button Start and Load the application into PS!"".
5." How o !oad $ont%Parameters $ile into
he #tep i# the #ame with downloading application$ %u#t #elect the different file.
5.& How o 'rite S( Into PS"##
As the )icture u)side- select chec1 'o0 B#3C and in)ut the #3- and the de(ice in the do/nload
interface- then clic1 start to do/nload #3 into de(ice*
5.5 How o )ebuild $ile System *+ PS"##
As the )icture u)side- select chec1 'o0 B;reate file syste%C- and the de(ice in the do/nload
interface- then clic1 start to re'uild file syste% of de(ice*
5 6ote
5efore use- )lease chec1 if all the %aterial is )re)ared*
7 *rodu$t 2ntrodu$tion
Jt is a %o'ile transaction ter%inal /ith 'uild-in ther%al )rinter and 'attery* Jt su))orts )rocesses
of %oney transfer- airti%e to)-u)- 'ill )ay%ent- tic1et 'oo1ing- online food ordering -lotteries and
<-sho))ing* Due to its all-in-one design- !"#300 can hel) %erchant e0)and the )oint of sale-
enhance ser(ice and increase re(enue quic1ly*