home *** CD-ROM | disk | FTP | other *** search
- 100 rem save"0:relocate",8
- 105 rem ** rte/85 - allows quick change of prg load address **
- 110 :
- 115 z$=chr$(0)
- 120 print "drive type:"
- 125 input "1)1541/2031, 2)4040, 3)8050/8250";d: if d<1 or d>3 then 125
- 130 if d=1 then dl=144: dh=2: di=4: dt=18: bl=0: bh=3: rem 1541/2031
- 135 if d=2 then dl=150: dh=67: di=4: dt=18: bl=0: bh=17: rem 2040/4040
- 140 if d=3 then dl=96: dh=67: di=8: dt=39: bl=0: bh=17: rem 8050/8250
- 145 :
- 150 input "drive #, filename ";dr,f$: f$=str$(dr)+":"+f$
- 155 input "new start address (decimal) ";sa: sh%=sa/256: sl=sa-256*sh%
- 160 open 15,8,15: open 8,8,8,(f$): get#8,a$: if st then close8: stop
- 165 print#15,"m-r"chr$(dl)chr$(dh): get#15,s$: rem sector
- 170 print#15,"m-r"chr$(dl+di)chr$(dh): get#15,i$: rem index
- 175 s=asc(s$+z$): i=asc(i$+z$)+1
- 180 close 8: open 8,8,8,"#0"
- 185 print#15,"u1:"8;dr;dt;s: rem read in directory track/sector
- 190 print#15,"m-r"chr$(bl+i)chr$(bh)chr$(2): rem get 1st data block ptr
- 195 get#15,t$,s$: t=asc(t$+z$): s=asc(s$+z$)
- 200 print#15,"u1:"8;dr;t;s: rem get first data block
- 205 print#15,"m-w"chr$(bl+2)chr$(bh)chr$(2)chr$(sl)chr$(sh%)
- 210 print#15,"u2:"8;dr;t;s: rem write block back
- 215 close 8: close 15
- 220 print "** address changed **"
- 225 end
-