Sim40 Example Configuration Code - Motorola MC68340 User Manual

Integrated processor with dma
Hide thumbs Also See for MC68340:
Table of Contents

Advertisement

4.4.3 SIM40 Example Configuration Code

The following code is an example configuration sequence for the SIM40 module.
***************************************************************************
* MC68340 basic SIM40 register initialization example code:
* This code is used to initialize the MC68340's internal SIM40 registers,
* providing basic functions for operation.
* It includes chip select programming for external devices.
* This code would be programmed beginning at offset $0 into ROM which is
* relocated to address $60000 by the initialization code.
* The SSP_VEC and RST_VEC vectors used to initialize the system stack
* pointer and initial PC, respectively, are located at offset $0 after
* reset.
***************************************************************************
* equates
***************************************************************************
SSP_INIT
EQU $10000
MBAR
EQU $0003FF00 Address of Module Base Address Reg.
MODBASE EQU $FFFFF000 Default Module Base address value
****************************************
* SIM40 register offsets from MBAR base address
MCR
EQU $00
SYNCR
EQU $04
SYPCR
EQU $21
CSAM0
EQU $40
CSBAR0
EQU $44
CSAM1
EQU $48
CSBAR1
EQU $4c
CSAM2
EQU $50
CSBAR2
EQU $54
CSAM3
EQU $58
CSBAR3
EQU $5c
***************************************************************************
* Reset vectors
* These two vectors should be located at addresses $0 and $4 after a processor
* hardware reset.
***************************************************************************
ORG $60000
SSP_VEC
DC.L SSP_INIT
RST_VEC
DC.L INIT340
4-38
Freescale Semiconductor, Inc.
Stack pointer initial value - top of RAM
Supervisor stack pointer - initial value
Reset vector pointing to initialization code
MC68340 USER'S MANUAL
For More Information On This Product,
Go to: www.freescale.com
MOTOROLA

Advertisement

Table of Contents
loading

Table of Contents