Last change
on this file since 9519422 was 4f508e6, checked in by Thomas Lopatic <thomas@…>, 7 years ago |
Converted assembly language files.
|
-
Property mode
set to
100644
|
File size:
897 bytes
|
Rev | Line | |
---|
[4f508e6] | 1 | | ------------------------------------------------------------------------------
|
---|
| 2 | | ptcl12.s -- store a cluster entry into the FAT
|
---|
| 3 | | Version 2 -- 1987-10-27 -- D.N. Lynx Crowe
|
---|
| 4 | | ------------------------------------------------------------------------------
|
---|
[f40a309] | 5 | .text
|
---|
| 6 | .xdef __ptcl12
|
---|
[4f508e6] | 7 |
|
---|
| 8 | CL = 12
|
---|
| 9 | VAL = 14
|
---|
| 10 | CLA = d7
|
---|
| 11 | CLP = d6
|
---|
| 12 | CLT = d5
|
---|
| 13 | FAT = a5
|
---|
| 14 |
|
---|
[f40a309] | 15 | __ptcl12: link A6,#0
|
---|
| 16 | movem.l CLT-CLA/FAT-FAT,-(sp)
|
---|
| 17 | move.l 8(A6),FAT
|
---|
| 18 | move.w CL(A6),CLA
|
---|
[4f508e6] | 19 | lsr.w #1,CLA
|
---|
[f40a309] | 20 | add.w CL(A6),CLA
|
---|
| 21 | move.b 1(FAT,CLA.W),CLP
|
---|
| 22 | lsl.w #8,CLP
|
---|
| 23 | move.b 0(FAT,CLA.W),CLP
|
---|
| 24 | btst #0,CL+1(A6)
|
---|
| 25 | beq L2
|
---|
[4f508e6] | 26 |
|
---|
[f40a309] | 27 | move.w CLP,CLT
|
---|
[4f508e6] | 28 | and.w #0x000F,CLT
|
---|
[f40a309] | 29 | move.w VAL(A6),D0
|
---|
| 30 | lsl.w #4,D0
|
---|
| 31 | or.w D0,CLT
|
---|
| 32 | bra L3
|
---|
[4f508e6] | 33 |
|
---|
[f40a309] | 34 | L2: move.w CLP,CLT
|
---|
[4f508e6] | 35 | and.w #0xF000,CLT
|
---|
[f40a309] | 36 | move.w VAL(A6),D0
|
---|
[4f508e6] | 37 | and.w #0x0FFF,D0
|
---|
[f40a309] | 38 | or.w D0,CLT
|
---|
[4f508e6] | 39 |
|
---|
[f40a309] | 40 | L3: move.b CLT,0(FAT,CLA.W)
|
---|
| 41 | move.w CLT,D0
|
---|
| 42 | lsr.w #8,D0
|
---|
| 43 | move.b D0,1(FAT,CLA.W)
|
---|
[4f508e6] | 44 |
|
---|
[f40a309] | 45 | L1: movem.l (sp)+,CLT-CLA/FAT-FAT
|
---|
| 46 | unlk A6
|
---|
| 47 | rts
|
---|
[4f508e6] | 48 |
|
---|
[f40a309] | 49 | .end
|
---|
Note:
See
TracBrowser
for help on using the repository browser.