17.05.2015 Views

~ National ~ Semiconductor - Al Kossow's Bitsavers

~ National ~ Semiconductor - Al Kossow's Bitsavers

~ National ~ Semiconductor - Al Kossow's Bitsavers

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

.set icu fprt,14 *aO<br />

.set icu-mctl,16 *aO<br />

.set lCu-c1ptr,18 *aO<br />

.set 1cu-pdat,19 *aO<br />

.set iCU-1PS,20 *aO<br />

.set icu-pdir,21 *aO<br />

.set 1Cu-cctl,22 *aO<br />

.set 1CU:C1ctl,23 *aO<br />

.set 1cu_addr,OxftfeOO<br />

t************************* STATIC BASE<br />

.set irl mod, 17*4<br />

• set sbut, Oxle<br />

.set rbuf, Ox41e<br />

.set cbuf, Ox61e<br />

.set intabl., Ox81e<br />

#********************** SET UP DISPATCH<br />

start::<br />

b1cpsrw $(OxlOO)<br />

movd $OxOc,rO<br />

movd $Ox055555555,rl<br />

addr 1ntable(sb),r2<br />

movd $OxOc,r3<br />

svc<br />

sprd 1ntbase,r2<br />

mova 1srent,irl_mod(r2)<br />

t<br />

* i<br />

•<br />

I<br />

i<br />

t<br />

i<br />

#<br />

tFirst ICU register addre~s<br />

t<br />

•<br />

• tDispatch table offset for IRl entry<br />

'sbuf = area used to<br />

tstore data to be transmitted, rbuf<br />

tarea used to store rece1ved data,<br />

tcbuf = area used to store compare<br />

.buffer, 1ntable = base po1nter to the<br />

iinterrupt table<br />

#<br />

TABLE FOR THE 32032 ********************<br />

STARTING LOCATIONS **********************<br />

•#Clear 1ntr's<br />

tset for monitor svc to move 1ntbase<br />

,from ROM to ram becauae you have<br />

tto change the address for the<br />

.interrupt service routine.<br />

tActual svc for move<br />

tPut base addr of 1ntbase in r2<br />

IPut offset of isr into 1st location<br />

tof dispatch table<br />

t<br />

#w******************** LOAD TRANSMITTER BUFFER (FF to 00) **********************<br />

t<br />

senddat: addr sbuf(sb),rO tRO contains str1ng buffer ptr.<br />

movd $O,rl<br />

IRl conta1ns offset<br />

movb $OxOtt,r2 Unit data reg.<br />

sbufloop: movb r2,O(rO)[rl:b] iLoad char. to string buffer<br />

addqw l,rl<br />

tIncrQment offset ptr.<br />

subb $l,r2<br />

IIncrement data<br />

cmpw r.1,$256<br />

.Check for 256 chars. loaded<br />

bne sbufloop<br />

#Jump back 1f not done<br />

I<br />

t*********************** LOAD COMPARISON BUFFER (00 TO FF) *********************<br />

i<br />

compdat: addr cbuf (sb) , rO tRO conta1ns pointer<br />

movd $O,rl<br />

tRl contains offset<br />

movb $O,r2<br />

Unit data reg.<br />

Cbufloop: movb r2,O(rO)[rl:b] tLoad char. to compare buffer<br />

addqw l,rl<br />

IIncrement ptr. offset<br />

addqw l,r2<br />

IDecrement data<br />

cmpw r.1,$256<br />

'Check for 256 chars. loaded<br />

bne Cbufloop<br />

tJump back if not done<br />

i<br />

t*************** SET UP INTERRUPT SERVICE ROUTINE PARAMETERS *******************<br />

movd $16,blk16cnt<br />

I<br />

iInitialize 16 byte block counter<br />

TL/C/9313-21<br />

4-80

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!