You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

copall.src 2.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. .page 'copy all'
  2. ;
  3. ; set up subroutine
  4. ;
  5. pups1 lda #0
  6. sta rec
  7. sta drvcnt
  8. sta filtrk
  9. sta filtrk+1
  10. lda fildrv+1 ; get drive number
  11. and #1 ; only
  12. sta drvnum
  13. ora #1
  14. sta delsec ; nonzero
  15. lda filtbl+1 ; fn1=fn2
  16. sta filtbl
  17. rts
  18. ;
  19. ;.end
  20. .page 'copy all'
  21. ;
  22. ; copy disk to disk routines
  23. ;
  24. ;cpydtd lda filtbl+1 ; save in temp
  25. ; sta temp
  26. ; ldy #40 ; 40 char buffer
  27. ; ldx cmdsiz ; prep to move
  28. ; sty cmdsiz ; end of filename2
  29. ;movlp1 dey
  30. ; dex
  31. ; lda cmdbuf,x ; mov fn lifo
  32. ; sta cmdbuf,y
  33. ; cpx temp ; actual f2 val
  34. ; bne movlp1
  35. ; sty filtbl+1 ; pointer to f2
  36. ;movlp2 jsr optsch
  37. ; jsr pups1 ; setup first pass
  38. ; jsr ffst ; first match
  39. ; bpl fixit ; entry found?
  40. ; bmi endit ; no
  41. ;;
  42. ;exlp0 pla ; pull needed vars
  43. ; sta dirsec
  44. ; pla
  45. ; sta filtbl+1
  46. ; pla
  47. ; sta lstbuf
  48. ; pla
  49. ; sta filcnt
  50. ; pla
  51. ; sta index
  52. ; pla
  53. ; sta found
  54. ; pla
  55. ; sta delind
  56. ; pla
  57. ; sta drvflg
  58. ;;
  59. ;exlp1 jsr pups1 ; set up vars
  60. ; jsr ffre ; next match
  61. ; bpl fixit ; found one?
  62. ;endit jmp endcmd ; no! so bye
  63. ;;
  64. ;fixit lda drvflg ; push needed vars
  65. ; pha
  66. ; lda delind
  67. ; pha
  68. ; lda found
  69. ; pha
  70. ; lda index
  71. ; pha
  72. ; lda filcnt
  73. ; pha
  74. ; lda lstbuf
  75. ; pha
  76. ; lda filtbl+1
  77. ; pha
  78. ; lda dirsec
  79. ; pha
  80. ;;
  81. ;exlp2 jsr trfnme ; transfer name
  82. ; lda #1 ; fake out lookup
  83. ; sta f1cnt
  84. ; sta f2cnt
  85. ; jsr lookup
  86. ; lda #1
  87. ; sta f1cnt
  88. ; lda #2 ; real
  89. ; sta f2cnt
  90. ; jsr cy ; copy it
  91. ; jmp exlp0 ; next one folks
  92. ;;
  93. ;; transfer name (dirbuf) to cmdbuf
  94. ;;
  95. ;trfnme ldy #3 ; both indexes
  96. ; sty filtbl ; begining of filename1
  97. ;trf0 lda (dirbuf),y ; move it
  98. ; sta cmdbuf,y
  99. ; iny
  100. ; cpy #19 ; all 16 chars passed?
  101. ; bne trf0
  102. ; rts
  103. ;;.end