Electronic Components Datasheet Search
  English  ▼
ALLDATASHEET.NET

X  

SPMCK16Z4MPV20 Datasheet(PDF) 471 Page - Freescale Semiconductor, Inc

Part # SPMCK16Z4MPV20
Description  M68HC16Z Series
PDF  500 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  FREESCALE [Freescale Semiconductor, Inc]
Direct Link  http://www.freescale.com
Logo FREESCALE - Freescale Semiconductor, Inc

SPMCK16Z4MPV20 Datasheet(HTML) 471 Page - Freescale Semiconductor, Inc

Back Button SPMCK16Z4MPV20 Datasheet HTML 467Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 468Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 469Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 470Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 471Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 472Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 473Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 474Page - Freescale Semiconductor, Inc SPMCK16Z4MPV20 Datasheet HTML 475Page - Freescale Semiconductor, Inc Next Button
Zoom Inzoom in Zoom Outzoom out
 471 / 500 page
background image
M68HC16 Z SERIES
INITIALIZATION AND PROGRAMMING EXAMPLES
USER’S MANUAL
E-19
ORG
$0200
;start program after interrupt table
*****
Initialize
*****
INIT:
;initialization stuff
TEMP
EQU
$0006
;variable space used in hex to asc routine
SCCNT
EQU
$0004
;stores the current number of seconds
MNCNT
EQU
$0002
;stores the current number of minutes
HRCNT
EQU
$0000
;stores the current number of hours
INITSYS:
;The following section is normally part of
;INCLUDE 'INITSYS.ASM', but we want to
;leave the COP on.
LDAB
#$0F
TBEK
;point EK to bank F for register access
LDAB
#$00
TBXK
;point XK to bank 0
TBYK
;point YK to bank 0
TBZK
;point ZK to bank 0
LDD
#$00CF
;initialize the SIM MCR
STD
SIMMCR
;this is redundant; it happens at reset
LDAA
#$7F
STAA
SYNCR
;set system clock to 16.78 Mhz
LDAB
#$C0
STAB
SYPCR
;enable the watchdog (COP)
;and set time-out period to 8 seconds
INCLUDE
'INITRAM.ASM'
;turn on internal SRAM at $10000
;set stack in bank 1 (SK=1, SP=03FE)
INCLUDE
'INITSCI.ASM'
;set SCI baud rate at 9600 baud
;enable SCI transmitter and receiver
LDD
#$0638
STD
PICR
;set the periodic interrupt at request level 6
;& assign vector #56 (address $00070) to it
LDD
#$0110
STD
PITR
;initialize PITR to interrupt every 1 sec
LDD
#$FFF9
;initialize Chip Sel Base Reg for Autovector
STD
CSBAR3
;on an IACK cycle: A24-A11=$FFF8, blK_sz = 8K
LDD
#$7801
;initialize Chip Sel Option Reg for
Autovector:
STD
CSOR3
;asynchronous, any Interrupt Priority Level
LDAB
#$FF
;set port F pins to be IRQ pins
STAB
PFPAR
;this is redundant: it happens at reset
LDAB
#$01
TBZK
;set zk nibble to bank 1 for variable access
LDZ
#$0000
;index those variables from $10000
LDD
#$0000
STD
SCCNT,Z
;clear sccnt register
STD
MNCNT,Z
;clear mncnt register
STD
HRCNT,Z
;clear hrcnt register
STD
TEMP,Z
;clear “save” variable space
LDAB
RSR
;find out who caused the last reset
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100  ...More


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com