STK 2148 LabManualV1.0

Share Embed Donate


Short Description

STK 2148 LabManualV1.0...

Description

STK-2148 Lab Manual 

STK-2148 Embedded Lab Manual

SPJ Embedded Technologies Pvt. Ltd. Survey No. 124/12 A, Mulik Baug, Near MIT College, Off Paud Road, o!"rud. Pu#e $ 411%&' (IN)IA* Tel. +1-2%-22&%%2 +1-2%-22&%%2 a0. +1-2%-22&%%& +1-2%-22&%%& "!!//333.5y!e6.7o6

 SPJETPL  ©  SPJETPL

All Rights Reserved. (www.spjsystems.com ( www.spjsystems.com))

Page 1 of 8%

STK-2148 Lab Manual 

!S"L#!ME$  Embedded Lab Manual %o& #$M'TM! and othe& documentation(

T"i 6a#ual a#d !"e a77o6a#yi#g do7u6e#!a!io# u7" a 7"e6a!i7 diagra6 $ i# of! or "ard for6 -7o#!ai# de7ri!io# of 7oyrig"!ed rodu7!, 3"i7" are #o! e0li7i!ly i#di7a!ed a u7". T"e a9e#7e of !rade6ark y69ol doe #o! i#fer !"a! a Produ7! i #o! ro!e7!ed. Addi!io#ally, regi!ered a!e#! a#d !rade6ark are i6ilarly #o! e0rely i#di7a!ed i# !"ee do7u6e#!. T"e i#for6a!io# i# !"ee do7u6e#! "a 9ee# 7arefully 7"e7ked a#d i 9elieved 9 elieved !o 9e e#!irely relia9le. :o3ever, SPJ Embedded Technologies Pvt. Ltd. ("e#7efor!" ;"om)an*0eri6e#!...........................................................................................................................................&1 .1 @ri!e ae69ly la#guage rogra6 for ari!"6e!i7 oera!io# (addi!io#, u9!ra7!io#, 6ul!ili7a!io# a#d diviio#*..........................................................................................................................................&1 .2 @ri!e a rogra6 for )igi!al Ou!u!.................................................................................................&2 .& @ri!e a rogra6 for )igi!al I#u!....................................................................................................&& .4 @ri!e a rogra6 for Buer I#!erfa7e..............................................................................................&4 .8 @ri!e a rogra6 for Relay I#!erfa7e................................................................................................&8 . @ri!e a rogra6 for S!eer Mo!or I#!erfa7e..................................................................................& . I#!erfa7i#g of 102 Te0! HC).........................................................................................................& .' @ri!e a rogra6 for Serial Co66u#i7a!io# ui#g JART%.............................................................&' . @ri!e a rogra6 for 4L4 Ma!ri0 eyad I#!erfa7e..........................................................................& .1% @ri!e a rogra6 for o#-7"i A#alog !o )igi!al Co#verio#..........................................................4% .11 @ri!e a rogra6 for HM&8 Te6era!ure Se#or I#!erfa7e............................................................41 .12 e#era!io# of Ra6 3ave ui#g o#-7"i )AC.............................................................................42 .1& @ri!e a rogra6 for I2C 9aed Seve# Seg6e#! H>) )ilay I#!erfa7e.......................................4& .14 @ri!e a rogra6 for I2C 9aed >>PROM I#!erfa7e......................................................................44 .18 @ri!e a rogra6 for I2C 9aed RTC I#!erfa7e..............................................................................48 .1 @ri!e a rogra6 for SPI 9aed >>PROM I#!erfa7e......................................................................4 .1 @ri!e a rogra6 for >0!er#al I#!erru!..........................................................................................4 .1' @ri!e a rogra6 for 12'04 ra"i7 HC) I#!erfa7e...................................................................4' '. >0eri6e#! 9aed o# FC/OS-II RTOS.................................................................................................4

 SPJETPL  ©  SPJETPL

All Rights Reserved. (www.spjsystems.com ( www.spjsystems.com))

Page 4 of 8%

STK-2148 Lab Manual 

'.1 I6le6e#! Mul!i!aki#g 3i!" T3o eara!e H>) 9li#ki#g !ak....................................................4 '.2 I6le6e#! Priori!y S7"eduli#g a#d OS Ti6e )elay u#7!io# 9y 3ri!i#g & differe#! JART Tra#6i!!i#g Tak................................................................................................................................8%

 SPJETPL  ©  SPJETPL

All Rights Reserved. (www.spjsystems.com ( www.spjsystems.com))

Page 8 of 8%

STK-2148 Lab Manual 

1. !nt&oduction T"i i uerE 6a#ual for STK-2148  Trai#er i! 9aed o# HPC214' 6i7ro-7o#!roller. T"i !rai#er 9oard i deig#ed !o erfor6 la9 ra7!i7al a#d "a a fa7ili!y !o do3#load !"e uer rogra6 i#!o !"e o#-7"i fla" 6e6ory of !"e 6i7ro-7o#!roller. I! i !ro#gly re7o66e#ded !o read !"i 6a#ual 7arefully 9efore you !ar! ui#g !"e STK-2148  9oard.

"#+T!, T"i 9oard 7o#!ai# 7o6o#e#! !"a! are e#i!ive !o >le7!ro-S!a!i7 )i7"arge (>S)*. T"e

 9oard 6u! 9e "a#dled 7arefully, o a #o! !o u95e7! i! !o >S). A far a oi9le, do #o! !ou7" a#y 7o#du7!i#g ar! o# !"e 9oard - i#7ludi#g a#y 7o6o#e#! or 7o##e7!or i# - a !"i 6ay da6age ar! of !"e  9oard er6a#e#!ly. If you 3a#! !o !ou7" a#y of !"e ar!, 6ake ure !o di7"arge yourelf !o ear!". Par! da6aged due !o >S) are #o! 7overed u#der li6i!ed 3arra#!y.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page  of 8%

STK-2148 Lab Manual 

2. etting Sta&ted 2.1 S"#$M !nstallation( A a ar! of !"e SCARM of!3are a7kage, you "ould "ave re7eived a C). Pleae i#er! i! i#!o

1.

!"e C)-ROM drive. Oe# SPJTools (C) drive*, oe# !"e folder S"#$M a#d ru# !"e SET+P.E/E 2.

If i! "o3 a#y error !"e# 7li7k Ig#ore.

3.

S"#$M Setu) 3i#do3 3ill oe#, 7li7k E/T.

4.

A77e! !"e of!3are li7e#e agree6e#! 9y 7li7ki#g 0ES.

5.

C"ooe de!i#a!io# lo7a!io# 3"ere you 3a#! !o i#!all !"e SCARM a#d 7li7k E/T.

6.

Cli7k E/T 9u!!o# a#d i#!alla!io# 3ill !ar!.

7.

Cli7k !!S 9u!!o# !o 7o6le!e !"e I#!alla!io#.

8.

 No3 7o##e7! !"e S"#$M SPJ Loc3  !o +S )o&t o% the com)ute& .

9.

A o-u 3ill "o3 5ound e6 a&d6a&e7

10.

ound e6 a&d6a&e i9a&d  3i#do3 3ill 9e oe#. Sele7! o, not this time  o!io# a#d 7li7k

o# e:t. 11. No3 12.

 Bro3e for !"e folder d&v fro6 "(=S"#$M=d&v a#d 7li7k e:t.

13. No3 14.

ele7! !nstall %&om a list o& s)eci%ic location ;#dvanced< a#d 7li7k e:t.

a&d6a&e !nstallation 6indo6  3ill oe#, 7li7k "ontinue #n*6a* .

Af!er 7o6le!io# of i#!alla!io#, a 6eage 3ill 7o6e The 6i9a&d has %inished installing the so%t6a&e %o& SPJ Loc3 , #o3 7li7k o# inish.

15.

Agai# you 3ill ee 5ound e6 a&d6a&e7  3i#do3, !"erefore reea! !"e a6e ro7edure fro6 !e #o..

16.

Af!er !"i you 7a# !ar! ui#g S"#$M ; Start > All Programs > SPJ-SCARM > SIDE_ARM "<  a#d Te&minal Emulation +tilit* ;SPJTe&m< . T"i do7u6e#! de7ri9e !e !o 7rea!e

ARM ali7a!io# i# DCE ui#g !"e SCARM.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page  of 8%

STK-2148 Lab Manual 

#bout 5P&o?ect7( @"a! i a ro5e7! A ro5e7! i a file i# 3"i7" SI)>ARM !ore all i#for6a!io# rela!ed !o a# ali7a!io#. >.g. i! !ore !"e #a6e of DCE a#d/or Ae69ler our7e file, 6e6ory ie !o 9e ued a#d o!"er o!io# for 7o6iler, ae69ler a#d li#ker. ,)ening a )&o?ect(

To oe# a# e0i!i#g ro5e7! file, ele7! P&o?ect @ ,)en P&o?ect fro6 !"e 6e#u. "&eating a ne6 )&o?ect(

To 7rea!e a #e3 ro5e7!, ele7! P&o?ect @ e6 P&o?ect fro6 !"e 6e#u. "hanging )&o?ect settings(

To 7"a#ge !"e ro5e7! e!!i#g (u7" a addi#g or re6ovi#g DCE a#d/or Ae69ler our7e file(*, 7"a#gi#g 6e6ory e!!i#g e!7.*, ele7! Pro5e7! / Se!!i#g fro6 !"e 6e#u.

2.2 Auic3 sta&t to c&eate assembl* language a))lications( 1. S!ar! !"e S!EB#$M rogra6 (i.e. !"e I#!egra!ed )evelo6e#! >#viro#6e#!* fro6 !ar!Progra6SPG-SCARMSI)>ARM. 2. ro6 P&o?ect  6e#u, ele7! "lose )&o?ect (if a#y ro5e7! i oe#*. &. ro6 P&o?ect   6e#u, ele7! e6 P&o?ect . T"e Oe# dialog 3i#do3 3ill 9e dilayed. Sele7! !"e deired a!" 3"ere you 3i" !o 7rea!e !"i #e3 ro5e7!. (or e0a6le, CSPG*. CAJTION T"e a!" a#d file#a6e 6u! #o! 7o#!ai# a7e or o!"er e7ial 7"ara7!er u7" a !a9, 7o66a, e6i7olo# e!7. I# !"e ;ile #a6e< field, !ye !"e #a6e of !"e ro5e7!, 3i!"ou! a#y e0!e#io#. or e0a6le, you 6ay !ye ;P$,1 (i# a9ove e0a6le, P$,1.E/*. T"i i !"e file !"a! you 3ill #eed !o ue !o rogra6 your 6i7ro-7o#!roller.

2.4 Auic3 sta&t %o& G"@,S-!! ;$T,S< a))lications( 2.4.1 o6 to ,)en and modi%* e:isting u",S P&o?ect( 1.

Coy give# uCOS rogra6 o# " d&ive (eg. C:\Multitasking *

2.

Oe# S"#$M ;Sta&t

3.

Cloe !"e ro5e7! i# SI)>-ARM, if a#y ro5e7! i oe#.

4.

To ,)en !"e e0i!i#g )&o?ect  go !o ;S!E-#$M C:\Multitasking  

5.

#ll P&og&ams

SPJ H S"#$M

P&o?ect

S!E-#$M<

,)en )&o?ect

main.PI1g.

All .

C:\Multitasking\%uil$\%in\&PC'()*!"+  8.

)o3#load !"i "e0 file a#d 7"e7k !"e reul!.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 12 of 8%

STK-2148 Lab Manual 

2.4.2 ote( !% *ou 6ant to change %olde& name o% the e:isting )&o?ect then %ollo6 belo6 mentioned )&ocedu&e(

1. Coy give# uCOS rogra6 o# C drive. 2. Make 7oy of o#e of !"e uCOS ro5e7!, 3i!" a#o!"er #a6e a#d ave i! (uoe C:\Multi_,ask *. &. A you "ave 7"a#ged !"e #a6e of !"e folder (6ea# 3orki#g dire7!ory*, you 6u! "ave !o do !"e a6e 7"a#ge i# !"e Ma3e%ile  ree#! i# !"e a6e folder vi. C:\Multi_,ask

Mak"fil"

4. Oe# !"i Makefile i# @ordPad. I# Makefile fi#d @OR)IR U C:\Multitasing !any another name may be present" C"a#ge !"i li#e !o ,$KB!$ ( "(=MultiBTas3 

Save !"e Makefile a#d 7loe i!. 8. Oe# S"#$M ;Sta&t

#ll P&og&ams

SPJ H S"#$M

S!E-#$M<

. Cloe !"e ro5e7! i# SI)>-ARM, if a#y ro5e7! i oe#. . To ,)en !"e e0i!i#g )&o?ect  (MultiBTas3 * go !o ;S!E-#$M C:\Multi_,ask  

,)en )&o?ect

main.PI1g.

All .

C:\Multi_,ask\%uil$\%in\&PC'()*!"+  27.

)o3#load !"i "e0 file a#d 7"e7k !"e reul!.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 18 of 8%

STK-2148 Lab Manual 

D. a&d6a&e esc&i)tion D.1 STK-2148( +n)ac3ing( ou 3ill fi#d follo3i#g i!e6 i# !"e a7kage •

ST-214' 9oard



Serial 7o66u#i7a!io# 7a9le (S!raig"! -Pi#*



Po3er ada!er 3i!" 7a9le



SPG>TE C)-ROM

Po6e& Su))l* $eui&ements( T"e o3er ada!er 3ork 3i!" 2&%Kol! AC. I! rodu7e aro0i6a!ely  Kol! )C, a#d !"e ST-214' ue o#-9oard regula!or !o rovide 8 Kol! a#d &.& Kol! )C !o all 7o6o#e#! o# !"e 9oard.

"onnecting the s*stem( T"e erial 7o66u#i7a!io# 7a9le ulied 3i!" !"e 9oard "ould 9e ued !o 7o##e7! !"e 9oard !o a PC ru##i#g @i#do38/'/NT/ M>/2%%%/P/Ki!a Oera!i#g Sy!e6. Co##e7! o#e e#d of !"e erial 7a9le !o JART% of ST-214' 9oard a#d o!"er e#d !o PC erial or!. Po6e&ing ,(

Af!er 7o##e7!i#g !"e erial 7o66u#i7a!io# 7a9le a de7ri9ed a9ove, you 6ay i#er! !"e o3er ada!er ou!u! 5a7k i#!o !"e o#-9oard o3er o7ke!. Plug !"e o3er ada!er i#!o 2&%KAC 6ai# ou!le! a#d !ur# i! o#. No3 re o#-9oard o3er 3i!7", o3er-o# i#di7a!io# ree# H>) 3ill !ur# o#. "#+T!,(  Pleae do #o! 7o##e7! or di7o##e7! !"e erial 7o66u#i7a!io# 7a9le 3"ile !"e 9oard i

 o3ered ON. )oi#g o 7a# da6age !"e erial or! of !"e ST-214' 9oard a#d/or PC.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 1 of 8%

STK-2148 Lab Manual 

4. "onnecto& etails Jum)e& and S6itch Settings 4.1 STK-2148 loc3 iag&am( Belo3 figure "o3 !"e lo7a!io# of differe#! 7o6o#e#! o# !"e ST-214' 9oard.

G1/JART1 or RS4'8 102 Te0! HC)

PS2 Co##e7!or 

12'04 ra"i7 HC)

G&/JSB

G2/JART%

SPI Co##e7!or  H>) !o o9erve P@M 2 ig#al

Po3er ON/O S3i!7" P@R GAC 

' e#eral Puroe H>)

Relay POT !o give A#alog I#u!

'-e#eral Puroe ey

HM&8

I2C 9aed Seve# Seg6e#!

Buer 

TP, Te! Poi#! for )AC ey !o give >0!er#al I#!erru! SPI 9aed >>PROM, AT2828

R>S>T

I2C 9aed RTC, )S1&%

PM

GTA Co##e7!or 

404 Ma!ri0 eyad

 Co##e7!or for S!eer Mo!or 

I2C 9aed >>PROM, AT24C812

igure 1

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 1 of 8%

STK-2148 Lab Manual 

Belo3 figure "o3 !"e lo7a!io# of differe#! 3i!7"e o# !"e ST-214' 9oard.

S1 S3i!7" !o 7o##e7! JART1 !o HPC214'

S14 S3i!7" !o Co##e7! RS4'8 i# !o HPC214'

S2 S3i!7" !o Tur# ON Au!o Mode

S& S3i!7" !o Co##e7! JSB )evi7e !o HPC214'

S12.1 a#d S12.2 S3i!7" !o 7o##e7! Relay1 a#d Relay2 !o HPC214'

S1&.1 !o e#a9le ra"i7 HC) a#d S1&.2 !o e#a9le H>)

G >0a#io# Co##e7!or 

S4.1 a#d S4.2 S3i!7" !o 7o##e7! POT a#d HM&8 !o A)C%.1 a#d A)C%.2 of HPC214'

S11 S3i!7" !o 7o##e7! S!eer Mo!or !o HPC214'

S.1, S.2 a#d S.& S3i!7" !o Co##e7! Buer, )AC /TP a#d >INT% !o HPC214'

S S3i!7" !o Co##e7! SPI >>PROM !o HPC214'

HPC214'

S8 S3i!7" !o Co##e7! I2C Peri"eral !o HPC214'

I2C Co##e7!or 

 Co##e7!or for S!eer Mo!or 

S@28 ey !o give >0!er#al I#!erru!

igure 2

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 1' of 8%

STK-2148 Lab Manual 

4.2 !P S6itches etails( S1(

Tur# ON !"i 3i!7" !o 7o##e7! JART1 7o##e7!or !o JART1 li#e (T0)1/P%.' a#d R0)1/P%.* of HPC214'. S2(

Mode ele7!io# 3i!7". T"e HPC2100 6i7ro-7o#!roller i#7lude o#-7"i fla" for !ori#g uer rogra6 a#d #o#-vola!ile da!a. T"e HPC214' "ave 812By!e fla". T"i fla" i I#-Sy!e6-Progra66a9le (ISP*. T"e HPC2100 6i7ro-7o#!roller "ave a 9uil!-i# 9oo!-load rogra6. Jo# o3er-o#, !"i 9oo!-load  rogra6 !ake 7o#!rol i! ae 7o#!rol !o !"e uer rogra6 if i# P%.14 i :I: a#d o6e o!"er 7o#di!io# are a!ified. Pleae refer !o !"e HPC2100 da!a-"ee! for fur!"er de!ail. O# !"e ST-214' 9oard, !"e P%.14 i# i 6ade availa9le o# !"i S& 3i!7". Tur# ON !"i 3i!7" !o 7o#!rol !"e Mode (ISP 6ode or Ru# 6ode* 9y la" Magi7. SD(

Tur# ON !"i 3i!7" !o 7o##e7! JSB devi7e 7o##e7!or !o JSB li#e of HPC214'. S4.1(

Tur# ON !"i 3i!7" !o 7o##e7! POT (R2%* !o A)C%.1/P%.2' of HPC214'. S4.2(

Tur# ON !"i 3i!7" !o 7o##e7! HM&8 !o A)C%.2/P%.2 of HPC214'. SI(

Tur# ON !"i 3i!7" !o 7o##e7! I2C eri"eral (Seve# Seg6e#!, RTC ()S1&%* a#d >>PROM (AT24C812** !o I2C li#e (SCH%/P%.2 a#d S)A%/P%.&* of HPC21 4'. S.1(

Tur# ON !"i 3i!7" !o 7o##e7! Buer !o P%.28 of HPC214'. S.2(

Tur# ON !"i 3i!7" !o 7o##e7! )AC/TP !o )ACOu!/P%.28 of HPC214'.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 1 of 8%

STK-2148 Lab Manual 

S.D(

Tur# ON !"i 3i!7" !o 7o##e7! 3i!7" S@28 !o >INT%/P%.1 of HPC214'. P%.1 i >0!er#al I#!erru! %  i# of HPC214'. S'(

Tur# ON !"i 3i!7" !o 7o##e7! SPI >>PROM (AT2828* !o SPI li#e (SC%/P%.4, MISO%/P%.8, MOSI%/P%. a#d CS/P%.* of HPC214'. S11(

Tur# ON !"i 3i!7" !o 7o##e7! S!eer Mo!or !o P%.1%, P%.11, P%.12 a#d P%.1& of HPC214'. S12.1(

Tur# ON !"i 3i!7" !o 7o##e7! Relay 1 !o P%.1' of HPC214'. S12.2(

Tur# ON !"i 3i!7" !o 7o##e7! Relay 2 !o P%.1 of HPC214'. S1D.1(

Tur# ON !"i 3i!7" !o e#a9le 12'04 ra"i7 HC). S1D.2(

Tur# ON !"i 3i!7" !o e#a9le ' H>) 7o##e7!ed !o P%.1% ()*, P%.11 ()1%*, P%.12 ()11*, P%.1& ()12*, P%.1' ()1&*, P%.1 ()14*, P%.2% ()18* a#d P%.21 ()1* of HPC214'. S14(

Tur# ON !"i 3i!7" !o e#a9le RS4'8 7o66u#i7a!io# ro!o7ol over HPC214'. or RS4'8 7o66u#i7a!io# MA4'8 IC i ued. S14.1( Tur# ON !"i 3i!7" !o 7o##e7! )I of MA4'8 !o P%.'/T)1 of HPC214'. S14.2( Tur# ON !"i 3i!7" !o 7o##e7! RO of MA4'8 !o P%./R)1 of HPC214'. S14.D( Tur# ON !"i 3i!7" !o 7o##e7! )> of MA4'8 !o P%.28/PIO of HPC214'.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 2% of 8%

STK-2148 Lab Manual 

4.D Push-utton S6itches etails( @"e# reed, !"e 3i!7"e are grou#ded. @"e# Idle, !"ey are ulled "ig". Push-utton RST/R>S>T S@1 S@2 S@& S@4 S@8 S@ S@ S@' S@28 S@ !o S@24 Ma!ri0 eyad

Signal ame Ree! !o HPC214' P1.1 P1.1 P1.1' P1.1 P1.2% P1.21 P1.22 P1.2& P%.1/ >INT% P1.1 !o P1.2&

4.4 LEs and u99e& etails( All !"e H>) are 7o##e7!ed 9y 7o66o# a#ode 6e!"od. T"a! 6ea# !"e oi!ive leg of ea7" H>) i 7o##e7!ed !o K77 a#d #ega!ive leg !o !"e or! i# of !"e 6i7ro7o#!roller. A logi7 % o# !"e or! i# 3ill 6ake H>) ON a#d logi7 1 3ill 6ake i! O. LE )1/ P.ON ) )1% )11 )12 )1& )14 )18 )1 )21 )28

Signal ame +8K Po3er ON/O P%.1% P%.11 P%.12 P%.1& P%.1' P%.1 P%.2% P%.21/P@M8 S@28 P%./P@M2

u99e&

PN.2I

4.I "onnecto& etails( +#$TN(

T"i i a )B fe6ale 7o##e7!or, ued for RS2&2 erial 7o66u#i7a!io# 3i!" !"e PC Pi# 2 U JART% RS2&2 T0) (ou!u! of C*

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 21 of 8%

STK-2148 Lab Manual 

Pi# & U JART% RS2&2 R0) (i#u! !o C* Pi# 4 U RS2&2 )TR  Pi# 8 U rou#d Pi#  U RS2&2 RTS All o!"er i# of G1/JART% are u#ued. +#$T1(

T"i i a )B fe6ale 7o##e7!or, ued for RS2&2 erial 7o66u#i7a!io# 3i!" !"e PC Pi# 2 U JART1 RS2&2 T0) (ou!u! of C* Pi# & U JART1 RS2&2 R0) (i#u! !o C* Pi# 8 U rou#d Pi#  U )+/A for RS4'8 Pi# ' U )-/B for RS4'8 1:2 L":

T"i i a 1 i#, i#gle li#e 7o##e7!or, deig#ed for 7o##e7!io# !o !a#dard, !e0! HC) 6odule. T"e  i#/ig#al 7orreo#de#7e i deig#ed !o 9e 6a!7"i#g 3i!" !"a! re=uired 9y u7" HC) 6odule. Pi# 1 U N) Pi# 2 U +8K Pi# & U Kl7d Pi# 4 U P1.28 (Jed a RS of HC)* Pi# 8 U N) Pi#  U P1.24 (Jed a >N of HC)* Pi#  !o 1% U No Co##e7!io#/N) Pi# 11 U P%.18 (Jed a )4 of HC)* Pi# 12 U P%.1 (Jed a )8 of HC)* Pi# 1& U P%.22 (Jed a ) of HC)* Pi# 14 U P%.&% (Jed a ) of HC)* Pi# 18 U Ba7k lig"!i#g Pi# 1 U N)

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 22 of 8%

STK-2148 Lab Manual 

128:4 &a)hics L" :

T"i i a 2% i#, i#gle li#e 7o##e7!or, deig#ed for 7o##e7!io# !o !a#dard, 12'04 Mo#o7"ro6e ra"i7 HC) 6odule. T"e i#/ig#al 7orreo#de#7e i deig#ed !o 9e 6a!7"i#g 3i!" !"a! re=uired 9y u7" HC) 6odule. Pi# 1 U N) Pi# 2 U +8K Pi# & U Kl7d Pi# 4 U P1.28 (Jed a RS of HC)* Pi# 8 U P%.18 (Jed a R@ of HC)* Pi#  U P1.24 (Jed a >N of HC)* Pi#  U P%.1% (Jed a )% of HC)* Pi# ' U P%.11 (Jed a )1 of HC)* Pi#  U P%.12 (Jed a )2 of HC)* Pi# 1% U P%.1& (Jed a )& of HC)* Pi# 11 U P%.1' (Jed a )4 of HC)* Pi# 12 U P%.1 (Jed a )8 of HC)* Pi# 1& U P%.2% (Jed a ) of HC)* Pi# 14 U P%.21 (Jed a ) of HC)* Pi# 18 U P%.22 (Jed a CS1 of HC)* Pi# 1 U P%.&% (Jed a CS2 of HC)* Pi# 1 U +8K Pi# 2% U N)

!2" "onnecto& ( T"i !a#dard 4 i# I2C 7o##e7!or rovide uor! for i#!erfa7i#g of I2C 9aed eri"eral !o HPC2100. T"i 7o##e7!or i 6ou#!ed o# 6iddle-9o!!o6 ide of !"e 9oard a "o3# i# figure1. 4 )in st&aight cable 7a#  9e ued !o 7o##e7! HPC2100 !o !"e 9oard "avi#g I2C 9aed eri"eral devi7e.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 2& of 8%

STK-2148 Lab Manual 

T"e i#-ou! of I2C Co##e7!or i give# 9elo3 Pin

Signal name

1 2 & 4

P%.2 (SCH%* P%.& (S)A%* +8K )N)

SP! "onnecto& ( T"i !a#dard 1% i# 7o##e7!or rovide uor! for i#!erfa7i#g 6ore SPI 9aed eri"eral devi7e !o HPC2100. T"i 7o##e7!or i 6ou#!ed o# !o ide of !"e 9oard a "o3# i# figure1.  1N )in st&aight cable 7a#  9e 7o##e7!ed !o !"i 7o##e7!or, 3"ile o!"er e#d of !"e 7a9le 7a# 9e 7o##e7!ed !o 9oard "avi#g SPI 9aed  eri"eral, ree7!ively. T"e i#-ou! of SPI Co##e7!or i give# 9elo3

Pin

Signal name

1 2 & 4 8   '  1%

P%.1 P%.2& P%.28 P%.&1 P%.8 (MISO* P%. (MOSI* P%. (NCS* P%.4 (SCO* +8K N)

JT# "onnecto&( T"i !a#dard 2% i# GTA 7o##e7!or rovide de9uggi#g uor! for !"e HPC2100. T"i 7o##e7!or i 6ou#!ed o# !o ide of !"e 9oard a "o3# i# figure1. JT# cables li3e SJT-S o& SJT-+ 7a# 9e 7o##e7!ed !o !"i 7o##e7!or, 3"ile o!"er e#d of !"e 7a9le 7a# 9e 7o##e7!ed !o PC COM or! or JSB or!, ree7!ively. )e9ugger of!3are (like !"e debugge& 9uil! i#!o S"#$M* allo3 GTA 9aed de9uggi#g. I! i alo oi9le !o ue !"ird ar!y GTA 9aed e6ula!or /de9ugger. T"e i#-ou! of GTA Co##e7!or i give# 9elo3

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 24 of 8%

STK-2148 Lab Manual 

Pin

Signal name

Pin

Signal name

1 & 8   11 1& 18 1 1

&.&K P1.&1/NTRST P1.2'/T)I P1.&%/TMS P1.2/TC P1.2/RTC P1.2/T)O NRST N) N)

2 4  ' 1% 12 14 1 1' 2%

&.&K N) N) N) N) N) N) N) N) N)

J(

T"i i 2 i# dual li#e "eader. I! 9ri#g ou! I/O a#d 6o! of !"e i# of !"e HPC2100 6i7ro-7o#!roller. ur!"er, 8K a#d N) are alo 6ade availa9le o# !"ee 7o##e7!or. T"ee 7o##e7!or are i#!e#ded for ue !o 7o##e7! e0!er#al eri"eral.

T"e i#/ig#al de!ail of G are a 9elo3

Pin

Signal name

Pin

Signal name

1 & 8   11 1& 18 1 1 21 2& 28

P1.1 P1.1' P%.2' P%.&% P%.1% P%.12 P%.14 P%.1 P1.1' P1.28 P1.2& P1.21 + 8K

2 4  ' 1% 12 14 1 1' 2% 22 24 2

P1.1 P1.1 P%.2 P%.&1 P%.11 P%.1& P%.18 P%.1 P1.1 P1.24 P1.22 P1.2% N)

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 28 of 8%

STK-2148 Lab Manual 

I. o6nloading and $unning +se& P&og&ams T"e HPC2100 6i7ro-7o#!roller i#7lude o#-7"i fla" for !ori#g uer rogra6 a#d #o#-vola!ile da!a. HPC214' o# ST-214' "ave 812By!e fla". T"i fla" i I#-Sy!e6-Progra66a9le (ISP*. T"erefore i! i oi9le !o do3#load uer rogra6 i#!o o#-7"i fla" of HPC214', !"roug" erial or! 7o##e7!ed !o PC. or doi#g o, a 7er!ai# oi!io# of S2 3i!7" i re=uired. S2 S6itch should be continuousl* , . T"i e7!io# de7ri9e "o3 !o ue !"e of!3are la" Magi7 !o do3#load rogra6 i#!o HPC214'.

I.1 o6 to install lash Magic( T"e C) you "ave re7eived 3i!" !"i 9oard 7o#!ai# SCARM, C Co6iler for ARM. I#!all i!. Af!er i#!alla!io# go !o folder "(=S"#$M=+tilities . T"i folder 7o#!ai# 8 i file. I#!all la" Magi7 fro6 la"Magi7&.1.i. >0!ra7! !"e lashMagicD.'1.9i)  a#d !"e# ru# la"Magi7.e0e fro6 !"e e0!ra7!ed file. (If you "ave 3ro#g verio# of la" Magi7 already i#!alled, !"e# leae u#i#!all i! fir! a#d !"e# i#!all #e3 verio#*.

I.2 o6nload and $un )&og&am using lash Magic into LP"2148( •

Af!er i#!alla!io# of la" Magi7, oe# i!.



I# la" Magi7 go !o O!io# -V Adva#7ed O!io#-V Co66u#i7a!io#. C"e7k :ig" Seed Co66u#i7a!io# a#d kee Ma0i6u6 Baud Ra!e a 12%%. Cli7k o# O.



Agai# i# la" Magi7 go !o O!io# -V Adva#7ed O!io#-V :ard3are Co#fig. ;Je )TR a#d RTS !o 7o#!rol RST a#d P%.14< o!io# "ould 9e 7"e7ked. Cli7k o# O. (Af!er doi#g a9ove 6e#!io#ed e!!i#g, la" Magi7 !ore i! 6ea# for !"e #e0! !i6e 5u! verify if !"ee e!!i#g are roer or #o!. If !"ey are roer !"e# you 7a# dire7!ly follo3 9elo3 6e#!io#ed  ro7edure*

1. Co##e7! !"e G2/JART% 7o##e7!or of ST-214' 9oard !o COM1 or COM2 of a PC, ui#g !"e erial 7o66u#i7a!io# 7a9le (ulied 3i!" !"e 9oard*. 2. ee S2 3i!7" i# ON oi!io#. (ou 7a# kee S2 3i!7" 7o#!i#uouly ON* S3i!7" ON o3er !o !"e ST-214'.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 2 of 8%

STK-2148 Lab Manual 

&. )o roer e!!i#g i# la" Magi7 (COM Por! COM1 (if o!"er 7"ooe i!*, Baud Ra!e &'4%%, )evi7e HPC214', I#!erfa7e No#e (ISP*, >#a9le ;>rae 9lo7k ued 9y :e0 ilee&i%*ing co&&ect cable connection( @"e# !"e GTA Ca9le i 7orre7!ly 7o##e7!ed !o PC a 3ell a !"e !arge! 9oard, i! erve a a li#k  9e!3ee# !"e GTA or! of !arge! ro7eor a#d !"e PC. T"i li#k i ued 9y SPG - SCARM of!3are Tool (e.g. )e9ugger for ARM 6i7ro7o#!roller*. T"i of!3are !ool, )e9ugger 3ill 3ork 7orre7!ly o#ly 3"e# !"e GTA Ca9le i 7o##e7!ed 7orre7!ly.

o& SJT-S(

T"ere i a 7rude !e! !o verify SGT-S GTA Ca9le 7o##e7!io#. ou 6ay leae follo3 !"ee !e 1. Co##e7! GTA Ca9le 9e!3ee# PC COM or! a#d GTA 7o##e7!or o# ST-214', a er i#!ru7!io# i# !"i 6a#ual. 2. Tur# ON o3er !o !"e !arge! 9oard. &. O# !"e PC, ru# SPGTer6i#al of!3are. 4. I# !"e Por! Se!!i#g, ele7! aroria!e COM or! (!o 3"i7" !"e GTA 7a9le i 7o##e7!ed*. Sele7! 1182%% 9aud, #o ari!y, ' 9i! er 7"ar, 1 !o 9i! a#d #o flo3 7o#!rol. 8. Oe# !"e COM Por! 7o##e7!io#. . Tye 7"ara7!er DKE i# !"e !er6i#al 3i#do3. i.e. e#d !"e 7"ara7!er DKE !o !"e PC COM or!. . If !"e GTA Ca9le 7o##e7!io# i 7orre7!, i! 3ill e#d verio# of GTA 7a9le. A a reul!, you 3ill ee !"a! verio# aeari#g i# !"e !er6i#al 3i#do3. T"i i#di7a!e !"a! GTA Ca9le 7o##e7!io# i O. '. If you do#E! ee a#y 7"ara7!er i# !"e !er6i#al 3i#do3, ro9a9ly !"e GTA Ca9le i #o! 7o##e7!ed aroria!ely.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 2 of 8%

STK-2148 Lab Manual 

. o6 to ebug P&og&am(

1. Co##e7! SGT-S a 6e#!io#ed a9ove. 2. Oe# ro5e7! i# SI)>ARM. Re9uild i!. &. )o3#load !"e a6e 7ode i# !"e !arge! 9oard. 4. I# SI)>ARM go !o Tool -V )e9ugger. 8. I# )e9ugger go !o Ru# -V Cli7k o# ;No! 7o##e7!ed !o !arge! (7li7k "ere !o 7o##e7!*0%1Ari!"6e!i7

GTA

"onnections( To ue SGT-S, GTA 7a9le Refer C"a!er  P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>0%1Ari!"6e!i7

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 To do3#load a#d ru# !"i rogra6 Refer C"a!er 8 ,ut)ut( Ari!"6e!i7 oera!io# are erfor6ed o# !"e ARM 7ore regi!er. To ee !"e reul! of oera!io# ue )e9ugger. Refer C"a!er .

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page &1 of 8%

STK-2148 Lab Manual 

'.2 &ite a )&og&am %o& igital ,ut)ut. #im( @ri!e a Progra6 !o Bli#k H>) ree#! o# ST-214'. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' ' e#eral Puroe H>)

PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>0%2Bli#k 

"onnections( ee S1&.2 3i!7" i# ON oi!io#. ' H>) () !o )1* ree#! o# ST-214' are 7o##e7!ed !o P%.1%, P%.11, P%.12, P%.1&, P%.1', P%.1, P%.2% a#d P%.21 ree7!ively 9y Co66o# A#ode 6e!"od. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>0%2Bli#k 

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee 9li#ki#g of H>). ote ee S1&.2 3i!7" i# O oi!io# !o ave o3er, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page &2 of 8%

STK-2148 Lab Manual 

'.D &ite a )&og&am %o& igital !n)ut. #im( @ri!e a rogra6 !o !ake i#u! fro6 u"-9u!!o# 3i!7"e S@1 !o S@' (7o##e7!ed fro6 P1.1 !o P1.2&* a#d "o3 i! !a!u o# 7orreo#di#g H>) ) !o )1 ree#! o# ST-214'. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' ' e#eral Puroe H>) a#d 3i!7"e

PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>0%&)igi!alI#u!

"onnections( ee S1&.2 3i!7" i# ON oi!io#. Pu"-9u!!o# 3i!7"e S@1 !o S@' are 7o##e7!ed fro6 P1.1 !o P1.2&. H>) ) !o )12 are 7o##e7!ed !o P%.1% !o P%.1& a#d )1& !o )1 are 7o##e7!ed fro6 P%.1' !o P%.21. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%&)igi!alI#u!

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( Af!er rei#g a#y 3i!7" fro6 S@1 !o S@', i! 7orreo#di#g H>) () !o )1* 3ill 9e7o6e ON o!"er3ie i! 3ill 9e O. ote ee S1&.2 3i!7" i# O oi!io# !o ave o3er, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page && of 8%

STK-2148 Lab Manual 

'.4 &ite a )&og&am %o& u99e& !nte&%ace. #im( @ri!e a rogra6 for 9uer i#!erfa7e. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' PC Buzzer

Serial Ca9le

Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>0%4Buer  "onnections(

ee S.1 3i!7" i# ON oi!io#. Buer i 7o##e7!ed !o P%.28. P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>0%4Buer  To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut(

Buer 3ill !ur# ON a#d O. ote ee S.1 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page &4 of 8%

STK-2148 Lab Manual 

'.I &ite a )&og&am %o& $ela* !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e 2 relay 3i!" HPC214'. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

RH2

PC

ST-214'

RH1

Serial Ca9le

Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%8Relay

"onnections(

ee S1&.2 3i!7" i# ON oi!io# !o ee relay 7o#di!io# (ON or O* o# H>) ()1& !o )14*. ee S12 3i!7" i# ON oi!io#. S12.1 i 7o##e7!ed !o RH1 a#d S12.2 i 7o##e7!ed !o RH2. RH1 a#d RH2 are 7o##e7!ed !o P%.1' a#d P%.1 ree7!ively !"roug" H>) )1& a#d )14.

P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%8Relay

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8.

,ut)ut(

Relay 3ill 9e7o6e ON a#d O 7o#!i#uouly.

ote ee S1&.2 a#d S12 3i!7"e i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page &8 of 8%

STK-2148 Lab Manual 

'. &ite a )&og&am %o& Ste))e& Moto& !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e !eer 6o!or. Eui)ments(  SCARM, PC, ST-214' 3i!" S!eer Mo!or. loc3 iag&am( G2/JART% G2

ST-214' S!eer Mo!or )river 

PC

/

Serial Ca9le Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%S!eerMo!or  "onnections(

Co##e7! S!eer Mo!or !o  7o##e7!or. ee S1&.2 3i!7" i# ON oi!io# !o ee !eer 6o!or "ae o# H>) () !o )12*. ee S11 3i!7" i# ON oi!io#. S!eer Mo!or i #o3 7o##e7!ed !o P%.1%, P%.11, P%.12 a#d P%.1& !"roug" H>) ) !o )12. P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%S!eerMo!or  To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut(

ou 7a# ee !eer 6o!or 6ovi#g i# a ar!i7ular dire7!io# a#d 7orreo#di#g "ae 7"a#ge you 7a# o9erve o# H>) ) !o )12. ote ee S1&.2 a#d S11 3i!7"e i# O oi!io# !o ave o3er, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page & of 8%

STK-2148 Lab Manual 

'.' !nte&%acing o% 1:2 Te:t L". #im( @ri!e a rogra6 !o dilay 6eage o# 102 Te0! HC). Eui)ments(  SCARM, PC, ST-214' 3i!" 102 Te0! HC). loc3 iag&am( G2/JART% G2

102 Te0! HC)

PC ST-214' Serial Ca9le

Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%:elloHC)

P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%:elloHC)

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8.

,ut)ut(

ou 7a# ee !"e 6eage ello o&ld o# HC). If re=uired Ree! !"e 9oard.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page & of 8%

STK-2148 Lab Manual 

'.8 &ite a )&og&am %o& Se&ial "ommunication using +#$TN. #im( @ri!e a Progra6 !o !ra#fer 6aage ;:ello 3orldW< erially a! 12%%-9aud ra!e '-9i! da!a a#d 1 !o-9i! ui#g JART%. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%':ello "onnections( Co##e7! PC erial or! !o G2/JART% 7o##e7!or o# ST-214' 9y !"e 7a9le rovided !o you 3i!" ST214'. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >0%':ello

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee ou!u! o# SPGTer6i#al. T"erefore Oe# SPGTer6i#al. o !o Por! -V Se!!i#g. )o roer e!!i#g (Baud Ra!e 12%%, )a!a Bi! ', S!o Bi! 1, >7"o Off, Pari!y No#e, Co6 Por! Co6 1 (if o!"er 7"ooe i!**. Cli7k o# O. o !o Por! -V Oe#. If re=uired Ree! !"e ST-214' 9oard. I! 3ill !ra#6i! !"e 6eage X:ello 3orldW0%404Ma!ri0eyad

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( I# !"i rogra6 af!er rei#g a#y key fro6 S@ !o S@24, i! 7ode 3ill 9e dilayed o# 102 Te0! HC).

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page & of 8%

STK-2148 Lab Manual 

'.1N &ite a )&og&am %o& on-chi) #nalog to igital "onve&sion. #im( @ri!e a rogra6 for o#-7"i A)C (A)C %, C"a##el 1, P%.2'*. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' A#alog I#u!

PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01%A)C

"onnections( To give a#alog i#u! fro6 Po!e#!io6e!er R2% ree#! i# A#alog I#u! regio# o# ST-214' kee S4.1 i# ON oi!io#. To give e0!er#al a#alog i#u!, kee S4.1 i# O oi!io# a#d 7o##e7! e0!er#al a#alog i#u! !o i# 1 of AIN>T 7o##e7!or. A#alog i#u! ra#ge i fro6 % !o &.&K. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01%A)C

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee digi!al readi#g of !"e 7orreo#di#g a#alog i#u! o# 102 Te0! HC). ote ee S4.1 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 4% of 8%

STK-2148 Lab Manual 

'.11 &ite a )&og&am %o& LMDI Tem)e&atu&e Senso& !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e of HM&8 !e6era!ure e#or !o o#-7"i A)C (A)C %, C"a##el 2, P%.2*. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' A#alog I#u!

PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >011HM&8Te6era!ureSe#or 

"onnections( To i#!erfa7e HM&8 (ree#! i# A#alog I#u! regio# o# ST-214'* 3i!" A)%.2 kee S4.2 i# ON oi!io#. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>011HM&8Te6era!ureSe#or 

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee !"e !e6era!ure readi#g o# 102 Te0! HC). ote ee S4.2 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 41 of 8%

STK-2148 Lab Manual 

'.12 ene&ation o% $am) 6ave using on-chi) #". #im( @ri!e a rogra6 !o ge#era!e ra6 3ave ui#g o#-7"i )AC (P%.28*. Eui)ments(  SCARM, PC, ST-214', O7illo7oe. loc3 iag&am( G2/JART% G2

ST-214' + O7illo7oe PC S TP

Serial Ca9le Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e)AC

"onnections(

ee S.2 (ree#! i# >T. INT regio#* i# ON oi!io#. Co##e7! o#e i# of o7illo7oe !o TP/)AC a#d a#o!"er !o N).

P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e)AC

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8.

,ut)ut(

ou 7a# ee ra6 3ave o# o7illo7oe.

ote ee S.2 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 42 of 8%

STK-2148 Lab Manual 

'.1D &ite a )&og&am %o& !2" based Seven Segment LE is)la* !nte&%ace. #im( @ri!e a rogra6 !o dilay #u69er o#  eg6e#! dilay ui#g I2C ro!o7ol. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' )IS2 PC

Sou&ce "ode(

Serial Ca9le )IS1

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e>01&I2CSeve#Seg6e#!

"onnections(

ee S8 3i!7" (ree#! i# I2C Peri"eral regio#* i# ON oi!io#.

P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01&I2CSeve#Seg6e#!

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8.

,ut)ut(

ou 7a# ee  a#d 2 #u69er o# Seve# Seg6e#!.

ote ee S8 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 4& of 8%

STK-2148 Lab Manual 

'.14 &ite a )&og&am %o& !2" based EEP$,M !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e >>PROM ui#g I2C ro!o7ol. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' I2C

PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >014I2C>>PROM "onnections( ee S8 3i!7" (ree#! i# I2C Peri"eral regio#* i# ON oi!io#. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >014I2C>>PROM

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee ou!u! o# SPGTer6i#al. T"erefore Oe# SPGTer6i#al. o !o Por! -V Se!!i#g. )o roer e!!i#g (Baud Ra!e 12%%, )a!a Bi! ', S!o Bi! 1, >7"o Off, Pari!y No#e, Co6 Por! Co6 1 (if o!"er 7"ooe i!**. Cli7k o# O. o !o Por! -V Oe#. If re=uired Ree! !"e ST-214' 9oard. ir! da!a 3ill  9e 3ri!!e# i# >>PROM a#d !"e# i! 3ill 9e read fro6 >>PROM. T"e a6e da!a (%, 1, 2 a#d &* 3ill 9e dilayed o# SPGTer6i#al. ote ee S8 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 44 of 8%

STK-2148 Lab Manual 

'.1I &ite a )&og&am %o& !2" based $T" !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e )S1&% RTC ui#g I2C ro!o7ol. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' I2C

PC Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >018I2CRTC "onnections( ee S8 3i!7" (ree#! i# I2C Peri"eral regio#* i# ON oi!io#. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >018I2CRTC

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee da!e a#d !i6e o# 102 Te0! HC). Alo you 7a# ee ou!u! o# SPGTer6i#al. T"erefore Oe# SPGTer6i#al. o !o Por! -V Se!!i#g. )o  roer e!!i#g (Baud Ra!e 12%%, )a!a Bi! ', S!o Bi! 1, >7"o Off, Pari!y No#e, Co6 Por! Co6 1 (if o!"er 7"ooe i!**. Cli7k o# O. o !o Por! -V Oe#. If re=uired Ree! !"e ST-214' 9oard. To S>T RTC follo3 !"e !e dilayed o# SPGTer6i#al o!"er3ie 3ai! for 8 e7o#d, da!e a#d !i6e 3ill 9e dilayed 7o#!i#uouly o# SPGTer6i#al. ote ee S8 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 48 of 8%

STK-2148 Lab Manual 

'.1 &ite a )&og&am %o& SP! based EEP$,M !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e >>PROM ui#g SPI ro!o7ol. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' PC SPI

Serial Ca9le Sou&ce "ode( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01SPI>>PROM "onnections( ee S 3i!7" (ree#! i# SPI >>PROM regio#* i# ON oi!io#. P&ocedu&e( T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01SPI>>PROM

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut( ou 7a# ee ou!u! o# SPGTer6i#al. T"erefore Oe# SPGTer6i#al. o !o Por! -V Se!!i#g. )o roer e!!i#g (Baud Ra!e 12%%, )a!a Bi! ', S!o Bi! 1, >7"o Off, Pari!y No#e, Co6 Por! Co6 1 (if o!"er 7"ooe i!**. Cli7k o# O. o !o Por! -V Oe#. If re=uired Ree! !"e ST-214' 9oard. ir! da!a 3ill  9e 3ri!!e# i# >>PROM a#d !"e# i! 3ill 9e read fro6 >>PROM. T"e a6e da!a (:ello* 3ill 9e dilayed o# SPGTer6i#al. ote ee S 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 4 of 8%

STK-2148 Lab Manual 

'.1' &ite a )&og&am %o& E:te&nal !nte&&u)t. #im( @ri!e a rogra6 !o oera!e H>) ui#g u"-9u!!o# key 7o##e7!ed !o e0!er#al i#!erru! >INT% (P%.1* of HPC214'. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' PC

>0!. INT

Serial Ca9le Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01>INT% "onnections(

To 7o##e7! S@28 3i!7" (ree#! i# >T. INT regio#* !o >INT%/P%.1 of HPC214', kee S.& (ree#! i# >T. INT regio#* i# ON oi!io#. P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01>INT% To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8. ,ut)ut(

>INT% i 7o#figured a Ho3-a7!ive, Hevel Se#i!ive. T"erefore if S@28 3i!7" i reed !"e# )1/PM H>) 3ill glo3 for !"a! 6u7" of !i6e o#ly. ote ee S.& 3i!7" i# O oi!io#, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 4 of 8%

STK-2148 Lab Manual 

'.18 &ite a )&og&am %o& 128:4 &a)hics L" !nte&%ace. #im( @ri!e a rogra6 !o i#!erfa7e 12'04 ra"i7 HC). Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

PC

12'04 ra"i7 HC)

ST-214' Serial Ca9le

Sou&ce "ode(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01'ra"i7HC)

"onnections(

ee S1&.1 3i!7" i# ON oi!io# !o e#a9le ra"i7 HC).

P&ocedu&e(

T"i rogra6 i availa9le i# !"e C) a! ST-214'Sour7e >01'ra"i7HC)

To >di! / Co6ile/ e#era!e :e0 file Refer C"a!er 2 . To do3#load a#d ru# !"i rogra6 Refer C"a!er 8.

,ut)ut(

or o6e !i6e, 6eage 3ill 9e dilayed o# ra"i7 HC). Af!er 6eage =uare 3ave 3ill aear o# ra"i7 HC).

ote ee S1&.1 3i!7" i# O oi!io# !o ave o3er, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 4' of 8%

STK-2148 Lab Manual 

8. E:)e&iments based on G"@,S-!! $T,S 8.1 !m)lement Multitas3ing 6ith T6o se)a&ate LE blin3ing tas3s. #im( @ri!e a rogra6 for 6ul!i!aki#g, !o 9li#k 2 H>) () (7o##e7!ed !o P%.1%* a#d )1% (7o##e7!ed !o P%.11** i# 2 eara!e !ak. Eui)ments(  SCARM, PC, ST-214'. loc3 iag&am( G2/JART% G2

ST-214' PC Serial Ca9le Sou&ce "ode( u",S )&og&ams a&e available at STK-2148=Sou&ce=u",S-!! Paste all these )&og&ams on " d&ive.

 No3 !"i 6ul!i!aki#g rogra6 i availa9le a! CMul!i!aki#gH>) (6ai#.P81* "onnections(

ee S1&.2 3i!7" i# ON oi!io#. T"i rogra6 i 3ri!!e# !o 9li#k 2 H>), ) a#d )1% 7o##e7!ed !o P%.1% a#d P%.11. P&ocedu&e(

 No3 !"i rogra6 i availa9le a! CMul!i!aki#gH>) (6ai#.P81* To >di! / Co6ile/ e#era!e :e0 file Refer Se7!io# 2.4 To do3#load a#d ru# !"i rogra6 Refer C"a!er 8 ,ut)ut(

ou 7a# ee H>) 9li#ki#g () a#d )1%*. ote ee S1&.2 3i!7" i# O oi!io# !o ave o3er, af!er e0e7u!io# of rogra6.

 ©   SPJETPL

All Rights Reserved. (www.spjsystems.com)

Page 4 of 8%

View more...

Comments

Copyright ©2017 KUPDF Inc.
SUPPORT KUPDF