Freescale Semiconductor DSP56366 User Manual

Page 258

Advertising
background image

DSP56366 Bootstrap Program

DSP56366 24-Bit Digital Signal Processor User Manual, Rev. 4

A-6

Freescale Semiconductor

; MD:MC:MB:MA=0001

EPROMLD

move #BOOT,r2 ; r2 = address of external EPROM

movep #AARV,X:M_AAR1 ; aar1 configured for SRAM types of access

do #6,_LOOP9 ; read number of words and starting address

movem p:(r2)+,a2 ; Get the 8 LSB from ext. P mem.

asr #8,a,a ; Shift 8 bit data into A1

_LOOP9 ;

move a1,r0 ; starting address for load

move a1,r1 ; save it in r1

; a0 holds the number of words

do a0,_LOOP10 ; read program words

do #3,_LOOP11 ; Each instruction has 3 bytes

movem p:(r2)+,a2 ; Get the 8 LSB from ext. P mem.

asr #8,a,a ; Shift 8 bit data into A1

_LOOP11 ; Go get another byte.

movem a1,p:(r0)+ ; Store 24-bit result in P mem.

nop ; pipeline delay

_LOOP10 ; and go get another 24-bit word.

; Boot from EPROM done

bra <FINISH

OMR1XXX

jclr #MC,omr,BURN_RESER ; IF MD:MC:MB:MA=101x, go to RESERVED

; IF MD:MC:MB:MA=1001, go to BURN

jclr #MB,omr,OMR1IS0 ; IF MD:MC:MB:MA=110x, go to look for ISA/HC11

jclr #MA,omr,I8051HOSTLD ; If MD:MC:MB:MA=1110, go load from 8051 Host

; If MD:MC:MB:MA=1111, go load from MC68302 Host

;========================================================================

; This is the routine which loads a program through the HDI08 host port

; The program is downloaded from the host MCU with the following rules:

; 1) 3 bytes - Define the program length.

; 2) 3 bytes - Define the address to which to start loading the program to.

; 3) 3n bytes (while n is the program length defined by the 3 first bytes)

; The program words will be stored in contiguous PRAM memory locations starting

; at the specified starting address.

; After reading the program words, program execution starts from the same

; address where loading started.

; The host MCU may terminate the loading process by setting the HF1=0 and HF0=1.

; When the downloading is terminated, the program will start execution of the

; loaded program from the specified starting address.

; The HDI08 boot ROM program enables the following busses to download programs

; through the HDI08 port:

;

; C - ISA - Dual strobes non-multiplexed bus with negative strobe

; pulses dual positive request

; D - HC11 - Single strobe non-multiplexed bus with positive strobe

; pulse single negative request.

Advertising