| Electronic Components Datasheet Search |
|
SPMCK16Z4MPV20 Datasheet(PDF) 471 Page - Freescale Semiconductor, Inc |
|
|
|||||||||||||||||||||||||||||
SPMCK16Z4MPV20 Datasheet(HTML) 471 Page - Freescale Semiconductor, Inc |
|
471 / 500 page ![]() 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 |
|
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 |
| 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 |