[Copyright 1999,2002,2014 Frank Durda IV, All Rights Reserved. Mirroring of any material on this page in any form is expressly prohibited. The official web site for this material is: http://nemesis.lonestar.org Contact this address for use clearances: clearance_2014 at nemesis.lonestar.org Comments and queries to this address: web_software_2014 at nemesis.lonestar.org]
MISOSYS EDAS-4.3 04/11/99 00:03:36 COPY/APPEND - LS-DOS 6.3 Page 00001 00001 ;LBCOPY/ASM - Copy/Append Commands 00003 ; 0000 00004 *GET BUILDVER:3 00005 ; 00006 ; Buildver/asm is a bit of a kludge since not all utilities can load 00007 ; equates from LDOS60 and still compile. LOWCORE and everybody else 00008 ; relies on this setting, and it eventually ends up in LDOS60/EQU 00009 ; for programs that can use that. 00010 ; FFFF 00011 @BLD631 EQU -1 ;<631>Build 631 distribution (LEVEL 1B) 00012 ; These switches activate patches made since the 1B release. 00013 ; It is important that all earlier patches be enabled when a higher 00014 ; patch is enabled. 00015 ; Patches C thru F were published in TMQ IV.iv, page 32 (NOTE: the 00016 ; patch addresses listed for SPOOL in SPOOL1/FIX are 19H high.) FFFF 00017 @BLD631C EQU -1 ;<631>Apply 1C patches (SETKI) FFFF 00018 @BLD631D EQU -1 ;<631>Apply 1D patches (DIR) FFFF 00019 @BLD631E EQU -1 ;<631>Apply 1E patches (DIR & MEMDISK/DCT) FFFF 00020 @BLD631F EQU -1 ;<631>Apply 1F patches (SPOOL) 00021 ; Patches G and H were published in TMQ V.i, pages 10 and 18/19. FFFF 00022 @BLD631G EQU -1 ;<631>Apply 1G patches (//KEYIN,DIR,DO *) FFFF 00023 @BLD631H EQU -1 ;<631>Apply 1H patches (MEMORY) 00024 ; 00025 ;End of BUILDVER/ASM 0000 00026 *GET SVCMAC:3 00027 ;SVCMAC/ASM - LS-DOS Version VI 00028 *LIST OFF 00420 *LIST ON 0000 00422 *GET VALUES:3 00423 ;VALUES/ASM - Version 6 00424 *LIST OFF 00451 *LIST ON 00452 ; 001E 00453 EL EQU 30 ;Erase Line 001D 00454 BL EQU 29 ;Beginning of Line 003A 00455 @INIT EQU 58 ;@INIT SVC # 003B 00456 @OPEN EQU 59 ;@OPEN SVC # 0080 00457 BREAK EQU 80H ;BREAK character 00458 ; 2400 00459 ORG 2400H 00460 ; 2400 00461 *GET LBCOPYA:3 00462 ;LBCOPYA/ASM - Copy/Append commands 00465 ; 00466 ; Jump to COPY Entry Point 00467 ; 2400 C3F424 00468 COPY JP COPYST ;Go to COPY 00469 ; 00470 ; APPEND Entry Point - Was thehit ? 00471 ; 00472 APPEND 00473 IF @BLD631 2403 ED732324 00474 LD (SAVESP+1),SP ;<631>Save SP address 00475 ENDIF 2407 00476 @@CKBRKC ;Check for break 2407+3E6A 00477 LD A,106 2409+EF 00478 RST 40 00479 IF @BLD631 240A 203D 00480 JR NZ,ABORT ;<631>Abort 00481 ELSE 00482 JR Z,APPENDA ;Continue if not 00483 LD HL,-1 ; else abort 00484 RET 00485 ; 00486 ; not hit - Execute Module 00487 ; 00488 APPENDA 00489 LD (SAVESP+1),SP ;Save SP address 00490 ENDIF 240C CD4E24 00491 CALL APCODE ;Call Append code 240F 210000 00492 EXIT LD HL,0 ;Good exit 2412 180E 00493 JR SAVESP 00494 ; 00495 ; I/O Error Display & Abort Routine 00496 ; 2414 F5 00497 IOERR PUSH AF ;Save error code 2415 CD6629 00498 CALL PMTSYS ;Prompt SYSTEM Disk 2418 F1 00499 POP AF ;Rcvr error code 2419 6F 00500 LD L,A ;Xfer any error to HL 241A 2600 00501 LD H,0 241C F6C0 00502 OR 0C0H ;Set for abbrev error msg 241E 4F 00503 LD C,A ;Save Error # in C 241F 00504 @@ERROR ;Display & abort 241F+3E1A 00505 LD A,26 2421+EF 00506 RST 40 00507 IF @BLD631 00508 ; 00509 ; P/u Stack, clear any & return 00510 ; 2422 310000 00511 SAVESP LD SP,$-$ ;<631>P/u stack 2425 00512 @@CKBRKC ;<631>Clear any 2425+3E6A 00513 LD A,106 2427+EF 00514 RST 40 2428 C9 00515 RET ;<631> and RETurn 00516 ELSE 00517 JR SAVESP ;Good bye 00518 ENDIF 00519 ; 00520 ; Load HL with error message string to display 00521 ; 2429 21192B 00522 SAMERR LD HL,SAMERR$ ;"Source & Dest same" 242C DD 00523 DB 0DDH 242D 21DF2A 00524 SPCREQ LD HL,SPCREQ$ ;"File spec required" 2430 DD 00525 DB 0DDH 2431 21F22A 00526 NOINDO LD HL,NOINDO$ ;"Invalid during " 2434 DD 00527 DB 0DDH 2435 21992A 00528 DIFLRL LD HL,DIFLRL$ ;"Files have diff LRLs" 2438 DD 00529 DB 0DDH 2439 21B32A 00530 DSTREQ LD HL,DSTREQ$ ;"Dest spec Required" 243C 00531 @@LOGOT ;Log error message 00532 IFEQ 00H,1 00533 LD HL, 00534 ENDIF 243C+3E0C 00535 LD A,12 243E+EF 00536 RST 40 00537 ; 00538 ; Attempt to close any OPEN destination file 00539 ; 243F 11032C 00540 LD DE,FCB2 ;Point to dest FCB 2442 1A 00541 LD A,(DE) ;Is the file OPEN? 2443 07 00542 RLCA 2444 3003 00543 JR NC,ABORT ;No - abort 2446 00544 @@CLOSE 2446+3E3C 00545 LD A,60 2448+EF 00546 RST 40 2449 21FFFF 00547 ABORT LD HL,-1 ;Abort code to HL 00548 IF @BLD631 244C 18D4 00549 JR SAVESP ;<631> 00550 ELSE 00551 ; 00552 ; P/u Stack, clear any & return 00553 ; 00554 SAVESP LD SP,$-$ ;P/u stack 00555 @@CKBRKC ;Clear any 00556 RET ; and RETurn 00557 ENDIF 00558 ; 00559 ; APCODE - Append spec to spec 00560 ; 00561 APCODE 244E AF 00562 XOR A ;Turn off CLONE parm 244F 32A926 00563 LD (CPARM+1),A 2452 32AA26 00564 LD (CPARM+2),A 2455 32B228 00565 LD (APPFLAG+1),A ;We're in APPEND not COPY 00566 ; 2458 CD0529 00567 CALL DOINIT ;Set High memory 00568 ; 00569 ; Check if Filespec/Devspec #1 is legal 00570 ; 245B 11572C 00571 LD DE,FCB1 ;DE => File #1 FCB 245E 00572 @@FSPEC ;Check out filespec 245E+3E4E 00573 LD A,78 2460+EF 00574 RST 40 2461 C22D24 00575 JP NZ,SPCREQ ;NZ - Filespec Required 00576 ; 00577 ; Check if Filespec/Devspec #2 is legal 00578 ; 2464 11032C 00579 LD DE,FCB2 ;DE => File #2 FCB 2467 00580 @@FSPEC ;Check if legal 2467+3E4E 00581 LD A,78 2469+EF 00582 RST 40 246A C46A27 00583 CALL NZ,CVRTUC ;Convert line to U/C 00584 ; 00585 ; Is the second FCB a device ? 00586 ; 246D 3A032C 00587 APND1 LD A,(FCB2) ;P/u byte 0 of FCB2 2470 FE2A 00588 CP '*' ;Is this a devspec ? 2472 CA2D24 00589 JP Z,SPCREQ ;Z - Filespec required 00590 ; 00591 ; Parse any parameters entered 00592 ; 2475 11D12B 00593 LD DE,APPTBL ;DE => Parameter Table 2478 00594 @@PARAM ;Check out parameters 2478+3E11 00595 LD A,17 247A+EF 00596 RST 40 247B C21424 00597 JP NZ,IOERR ;NZ - Parameter Error 00598 ; 247E CD9427 00599 CALL PRSPC ;P/u FCB ptr in DE 00600 ; 00601 ; Open Filespec #2 with LRL of 256 00602 ; 2481 CD752A 00603 CALL OPENSR2 ;Open Filespec #2 2484 CD9B28 00604 CALL PUTDEST ;Xfer Dest filespec 2487 CDD028 00605 CALL GETLRL ;Get LRL from DIR entry 00606 ; 248A 32A324 00607 LD (LRL2+1),A ;Set dir LRL into parm 248D 32A626 00608 LD (GEOF1+1),A ;Also stuff for later 00609 ; 00610 ; Open Filespec #1 with LRL of 256 00611 ; 2490 CD6B2A 00612 CALL OPENSRC ;Open Filespec #1 2493 CD9528 00613 CALL PUTSOUR ;Xfer source filespec 00614 ; 00615 ; Is the Source a Device ? 00616 ; 2496 EB 00617 EX DE,HL 2497 CB7E 00618 BIT 7,(HL) ;P/u FCB+0 of source 2499 EB 00619 EX DE,HL ;Device ? 249A CCAC28 00620 CALL Z,CPYFILE ;Display "Appending ..." 249D 2819 00621 JR Z,APND2 ;Yes - don't check LRLs 00622 ; 00623 ; File Source - Check if LRLs are different 00624 ; 249F CDD028 00625 CALL GETLRL ;P/u LRL of Filespec #1 24A2 0600 00626 LRL2 LD B,$-$ ;P/u LRL of Filespec #2 24A4 A8 00627 XOR B ;Same ? 24A5 C23524 00628 JP NZ,DIFLRL ;No - Different LRLs 24A8 CDAC28 00629 CALL CPYFILE ;"Appending : " 00630 ; 00631 ; Files have same LRLs, check STRIP parameter 00632 ; 24AB 110000 00633 SPARM LD DE,$-$ ;P/u strip parameter 24AE 7A 00634 LD A,D ;If STRIP, then must do 24AF B3 00635 OR E ; byte I/O 24B0 2006 00636 JR NZ,APND2 ;Go if STRIP 00637 ; 00638 ; Pick up End of File offset byte from FCB 00639 ; 24B2 3A0B2C 00640 LD A,(FCB2+8) ;Get eof mark 24B5 B7 00641 OR A ;If full sectors, use 24B6 281F 00642 JR Z,APND3 ;Sector I/O 00643 ; 00644 ; EOF not on page boundary - use byte I/O 00645 ; 24B8 11032C 00646 APND2 LD DE,FCB2 24BB 00647 @@PEOF ;Position to end of file 24BB+3E41 00648 LD A,65 24BD+EF 00649 RST 40 00650 ; 00651 ; If STRIP, then backspace the dest by 1 byte 00652 ; 24BE 3AAC24 00653 LD A,(SPARM+1) ;P/u SPARM 24C1 B7 00654 OR A ;Specified ? 24C2 280A 00655 JR Z,APND2A ;No - don't backspace 00656 ; 00657 ; SPARM specified - Backspace one byte 00658 ; 24C4 210C2C 00659 LD HL,FCB2+9 ;HL => LRL of FCB #2 24C7 46 00660 LD B,(HL) ;P/u current dest LRL 24C8 3601 00661 LD (HL),1 ;Reset LRL=1 24CA 00662 @@BKSP ;Backspace 1 byte 24CA+3E3D 00663 LD A,61 24CC+EF 00664 RST 40 24CD 70 00665 LD (HL),B ;Reset LRL back 00666 ; 00667 ; Replace the I/O buffer in FCB #2 00668 ; 24CE 21002F 00669 APND2A LD HL,BUF2 ;HL => New buffer addr 24D1 22062C 00670 LD (FCB2+3),HL ;Stuff in FCB 24D4 C32E27 00671 JP BYTIO0 ; 00672 ; 00673 ; EOF on page boundary, use sector I/O 00674 ; 24D7 ED4B632C 00675 APND3 LD BC,(FCB1+12) ;P/u ERN of source 24DB 78 00676 LD A,B ;If source is a null 24DC B1 00677 OR C ; file, don't do any 24DD CADD26 00678 JP Z,GEOF3 ; appending, just close 00679 ; 00680 ; Write Ending Record Number 00681 ; 24E0 2A0F2C 00682 LD HL,(FCB2+12) ;P/u ERN of dest 24E3 E5 00683 PUSH HL ;Save it for later 24E4 09 00684 ADD HL,BC ;Add the two to find new 24E5 44 00685 LD B,H ; ERN & Xfer new ERN to BC 24E6 4D 00686 LD C,L 24E7 CDEF26 00687 CALL WRERN ;Write a data sector 24EA E1 00688 POP HL ;Recover original ERN 24EB 220F2C 00689 LD (FCB2+12),HL ; & reset FCB to it 24EE 00690 @@PEOF ;Position to end of file 24EE+3E41 00691 LD A,65 24F0+EF 00692 RST 40 24F1 C33A26 00693 JP XFER5 00696 ; 00697 ; COPY Entry Point - was hit ? 00698 ; 00699 COPYST 00700 IF @BLD631 24F4 ED732324 00701 LD (SAVESP+1),SP ;<631>Save SP address 00702 ENDIF 24F8 00703 @@CKBRKC ;Check for break 24F8+3E6A 00704 LD A,106 24FA+EF 00705 RST 40 00706 IF @BLD631 24FB C24924 00707 JP NZ,ABORT ;<631> 00708 ELSE 00709 JR Z,COPYSTA ;Continue if not 00710 LD HL,-1 ; else abort 00711 RET 00712 ; 00713 ; not hit - execute module 00714 ; 00715 COPYSTA LD (SAVESP+1),SP ;Save SP address 00716 ENDIF 24FE CD0425 00717 CALL COPYCD ;Execute Copy code 2501 C30F24 00718 JP EXIT ;Go to common exit 00719 ; 00720 ; COPYCD - Copy spec to spec 00721 ; 00722 COPYCD 2504 CD0529 00723 CALL DOINIT ;Set high mem test byte 00724 ; 00725 ; Check if Source Filespec is legal 00726 ; 2507 11572C 00727 LD DE,FCB1 ;DE => Source FCB 250A 00728 @@FSPEC ;Check out filespec 250A+3E4E 00729 LD A,78 250C+EF 00730 RST 40 250D C22D24 00731 JP NZ,SPCREQ ;NZ - Filespec required 00732 ; 00733 ; Check if Destination Filespec is legal 00734 ; 2510 11032C 00735 LD DE,FCB2 ;DE => Destination FCB 2513 00736 @@FSPEC ;Check out filespec 2513+3E4E 00737 LD A,78 2515+EF 00738 RST 40 2516 C46A27 00739 CALL NZ,CVRTUC ;Convert line to U/C 00740 ; 00741 ; Process any parameters entered 00742 ; 2519 11E42B 00743 COPY1 LD DE,COPYTBL ;DE => Parameter Table 251C 00744 @@PARAM ;Check out parameters 251C+3E11 00745 LD A,17 251E+EF 00746 RST 40 251F C21424 00747 JP NZ,IOERR ;NZ - Parameter Error 00748 ; 00749 ; Test if X parameter was entered 00750 ; 2522 110000 00751 XPARM LD DE,$-$ ;P/u (X) parm - We don't 2525 7A 00752 LD A,D ; XFER devices 2526 B3 00753 OR E ; 2527 200B 00754 JR NZ,XFER ; 00755 ; 00756 ; Is the Source or Destination a device ? 00757 ; 2529 CD3A2A 00758 CALL CKDEV ;Device ? 252C CA0F27 00759 JP Z,BYTEIO ;Yes - use byte I/O 00760 ; 00761 ; Pick up Defaults for source and destination 00762 ; 252F CD9427 00763 CALL PRSPC ;P/u defaults 2532 185B 00764 JR OPNSRC 00765 ; 00766 ; XFER initialization code 00767 ; 2534 00768 XFER @@FLAGS ;Position IY to flags 2534+3E65 00769 LD A,101 2536+EF 00770 RST 40 2537 FDCB126E 00771 BIT 5,(IY+SFLAG$) ;DO in Effect ? 253B C23124 00772 JP NZ,NOINDO ;Yes - abort 00773 ; 00774 ; If the Source or Dest is a Device - abort 00775 ; 253E CD3A2A 00776 CALL CKDEV ;Device ? 2541 CA2D24 00777 JP Z,SPCREQ ;Yes - Filespecs required 00778 ; 00779 ; P/u Drivespec of Source Filespec if entered 00780 ; 2544 21572C 00781 LD HL,FCB1 ;HL => FCB #1 2547 0E00 00782 LD C,0 ;Init to drive zero 00783 ; 00784 ; Loop to Pick up Drive # or terminator 00785 ; 2549 7E 00786 XFER1 LD A,(HL) ;Look for drive spec 254A 23 00787 INC HL 254B FE3A 00788 CP ':' ;Colon indicator? 254D 2806 00789 JR Z,XFER2 ;Jump if found 254F FE20 00790 CP ' ' ;Jump on end 2551 3806 00791 JR C,XFER3 2553 18F4 00792 JR XFER1 ;Loop 00793 ; 00794 ; Colon indicator present - p/u drive # 00795 ; 2555 7E 00796 XFER2 LD A,(HL) ;P/u user drive 2556 D630 00797 SUB '0' ;Cvrt to binary 2558 4F 00798 LD C,A ; & stuff in C 00799 ; 00800 ; Save Source drive number 00801 ; 2559 216C29 00802 XFER3 LD HL,XFRDRV+1 ;HL => Drive # 255C 71 00803 LD (HL),C ;Save drive # for later 00804 ; 00805 ; Stuff drive # into Prompt strings 00806 ; 255D 3E30 00807 LD A,'0' ;Cvt drive # to ASCII 255F 81 00808 ADD A,C 2560 32822B 00809 LD (SRC_DR),A ;Source Drive # 2563 32BC2B 00810 LD (DEST_DR),A ;Destination Drive # 00811 ; 00812 ; Transfer source FCB to destination FCB 00813 ; 2566 21572C 00814 LD HL,FCB1 ;HL => Source FCB 2569 11032C 00815 LD DE,FCB2 ;DE => Destination FCB 256C 012000 00816 LD BC,32 ;32 bytes to Xfer 256F EDB0 00817 LDIR ;Xfer 00818 ; 2571 CD342A 00819 CALL GETSYS2 ;Load SYS2 for OPEN 00820 ; 00821 ; Flash "Insert Source Disk" Message 00822 ; 2574 21622B 00823 LD HL,PMTSRC$ ;Prompt for source 2577 CDC729 00824 CALL FLASH ; and wait for 00825 ; 00826 ; Read in the GAT of the source disk 00827 ; 257A 3A6C29 00828 LD A,(XFRDRV+1) ;P/u source drive 257D 4F 00829 LD C,A ;Stuff in C 257E CD462A 00830 CALL RDGAT ;Read in GAT 2581 C21424 00831 JP NZ,IOERR ;Abort on GAT error 00832 ; 00833 ; Xfer Password, Name, & Date to destination 00834 ; 2584 21CE2D 00835 LD HL,GAT+0CEH ;Disk pw, name, date 2587 11772C 00836 LD DE,SRCSTR ;DE => Destination 258A 011200 00837 LD BC,18 258D EDB0 00838 LDIR ;Xfer 00839 ; 00840 ; OPEN the Source File with LRL of 256 00841 ; 258F CD6B2A 00842 OPNSRC CALL OPENSRC ;Open source file 2592 CD9528 00843 CALL PUTSOUR ;Xfer source filespec 2595 CDDF28 00844 CALL GETCLON ;Get clone data 2598 3A5D2C 00845 LD A,(FCB1+6) ;Get source drive 259B E607 00846 AND 7 259D CDFC28 00847 CALL WHATBIT ;Make into bit instr. 25A0 32A725 00848 LD (SRCBIT),A 25A3 3A0000 00849 LD A,($-$) ;See if new type year 25A4 00850 YFLAG1 EQU $-2 25A6 CB 00851 DB 0CBH ;Bit x,A 25A7 00 00852 SRCBIT DB 0 25A8 2005 00853 JR NZ,NEWD1 ;Source is new, done 25AA 3EFF 00854 LD A,-1 ;Else mark old source 25AC 32C426 00855 LD (CKTYP),A 00856 ; 00857 ; Pick up Source LRL 00858 ; 25AF 7D 00859 NEWD1 LD A,L ;Pt back to LRL of source 25B0 D610 00860 SUB 16 25B2 6F 00861 LD L,A 25B3 7E 00862 LD A,(HL) ;P/u source LRL 00863 ; 00864 ; Save LRL from source FCB or LRL Parameter 00865 ; 25B4 0100FF 00866 LPARM LD BC,0FF00H ;P/u LRL 25B7 04 00867 INC B 25B8 2001 00868 JR NZ,USEREGC ;If parm entered, use it 25BA 4F 00869 LD C,A 25BB 21A626 00870 USEREGC LD HL,GEOF1+1 ;HL => stuff LRL here 25BE 71 00871 LD (HL),C ;Stuff LRL for close here 00872 ; 00873 ; Ignore this if not COPY (X) 00874 ; 25BF 3A2325 00875 LD A,(XPARM+1) ;Bypass if not (X) 25C2 B7 00876 OR A 25C3 282D 00877 JR Z,OPNDST 00878 ; 00879 ; Flash "Insert Destination Disk" message 00880 ; 25C5 21972B 00881 LD HL,PMTDST$ ;Prompt destination 25C8 CDC729 00882 CALL FLASH ;Flash until loaded 00883 ; 00884 ; Read in GAT of Destination Disk 00885 ; 25CB 3A6C29 00886 LD A,(XFRDRV+1) ;P/u drive 25CE 4F 00887 LD C,A ;Read GAT from dest 25CF CD462A 00888 CALL RDGAT 25D2 C21424 00889 JP NZ,IOERR ;Jump on GAT read error 00890 ; 00891 ; Xfer Name, Password & Date to destination 00892 ; 25D5 21CE2D 00893 LD HL,GAT+0CEH ;HL => GAT + X'CE' 25D8 11892C 00894 LD DE,DSTSTR ;DE => Destination 25DB 011200 00895 LD BC,18 ;To match up when 25DE D5 00896 PUSH DE 25DF EDB0 00897 LDIR ; swapping disks 25E1 D1 00898 POP DE ;Restore Dest ptr 00899 ; 00900 ; Check if Source ID = Destination ID 00901 ; 25E2 21772C 00902 LD HL,SRCSTR ;Compare source & dest 25E5 0612 00903 LD B,18 ;CANNOT be same 25E7 CDBC29 00904 CALL CPRHLDE ;Ck MPW, PackID, Date 25EA 2006 00905 JR NZ,OPNDST ;Bypass if different 00906 ; 00907 ; Display "Source & Dest. Disks Identical" 00908 ; 25EC CD6629 00909 CALL PMTSYS ;Prompt for SYSTEM 25EF C32924 00910 JP SAMERR ;Disk packs are identical 00911 ; 00912 ; OPEN the destination File 00913 ; 25F2 11032C 00914 OPNDST LD DE,FCB2 ;DE => FCB #2 25F5 21002E 00915 LD HL,BUF1 ;HL => I/O buffer #1 25F8 CD672A 00916 CALL INITDES ;Init the file 25FB CD9B28 00917 CALL PUTDEST ;Xfer Dest filespec 25FE 3A092C 00918 LD A,(FCB2+6) ;Get dest drive 2601 E607 00919 AND 7 2603 CDFC28 00920 CALL WHATBIT ;Get bit instr. 2606 320D26 00921 LD (DSTBIT),A 2609 3A0000 00922 LD A,($-$) ;Get date type flag 260A 00923 YFLAG2 EQU $-2 260C CB 00924 DB 0CBH ;Bit x,A 260D 00 00925 DSTBIT DB 0 260E 2804 00926 JR Z,NEWD2 ;Go if dest old 2610 21C426 00927 LD HL,CKTYP ;Else indicate dest new 2613 34 00928 INC (HL) 00929 ; 00930 ; Check if X parm entered 00931 ; 2614 3A2325 00932 NEWD2 LD A,(XPARM+1) ;If (X), then source & 2617 B7 00933 OR A ; dest can be same file 2618 200D 00934 JR NZ,XF2 ;Bypass if (X) 00935 ; 00936 ; Does Source & Dest. have same DEC & drive # 00937 ; 261A 2A5D2C 00938 LD HL,(FCB1+6) ;If SRC & DST have same 261D ED5B092C 00939 LD DE,(FCB2+6) ; DEC & drive, they are 2621 AF 00940 XOR A ; identical, abort if so 2622 ED52 00941 SBC HL,DE 2624 CA3924 00942 JP Z,DSTREQ ;Same - dest spec needed 00943 ; 00944 ; Write revised ERN for space check 00945 ; 2627 CDAC28 00946 XF2 CALL CPYFILE ;"Copying : ..." 262A ED4B632C 00947 LD BC,(FCB1+12) ;P/u ESN 262E CDEF26 00948 CALL WRERN ;Write a FORMAT sector 00949 ; 00950 ; Reset Destination ESN to Zero 00951 ; 2631 210000 00952 LD HL,0 ;Rewind file 2634 220F2C 00953 LD (FCB2+12),HL ; 2637 00954 @@REW ;Rewind the file 2637+3E44 00955 LD A,68 2639+EF 00956 RST 40 00957 ; 263A CD7829 00958 XFER5 CALL PMTSRC ;Display "Insert source" 00959 ; 00960 ; Stuff Correct Buffer Address in Source FCB 00961 ; 263D 21002E 00962 LD HL,BUF1 ;Stuff in FCB 2640 225A2C 00963 RDREC1 LD (FCB1+3),HL ;Set buffer addr 00964 ; 00965 ; Read in a Source Sector 00966 ; 2643 11572C 00967 LD DE,FCB1 ;DE => Source FCB 2646 00968 @@READ ;Read a sector 2646+3E43 00969 LD A,67 2648+EF 00970 RST 40 2649 280B 00971 JR Z,RDREC2 ;Bypass if no error 00972 ; 00973 ; Some sort of I/O Error - Check it out 00974 ; 264B FE1C 00975 CP 1CH ;EOF? 264D 2827 00976 JR Z,GOTEOF 264F FE1D 00977 CP 1DH ;NRN>ERN? 2651 2823 00978 JR Z,GOTEOF 2653 C31424 00979 JP IOERR ;Abort 00980 ; 00981 ; Successful READ - is there enough memory ? 00982 ; 2656 24 00983 RDREC2 INC H ;Bump memory pointer 2657 7C 00984 LD A,H ;Go past top? 2658 FE00 00985 RDREC3 CP $-$ 265A 20E4 00986 JR NZ,RDREC1 ;Loop if not 00987 ; 00988 ; Read in all we could - display "Insert Dest" 00989 ; 265C CD9A29 00990 CALL PMTDST ;Get destination 00991 ; 00992 ; Stuff Source FCB buffer into Destination FCB 00993 ; 265F 21002E 00994 LD HL,BUF1 ;Set buffer start 2662 22062C 00995 RDREC4 LD (FCB2+3),HL 00996 ; 00997 ; Loop to WRITE Destination file 00998 ; 2665 11032C 00999 LD DE,FCB2 ;DE => Destination FCB 2668 01000 @@WRITE ;Write a sector 2668+3E4B 01001 LD A,75 266A+EF 01002 RST 40 266B C21424 01003 JP NZ,IOERR ;Jump on write error 01004 ; 01005 ; Bump memory ptr & check if finished 01006 ; 266E 24 01007 INC H ;Else bump memory pointer 266F 7C 01008 LD A,H ;At top? 2670 FE00 01009 RDREC5 CP $-$ 2672 20EE 01010 JR NZ,RDREC4 ;Loop if not 2674 18C4 01011 JR XFER5 ;Else go back to source 01012 ; 01013 ; Got EOF error from source - Write out EOF 01014 ; 2676 CD4229 01015 GOTEOF CALL GEOF5 ;Write any memory left 2679 2A5F2C 01016 LD HL,(FCB1+8) ;P/u EOF & LRL 267C 220B2C 01017 LD (FCB2+8),HL ;Xfer to FCB2 01018 ; 01019 ; Get @CLOSE module if needed 01020 ; 267F CD6629 01021 CALL PMTSYS ;Prompt SYSTEM if needed 2682 CD372A 01022 CALL GETSYS3 ;Load SYS3 for CLOSE 2685 3A6C29 01023 LD A,(XFRDRV+1) ;P/u drive # 2688 B7 01024 OR A ;Is it zero ? 2689 CC9A29 01025 CALL Z,PMTDST ;Get dest if drive 0 01026 ; 01027 ; Close the destination file 01028 ; 268C ED4B092C 01029 LD BC,(FCB2+6) ;P/u drive # & DEC 2690 11032C 01030 LD DE,FCB2 ;DE => Destin file FCB 2693 01031 @@CLOSE ;Close the dest file 2693+3E3C 01032 LD A,60 2695+EF 01033 RST 40 2696 C21424 01034 JP NZ,IOERR ;Jump on error 01035 ; 01036 ; Get the destination file directory record 01037 ; 2699 01038 @@DIRRD ;Get destin dir entry 2699+3E57 01039 LD A,87 269B+EF 01040 RST 40 269C C21424 01041 JP NZ,IOERR ;I/O error - abort 01042 ; 01043 ; Stuff New LRL into directory entry 01044 ; 269F C5 01045 PUSH BC ;Save drive & DEC 01046 ; 26A0 E5 01047 PUSH HL ;HL => DIR+0 of dest 26A1 3E04 01048 LD A,4 ;Posn to LRL byte 26A3 85 01049 ADD A,L ; 26A4 6F 01050 LD L,A ;HL => DIR+4 (LRL) 26A5 3600 01051 GEOF1 LD (HL),$-$ ;GEOF1+1 contains LRL 26A7 E1 01052 POP HL ;Restore HL 01053 ; 01054 ; Pick up the Clone Parameter 01055 ; 26A8 11FFFF 01056 CPARM LD DE,-1 ;Default = ON 26AB 7A 01057 LD A,D ;Was it changed ? 26AC B3 01058 OR E 26AD 2822 01059 JR Z,GEOF2 ;CLONE = N 01060 ; 01061 ; CLONE = Yes, Transfer Attributes & Date 01062 ; 26AF E5 01063 PUSH HL ;Save DIR+0 26B0 EB 01064 EX DE,HL 26B1 219B2C 01065 LD HL,CLONSAV ;HL => Attr, DE => DIR+0 26B4 010300 01066 LD BC,3 ;Move in prot/date, etc 26B7 EDB0 01067 LDIR 01068 ; 01069 ; Transfer Password fields to entry 01070 ; 26B9 3E0D 01071 LD A,13 ;Pt to dir pswd fields 26BB 83 01072 ADD A,E 26BC 5F 01073 LD E,A ;DE => DIR+16 26BD 0E04 01074 LD C,4 ;BC = 4 bytes to xfer 26BF EDB0 01075 LDIR 26C1 1B 01076 DEC DE ;Pt at new year, DIR+19 26C2 E1 01077 POP HL ;Get back DIR+0 26C3 3EFE 01078 LD A,0FEH ;Ck if old type to new 26C4 01079 CKTYP EQU $-1 26C5 B7 01080 OR A 26C6 2009 01081 JR NZ,GEOF2 ;Was not old to new 26C8 23 01082 INC HL ;Was old to new, change 26C9 23 01083 INC HL ; date/time 26CA 7E 01084 LD A,(HL) ;Get old year 26CB E607 01085 AND 7 26CD 12 01086 LD (DE),A ;Year to DIR+19 26CE 1B 01087 DEC DE 26CF AF 01088 XOR A ;Make time 0 26D0 12 01089 LD (DE),A ;Store in DIR+18 01090 ; 01091 ; Write out Directory entry 01092 ; 26D1 C1 01093 GEOF2 POP BC ;Rcvr drive & DEC 26D2 01094 @@DIRWR ;Write Sector with entry 26D2+3E58 01095 LD A,88 26D4+EF 01096 RST 40 26D5 180C 01097 JR GEOF4 ;Go to Error check 01098 ; 01099 ; CLOSE the destination file 01100 ; 26D7 21FFFF 01101 GEOF3A LD HL,-1 ;Abort JCL 26DA 22EA26 01102 LD (RETCOD+1),HL ; if hit 26DD 11032C 01103 GEOF3 LD DE,FCB2 ;DE => Destination FCB 26E0 01104 @@CLOSE ;Close the file 26E0+3E3C 01105 LD A,60 26E2+EF 01106 RST 40 26E3 C21424 01107 GEOF4 JP NZ,IOERR ;I/O Error - Abort 01108 ; 01109 ; Flash "Insert SYSTEM disk" & exit 01110 ; 26E6 CD6629 01111 GOHOME CALL PMTSYS ;Prompt SYSTEM if needed 26E9 210000 01112 RETCOD LD HL,$-$ ;P/u return code 0=good 26EC C32224 01113 JP SAVESP ;Finished 01114 ; 01115 ; WRERN - Write a format sector on FILE #2 01116 ; 26EF 11032C 01117 WRERN LD DE,FCB2 ;DE => File #2 FCB 26F2 78 01118 LD A,B ;Don't bother to write 26F3 B1 01119 OR C ; a sector if source 26F4 C8 01120 RET Z ; is empty 01121 ; 01122 ; Position to ERN of File #2 01123 ; 26F5 0B 01124 DEC BC ;Adj for ERN 26F6 01125 @@POSN ;Position to ERN 26F6+3E42 01126 LD A,66 26F8+EF 01127 RST 40 26F9 D5 01128 PUSH DE ;Save FCB ptr 01129 ; 01130 ; Fill a buffer of X'E5's 01131 ; 26FA 21002E 01132 LD HL,BUF1 ;HL => I/O buffer 26FD 11012E 01133 LD DE,BUF1+1 ;DE => I/O buffer+1 2700 01FF00 01134 LD BC,255 ;255+1 bytes to fill 2703 36E5 01135 LD (HL),0E5H ;Format byte = X'E5' 2705 EDB0 01136 LDIR ;Fill buffer 01137 ; 01138 ; Write ERN of File #2 01139 ; 2707 D1 01140 POP DE ;DE => FCB #2 2708 01141 @@WRITE ;Write sector 2708+3E4B 01142 LD A,75 270A+EF 01143 RST 40 270B C8 01144 RET Z ;RETurn if no error 270C C31424 01145 JP IOERR ;Error - abort 01146 ; 01147 ; BYTEIO - OPEN Source or dest using byte I/O 01148 ; 270F CD6B2A 01149 BYTEIO CALL OPENSRC ;OPEN source file 2712 CD9528 01150 CALL PUTSOUR ;Get source filespec 01151 ; 01152 ; INIT the dest device with LRL from parm 01153 ; 2715 3AB525 01154 LD A,(LPARM+1) ;P/u LRL from Parm 2718 47 01155 LD B,A ;Open destination 2719 11032C 01156 LD DE,FCB2 ;DE => FCB #2 271C 21002F 01157 LD HL,BUF2 ;Different buffer 271F 3E3A 01158 LD A,@INIT ;@INIT SVC # 2721 CD7C2A 01159 CALL GETFILE ;Issue it 2724 CD9B28 01160 CALL PUTDEST ;Get dest devspec 2727 CDAC28 01161 CALL CPYFILE ;"Copying/Appending : .." 272A AF 01162 XOR A ;Reset LRL = 0 272B 320C2C 01163 LD (FCB2+9),A ;For sector I/O 01164 ; 01165 ; Turn on cursor 01166 ; 272E 0E0E 01167 BYTIO0 LD C,14 ;Turn cursor on 2730 CD1A2A 01168 CALL DISPB ;Display byte 01169 ; 01170 ; BYTIO1 Loop - File - Dev, Dev - File, Dev - Dev 01171 ; Was the key hit ? 01172 ; 01173 BYTIO1 2733 CD6229 01174 CALL CKBRK ;Was the key 2736 C2D726 01175 E_O_F JP NZ,GEOF3A ; hit ???? 01176 ; 01177 ; The was not hit - get a character 01178 ; 2739 11572C 01179 LD DE,FCB1 ;DE => Source FCB 273C 01180 @@GET ;Get a byte 273C+3E03 01181 LD A,3 273E+EF 01182 RST 40 273F 280B 01183 JR Z,BYTIO4 ;Good - stuff it 01184 ; 01185 ; If Error # = 0, then try @GET again 01186 ; 2741 B7 01187 OR A ;Error # = 0 ? 2742 28EF 01188 JR Z,BYTIO1 ;Yes - @GET again 01189 ; 01190 ; Is the Error an "End of File" error ? 01191 ; 2744 FE1C 01192 CP 1CH ;EOF? 2746 CADD26 01193 JP Z,GEOF3 ;Yes - finished 2749 C31424 01194 JP IOERR ;I/O error - abort 01195 ; 01196 ; Was the source character a ? 01197 ; 274C FE80 01198 BYTIO4 CP BREAK ; character ? 274E 2007 01199 JR NZ,BYTIO4A ;No - @PUT it 01200 ; 01201 ; Source = --- is the BREAK bit set ? 01202 ; 2750 CD6229 01203 CALL CKBRK ; bit set ? 2753 20E1 01204 JR NZ,E_O_F ;Yes - stop 2755 3E80 01205 LD A,BREAK ;Restore A 01206 ; 01207 ; Output byte to destination 01208 ; 2757 11032C 01209 BYTIO4A LD DE,FCB2 ;DE => Dest. Device/File 275A 4F 01210 LD C,A ;Stuff byte in C for @PUT 275B 01211 @@PUT ;Output byte 275B+3E04 01212 LD A,4 275D+EF 01213 RST 40 275E C21424 01214 JP NZ,IOERR ;NZ - I/O Error 01215 ; 01216 ; Echo byte if parameter set 01217 ; 2761 110000 01218 EPARM LD DE,$-$ ;P/u ECHO parm 2764 14 01219 INC D ;Specified ? 2765 CC1A2A 01220 CALL Z,DISPB ;Echo byte 2768 18C9 01221 JR BYTIO1 ;Go til EOF or BREAK 01222 ; 276A 01223 *GET LBCOPYB:3 01224 ;LBCOPYB/ASM - COPY/APPEND Common Routines 01227 ; 01228 ; CVRTUC - Transfer partspec & convert to U/C 01229 ; HL => Buffer containing characters to parse 01230 ; DE => Destination of converted line 01231 ; 276A CD7227 01232 CVRTUC CALL CVRT ;Convert line 276D 3E0D 01233 LD A,CR ;Ensure end-of-line 276F 12 01234 LD (DE),A ; with a carriage return 2770 C9 01235 RET 01236 ; 01237 ; Position to First non-space character 01238 ; 2771 23 01239 CVRT0 INC HL 2772 7E 01240 CVRT LD A,(HL) ;P/u possible dest char 2773 FE0D 01241 CP CR ;Exit on CR 2775 C8 01242 RET Z 2776 FE20 01243 CP ' ' ;Loop on space 2778 28F7 01244 JR Z,CVRT0 277A 2B 01245 DEC HL ;Backup to 1st separator 01246 ; 01247 ; HL => Filespec or Devspec, convert to U/C 01248 ; 277B 0620 01249 LD B,32 ;Max 32 chars 277D 7E 01250 COP1 LD A,(HL) ;Transfer the partial 277E FE61 01251 CP 'a' ;Cvrt lc to uc 2780 3806 01252 JR C,COP2 2782 FE7B 01253 CP 'z'+1 2784 3002 01254 JR NC,COP2 2786 CBAF 01255 RES 5,A 2788 12 01256 COP2 LD (DE),A ;Filespec until paren 2789 FE0D 01257 CP CR ;RETurn if terminator 278B C8 01258 RET Z 278C FE28 01259 CP '(' ;Parameter ? 278E C8 01260 RET Z 278F 23 01261 INC HL ;Bump ptr 2790 13 01262 INC DE 2791 10EA 01263 DJNZ COP1 ;32 characters max 2793 C9 01264 RET 01265 ; 01266 ; PRSPC - Match Source & Dest. specs for defaults 01267 ; 2794 21572C 01268 PRSPC LD HL,FCB1 ;HL => Source FCB 2797 11032C 01269 LD DE,FCB2 ;DE => Destin FCB 01270 ; 01271 ; Abort if first character is illegal 01272 ; 279A 1A 01273 LD A,(DE) ;P/u 1st char of dest 279B FE0D 01274 CP CR ;Is it a C/R ? 279D CA3924 01275 JP Z,DSTREQ ;"Destination spec req" 27A0 FE30 01276 CP '0' ;Numeric ? 27A2 3805 01277 JR C,CHKDEST 27A4 FE3A 01278 CP '9'+1 27A6 DA3924 01279 JP C,DSTREQ ;Yes - "Dest spec req" 01280 ; 27A9 D5 01281 CHKDEST PUSH DE ;Save Destination FCB ptr 01282 ; 01283 ; If no dest. filename, xfer source filename 01284 ; 27AA 1A 01285 LD A,(DE) ;P/u a dest char 27AB FE41 01286 CP 'A' ;Filename present ? 27AD DCE427 01287 CALL C,PRSPC7 ;No - xfer src filename 27B0 062F 01288 LD B,'/' ;With an alpha, init to 27B2 CDBD27 01289 CALL PRSPC2 ; test for extension 27B5 062E 01290 LD B,'.' ;Init to test for pswd 27B7 CDBD27 01291 CALL PRSPC2 27BA D1 01292 POP DE 27BB C9 01293 RET 01294 ; 01295 ; PRSPC2 - Transfer Field to destination 01296 ; DE => Start of Destination Field 01297 ; B = Delimiter to Position one byte after 01298 ; 27BC 13 01299 PRSPC1 INC DE 01300 ; 01301 ; Finished with Field (Delimiter hit) ? 01302 ; 27BD 1A 01303 PRSPC2 LD A,(DE) ;Is the next char the 27BE B8 01304 CP B ;Separator to look for 27BF 280E 01305 JR Z,PRSPC3 01306 ; 01307 ; Skip over an existing destination field 01308 ; 27C1 FE41 01309 CP 'A' ;Alphabetic ? 27C3 30F7 01310 JR NC,PRSPC1 ;Yes - skip it 27C5 FE30 01311 CP '0' ;Numeric ? 27C7 3808 01312 JR C,PRSPC4 ;No - use source field 27C9 FE3A 01313 CP '9'+1 ;Numeric ? 27CB 38EF 01314 JR C,PRSPC1 ;Yes - skip it 01315 ; 27CD 1802 01316 JR PRSPC4 ;Use source field 01317 ; 01318 ; Hit the delimiter - Position to next char 01319 ; 27CF 13 01320 PRSPC3 INC DE ;Position to next field 27D0 C9 01321 RET ; and RETurn 01322 ; 01323 ; Scan Source spec & see if it contains field 01324 ; 27D1 E5 01325 PRSPC4 PUSH HL ;Save ptr to source 27D2 7E 01326 PRSPC5 LD A,(HL) ;Grab a source char 27D3 23 01327 INC HL ;Position to next char 01328 ; 01329 ; Is the character a Terminator ? 01330 ; 27D4 FE03 01331 CP ETX ;End of line ? 27D6 280A 01332 JR Z,PRSPC6 ;If so, not in source 27D8 FE0D 01333 CP CR ;End of line? 27DA 2806 01334 JR Z,PRSPC6 ;If so, not in source 01335 ; 01336 ; is the character the field delimiter ? 01337 ; 27DC B8 01338 CP B ;Delimiter ? 27DD 20F3 01339 JR NZ,PRSPC5 ;Nope, continue 01340 ; 01341 ; Transfer Source Field to Destination 01342 ; 27DF CDF027 01343 CALL MVFLD1 ;Yes, xfer the SRC field 01344 ; 27E2 E1 01345 PRSPC6 POP HL ;Rcvr source ptr 27E3 C9 01346 RET 01347 ; 01348 ; PRSPC7 - Shoehorn source into destination field 01349 ; 01350 ; Check if 1st char in (HL) is alphanumeric 01351 ; 27E4 7E 01352 PRSPC7 LD A,(HL) ;P/u source char 27E5 FE30 01353 CP '0' ;RET NC if alphanumeric 27E7 D8 01354 RET C ;C - not alphanumeric 27E8 FE3A 01355 CP '9'+1 ;Numeric (0-9) ? 27EA 3803 01356 JR C,MVFLD ;Xfer if it is 27EC FE41 01357 CP 'A' ;Not numeric - 27EE D8 01358 RET C ;Must be alphabetic 01359 ; 01360 ; Shoehorn a source field byte into dest FCB 01361 ; 27EF 23 01362 MVFLD INC HL ;Bump source pointer 27F0 E5 01363 MVFLD1 PUSH HL 27F1 62 01364 LD H,D ;Xfer dest ptr to HL 27F2 6B 01365 LD L,E 01366 ; 01367 ; P/u current char, & stuff in last char 01368 ; 27F3 4E 01369 MVFLD2 LD C,(HL) ;P/u dest char 27F4 77 01370 LD (HL),A ;Stuff in last character 27F5 23 01371 INC HL ;Posn to next char 01372 ; 01373 ; Finished with field ? 01374 ; 27F6 79 01375 LD A,C ;Test dest for 27F7 FE03 01376 CP ETX ;End of line ? 27F9 2804 01377 JR Z,MVFLD3 01378 ; 27FB FE0D 01379 CP CR ;End of line ? 27FD 20F4 01380 JR NZ,MVFLD2 ;Ripple the destination 01381 ; 01382 ; Done stuffing 1 source byte into dest field 01383 ; 27FF 77 01384 MVFLD3 LD (HL),A ;Stuff the terminator 2800 E1 01385 POP HL ;Restore Source FCB 2801 13 01386 INC DE ;Advance to next pos 2802 18E0 01387 JR PRSPC7 ;Go get next source byte 01388 ; 01389 ; DOSVC - Get Filespec/Devspec & Issue @OPEN/@INIT 01390 ; 2804 F5 01391 DOSVC PUSH AF ;Save SVC # 2805 E5 01392 PUSH HL ;Buffer ptr 2806 D5 01393 PUSH DE ;FCB 01394 ; 01395 ; Transfer Filespec/Devspec into TEMBUF 01396 ; 2807 21232C 01397 LD HL,TEMBUF 280A 1A 01398 TLP LD A,(DE) ;P/u byte from FCB 280B FE2F 01399 CP '/' ;Extension ? 280D 2008 01400 JR NZ,STUFCHR ;No - save the char 280F 13 01401 INC DE ;Is the next character 2810 1A 01402 LD A,(DE) ; valid ? 2811 FE41 01403 CP 'A' 2813 3802 01404 JR C,STUFCHR ;No - don't output it 2815 1B 01405 DEC DE ;Back one 2816 1A 01406 LD A,(DE) ;P/u slash 2817 77 01407 STUFCHR LD (HL),A ;Xfer to TEMBUF 2818 23 01408 INC HL 2819 13 01409 INC DE 281A FE0E 01410 CP CR+1 ;Done ? 281C 3808 01411 JR C,DUN 281E FE3A 01412 CP ':' 2820 2804 01413 JR Z,DUN 2822 FE2E 01414 CP '.' 2824 20E4 01415 JR NZ,TLP 01416 ; 01417 ; Found valid terminator - Is this a device ? 01418 ; 2826 2B 01419 DUN DEC HL ;Back up to term 2827 D1 01420 POP DE ;DE => FCB+0 2828 1A 01421 LD A,(DE) ;Device ? 2829 FE2A 01422 CP '*' 282B 2807 01423 JR Z,DUN2 ;Yes - done 282D 363A 01424 LD (HL),':' ;No - overwrite with ":" 282F 23 01425 INC HL ;Bump 2830 229228 01426 LD (DSPEC+1),HL ;Save drivespec location 2833 23 01427 INC HL ;Bump 2834 3603 01428 DUN2 LD (HL),ETX ;End with X'03' 2836 E1 01429 POP HL ;HL => Disk I/O buffer 2837 F1 01430 POP AF ;A = SVC # 2838 326C28 01431 LD (SVCNUM+1),A ;Save SVC # 01432 ; 01433 ; Issue Supervisory Call 01434 ; 283B EF 01435 RST 28H ;Do it 283C F5 01436 PUSH AF ;Save SVC condition 283D CD8428 01437 CALL GETDRIV ;P/u drv (in C) if file 2840 2817 01438 JR Z,DEVICE ;Z - this is a device 01439 ; 01440 ; This is a file - did we @INIT it ? 01441 ; 2842 3A6C28 01442 LD A,(SVCNUM+1) ;P/u SVC # 2845 FE3A 01443 CP @INIT ;Is it @INIT ? 2847 2010 01444 JR NZ,DEVICE ;No - don't worry 01445 ; 01446 ; Was the @INIT successful ? 01447 ; 2849 F1 01448 POP AF ;Don't perform 284A F5 01449 PUSH AF ; a @CKDRV if you didn't 284B 2804 01450 JR Z,DO_CKDR ; successfully @INIT it. 284D FE2A 01451 CP 42 ;LRL Open Fault ? 284F 2008 01452 JR NZ,DEVICE ;No - Don't @CKDRV 01453 ; 01454 ; @INIT was ok - is this a Write Prot Disk? 01455 ; 2851 01456 DO_CKDR @@CKDRV ;Write Protected Disk ? 2851+3E21 01457 LD A,33 2853+EF 01458 RST 40 2854 3E0F 01459 LD A,15 ;Init WP disk error code 2856 DA1424 01460 JP C,IOERR ;Yes - abort 01461 ; 01462 ; Check status on the @INIT we did 01463 ; 2859 F1 01464 DEVICE POP AF ;Recover status 285A 2803 01465 JR Z,CHKPROT ;Check PROTection status 01466 ; 01467 ; Ignore Error #42 - "LRL Open Fault" 01468 ; 285C FE2A 01469 CP 42 ;Ignore this error 285E C0 01470 RET NZ ;NZ - Abort 01471 ; 01472 ; Check if File has proper Access 01473 ; 285F DDCB007E 01474 CHKPROT BIT 7,(IX) ;Is this a filespec ? 2863 281D 01475 JR Z,OKYDOKY ;No - don't check 2865 DD7E01 01476 LD A,(IX+1) ;P/u protection byte 2868 E607 01477 AND 7 286A 47 01478 LD B,A ;Xfer to B 286B 3E00 01479 SVCNUM LD A,$-$ ;P/u SVC # 286D FE3A 01480 CP @INIT ;@INIT ? 286F 78 01481 LD A,B ;P/u protection level 2870 280C 01482 JR Z,INIT1 ;Z - Must be < 5 2872 FE06 01483 CP 6 ;Read Access ? 2874 380C 01484 JR C,OKYDOKY ;Yes - set Z & RETurn 01485 ; 01486 ; Illegal Access to protected file 01487 ; 2876 01488 ILLACC @@CLOSE ;Close File 2876+3E3C 01489 LD A,60 2878+EF 01490 RST 40 2879 3E19 01491 LD A,25 ;File Access Denied 287B C31424 01492 JP IOERR ;Error - Regardless 01493 ; 287E FE05 01494 INIT1 CP 5 ;Update Access ? 2880 30F4 01495 JR NC,ILLACC ;No - Illegal Access 01496 ; 2882 AF 01497 OKYDOKY XOR A ;Set Z flag 2883 C9 01498 RET ;And RETurn 01499 ; 01500 ; GETDRIV - P/u Drive # from FCB & convert to ASCII 01501 ; 2884 D5 01502 GETDRIV PUSH DE ;Get fcb to 2885 DDE1 01503 POP IX ; here. 2887 1A 01504 LD A,(DE) ;Device ? 2888 CB7F 01505 BIT 7,A 288A C8 01506 RET Z ;Device - RETurn 01507 ; 01508 ; Stuff Drive # into Buffer 01509 ; 288B DD7E06 01510 LD A,(IX+6) 288E 4F 01511 LD C,A ;Xfer to C 288F C630 01512 ADD A,'0' ;Convert to ASCII 2891 320000 01513 DSPEC LD ($-$),A 2894 C9 01514 RET ;RETurn w/ condition 01515 ; 01516 ; PUTSOUR/PUTDEST - Create Src/Dest File/Dev specs 01517 ; 2895 E5 01518 PUTSOUR PUSH HL ;Save HL 2896 21332C 01519 LD HL,FROM ;Xfer there 2899 1804 01520 JR XBUFF 289B E5 01521 PUTDEST PUSH HL ;Save HL 289C 21472C 01522 LD HL,TO2 01523 ; 01524 ; XBUFF - Transfer TEMBUF contents to User Buffer 01525 ; HL => Destination of Filespec/Devspec 01526 ; 289F D5 01527 XBUFF PUSH DE ;Save FCB ptr 28A0 11232C 01528 LD DE,TEMBUF ;DE => Source 28A3 EB 01529 EX DE,HL ;Swap for LDIR 28A4 010F00 01530 LD BC,15 ;15 bytes Max 28A7 EDB0 01531 LDIR ;Xfer 28A9 D1 01532 POP DE ;DE => FCB+0 28AA E1 01533 POP HL ;Recover Buffer ptr 28AB C9 01534 RET ;Done 01535 ; 01536 ; CPYFILE - Display Copying/Appending Message 01537 ; 28AC E5 01538 CPYFILE PUSH HL ;Save registers 28AD D5 01539 PUSH DE 28AE 21832A 01540 LD HL,COPYMS ;"Copying : " 28B1 3E01 01541 APPFLAG LD A,$-$+1 ;Append or Copy ? 28B3 B7 01542 OR A 28B4 2003 01543 JR NZ,ITSCOPY 28B6 218D2A 01544 LD HL,APPDMS ;"Appending : " 28B9 CD212A 01545 ITSCOPY CALL DSPLY 28BC 21332C 01546 LD HL,FROM ;Source 28BF CD212A 01547 CALL DSPLY 28C2 21432C 01548 LD HL,TO ;" TO " 28C5 CD212A 01549 CALL DSPLY 28C8 0E0D 01550 LD C,CR ;End line 28CA CD1A2A 01551 CALL DISPB ;Display byte 28CD D1 01552 POP DE ;Restore Regs 28CE E1 01553 POP HL 28CF C9 01554 RET 01555 ; 01556 ; GETLRL - Get LRL from a Directory Entry 01557 ; DE => FCB of filespec 01558 ; IX <= FCB of filespec 01559 ; A <= LRL of file 01560 ; 28D0 D5 01561 GETLRL PUSH DE ;Xfer fcb to IX 28D1 DDE1 01562 POP IX 28D3 DD7E07 01563 LD A,(IX+7) ;P/u DEC 28D6 E6E0 01564 AND 0E0H ;Calculate Record Number 28D8 C604 01565 ADD A,4 ;Pt to LRL 28DA 6F 01566 LD L,A 28DB 2600 01567 SYSBUF LD H,$-$ ;P/u hi-byte of SBUFF$ 28DD 7E 01568 LD A,(HL) ;P/u LRL 28DE C9 01569 RET 01570 ; 01571 ; GETCLON - Recover Cloning info from Source 01572 ; 28DF D5 01573 GETCLON PUSH DE 28E0 DDE1 01574 POP IX ;Xfer FCB to IX 28E2 DD7E07 01575 LD A,(IX+7) ;P/u source DEC 28E5 E6E0 01576 AND 0E0H ;Pt to start of record 28E7 6F 01577 LD L,A ;Pt to core record 28E8 2600 01578 SYSBUF2 LD H,$-$ ;P/u hi-byte of SBUFF$ 28EA 119B2C 01579 LD DE,CLONSAV ;Save clone info 28ED 010300 01580 LD BC,3 28F0 EDB0 01581 LDIR 28F2 3E0D 01582 LD A,13 ;Pt to password fields 28F4 85 01583 ADD A,L 28F5 6F 01584 LD L,A 28F6 010400 01585 LD BC,4 ;Save them also 28F9 EDB0 01586 LDIR 28FB C9 01587 RET 01588 ; 01589 ; Change drive # in A to Bit x,A opcode 01590 ; 28FC 47 01591 WHATBIT LD B,A ;Drive # to B 28FD 04 01592 INC B ;Always do once 28FE 3E3F 01593 LD A,47H-8 ;Init opcode 2900 C608 01594 WHTB1 ADD A,8 ;Index to proper opcode 2902 10FC 01595 DJNZ WHTB1 2904 C9 01596 RET 01597 ; 01598 ; DOINIT - Initialization for APPEND or COPY 01599 ; 2905 01600 DOINIT EQU $ 01601 ; 01602 ; Calculate high byte of available memory 01603 ; 2905 E5 01604 PUSH HL ;Save HL 2906 01605 @@FLAGS ;IY => System Flags 2906+3E65 01606 LD A,101 2908+EF 01607 RST 40 2909 FDE5 01608 PUSH IY 290B D1 01609 POP DE 290C 211800 01610 LD HL,'Y'-'A' ;Find year type flag locn 290F 19 01611 ADD HL,DE 2910 22A425 01612 LD (YFLAG1),HL ;Save for date test 2913 220A26 01613 LD (YFLAG2),HL 2916 210000 01614 LD HL,0 ;P/u HIGH$ 2919 45 01615 LD B,L 291A FDCB024E 01616 BIT 1,(IY+CFLAG$) ;@CMNDR ? 291E 2801 01617 JR Z,USEHI ;No - use HIGH$ 2920 04 01618 INC B ;Yes - use LOW$ 2921 01619 USEHI @@HIGH$ 2921+3E64 01620 LD A,100 2923+EF 01621 RST 40 01622 ; 01623 ; Stuff high byte into memory check locations 01624 ; 2924 23 01625 INC HL ; 256-byte block 2925 25 01626 DEC H 2926 7C 01627 LD A,H ;Set up test bytes 2927 325926 01628 LD (RDREC3+1),A 292A 327126 01629 LD (RDREC5+1),A 292D 324729 01630 LD (GEOF6+1),A 01631 ; 01632 ; Pick up high byte of System Buffer (SBUFF$) 01633 ; 2930 010000 01634 LD BC,0 ;DEC = 0, Drive = 0 2933 01635 @@DIRRD ;Read in BOOT/SYS 2933+3E57 01636 LD A,87 2935+EF 01637 RST 40 2936 7C 01638 LD A,H ;P/u high byte of SBUFF$ 2937 32DC28 01639 LD (SYSBUF+1),A ;Stuff away for LRL 293A 32E928 01640 LD (SYSBUF2+1),A ;Stuff away for CLONE 01641 ; 01642 ; Reset & bits 01643 ; 293D CD0E2A 01644 CALL RESKFLG ;Reset bits 1-2 2940 E1 01645 POP HL 2941 C9 01646 RET 01647 ; 01648 ; GEOF5 - Write out the last sector of destination 01649 ; 2942 7C 01650 GEOF5 LD A,H ;P/u hi-order pointer 2943 FE2E 01651 CP BUF1<-8 ;Same as start? 2945 C8 01652 RET Z ;Ret if finished 01653 ; 01654 ; At the end of buffer area ? 01655 ; 2946 FE00 01656 GEOF6 CP $-$ ;GEOF6+1 = msb of top 2948 C8 01657 RET Z ;Return if finished 01658 ; 01659 ; Flash "Insert Dest. Disk" & write remainder 01660 ; 2949 CD9A29 01661 CALL PMTDST ;Prompt destination 294C 44 01662 LD B,H ;Save highest used 294D 21002E 01663 LD HL,BUF1 ;Pt to start 01664 ; 01665 ; Loop to write out remainder of dest. file 01666 ; 2950 22062C 01667 GEOF7 LD (FCB2+3),HL ;Set dest buffer address 2953 11032C 01668 LD DE,FCB2 ;DE => Dest. FCB 2956 01669 @@WRITE ;Write a record 2956+3E4B 01670 LD A,75 2958+EF 01671 RST 40 2959 C21424 01672 JP NZ,IOERR ;Jump on write error 01673 ; 01674 ; Finished writing ? 01675 ; 295C 24 01676 INC H ;Bump buff ptr 295D 7C 01677 LD A,H 295E B8 01678 CP B ;Finished? 295F 20EF 01679 JR NZ,GEOF7 ;Loop if not 2961 C9 01680 RET ;Return 01681 ; 01682 ; CKBRK - Check for BREAK 01683 ; NZ - key was depressed 01684 ; 01685 CKBRK 2962 01686 @@CKBRKC ; hit ? 2962+3E6A 01687 LD A,106 2964+EF 01688 RST 40 2965 C9 01689 RET ;Z - No, NZ - Yes 01690 ; 01691 ; PMTSYS - Prompt for a system disk 01692 ; 2966 3A2325 01693 PMTSYS LD A,(XPARM+1) ;X parameter entered ? 2969 B7 01694 OR A 296A C8 01695 RET Z ;No - need to prompt 01696 ; 01697 ; If Xfer drive number isn't 0 - don't prompt 01698 ; 296B 3E00 01699 XFRDRV LD A,$-$ ;XFRDRV+1 contains drv # 296D B7 01700 OR A ;Is it zero ? 296E C0 01701 RET NZ ;Ret if not SYSTEM drive 01702 ; 01703 ; Flash "Insert SYSTEM disk" message 01704 ; 296F E5 01705 PUSH HL ;Save HL 2970 21432B 01706 LD HL,PMTSYS$ ;"Insert SYSTEM disk" 2973 CDC729 01707 CALL FLASH ;Flash, & RET if 2976 E1 01708 POP HL ;Restore HL 2977 C9 01709 RET 01710 ; 01711 ; PMTSRC - Prompt for Source Disk 01712 ; 2978 3A2325 01713 PMTSRC LD A,(XPARM+1) ;X parameter entered ? 297B B7 01714 OR A 297C C8 01715 RET Z ;No - don't display it 01716 ; 01717 ; Flash "Insert Source disk" message 01718 ; 297D E5 01719 PUSH HL 297E 21622B 01720 LD HL,PMTSRC$ ;Init for source 2981 CDC729 01721 CALL FLASH ;Dsp msg & await reply 01722 ; 01723 ; Read in the GAT from the Source Disk 01724 ; 2984 3A6C29 01725 LD A,(XFRDRV+1) ;P/u drive 2987 4F 01726 LD C,A ;Stuff in C 2988 CD462A 01727 CALL RDGAT ;Get GAT 01728 ; 01729 ; Is this the correct source disk ? 01730 ; 298B 21CE2D 01731 LD HL,GAT+0CEH ;HL => Name & Date field 298E 11772C 01732 LD DE,SRCSTR ;DE => Original Source 2991 0612 01733 LD B,18 ;Same source disk ? 2993 CDBC29 01734 CALL CPRHLDE ;Z - same, NZ - different 2996 E1 01735 POP HL ;Restore HL 2997 20DF 01736 JR NZ,PMTSRC ;Re-request if not match 2999 C9 01737 RET ;Okay 01738 ; 01739 ; PMTDST - Prompt for Destination disk 01740 ; 299A 3A2325 01741 PMTDST LD A,(XPARM+1) ;X parameter entered ? 299D B7 01742 OR A 299E C8 01743 RET Z ;No - RETurn 01744 ; 01745 ; Flash "Insert Destination disk" message 01746 ; 299F E5 01747 PUSH HL 29A0 21972B 01748 LD HL,PMTDST$ ;Pt to msg 29A3 CDC729 01749 CALL FLASH ;Prompt & await reply 01750 ; 01751 ; Read in GAT from original destination disk 01752 ; 29A6 3A6C29 01753 LD A,(XFRDRV+1) ;P/u drive # 29A9 4F 01754 LD C,A ;Stuff in C 29AA CD462A 01755 CALL RDGAT ;Get GAT 01756 ; 01757 ; Is this the same destination disk ? 01758 ; 29AD 21CE2D 01759 LD HL,GAT+0CEH ;HL => Name & Date field 29B0 11892C 01760 LD DE,DSTSTR ;DE => Original dest 29B3 0612 01761 LD B,18 ;Same destination disk ? 29B5 CDBC29 01762 CALL CPRHLDE ;Z - Same, NZ - different 29B8 E1 01763 POP HL ;Restore HL 29B9 20DF 01764 JR NZ,PMTDST ;Re-request if wrong disk 29BB C9 01765 RET 01766 ; 01767 ; CPRHLDE - Compare string @ HL to string @ DE 01768 ; B => Number of characters to compare 01769 ; Z - Set if strings match 01770 ; 29BC 1A 01771 CPRHLDE LD A,(DE) ;P/u character @ DE 29BD BE 01772 CP (HL) ;Same ? 29BE C0 01773 RET NZ ;Ret (NZ) if no match 29BF 23 01774 INC HL ;Bump each 29C0 13 01775 INC DE 29C1 10F9 01776 DJNZ CPRHLDE ;Check B characters 29C3 C9 01777 RET ;Matched - RETurn Z 01778 ; 01779 ; FLASH & FLASH0 - Flash a message string 01780 ; HL => Message string to flash 01781 ; 29C4 CD0E2A 01782 FLASH0 CALL RESKFLG ;Reset Pause, Enter 01783 ; 01784 ; Pause briefly 01785 ; 29C7 01FD41 01786 FLASH LD BC,16893 ;Delay count 29CA 01787 @@PAUSE 29CA+3E10 01788 LD A,16 29CC+EF 01789 RST 40 01790 ; 01791 ; Wait for no Enter or Break 01792 ; 29CD FD7E0A 01793 LD A,(IY+KFLAG$) ;P/u KFLAG$ 29D0 E605 01794 AND 4!1 ;Wait until no ENTER!BRK 29D2 20F0 01795 JR NZ,FLASH0 ;Still down, go flash 29D4 CD0E2A 01796 CALL RESKFLG ;Reset 01797 ; 01798 ; Display the message & wait for 1/4 second 01799 ; 29D7 CD212A 01800 FLS1 CALL DSPLY 29DA 010040 01801 LD BC,4000H ;Delay 4000 iterations 29DD CDED29 01802 CALL FLS2 ; & scan for Break,Enter 01803 ; 01804 ; Erase the message & wait 01805 ; 29E0 0E1E 01806 LD C,EL ;Erase line 29E2 CD1A2A 01807 CALL DISPB 29E5 013333 01808 LD BC,3333H ;Delay 3333 iterations 29E8 CDED29 01809 CALL FLS2 ; & scan for Break,Enter 29EB 18EA 01810 JR FLS1 ;Loop if neither 01811 ; 01812 ; FLS2 - Delay BC loops & scan for 01813 ; 29ED CD6229 01814 FLS2 CALL CKBRK ;Check for 29F0 C24924 01815 JP NZ,ABORT 01816 ; 01817 ; Was the pressed ? 01818 ; 29F3 FDCB0A56 01819 BIT 2,(IY+KFLAG$) ; hit ? 29F7 2006 01820 JR NZ,FLS4 ;Go on ENTER down 01821 ; 01822 ; Nothing hit - Count down 01823 ; 29F9 0B 01824 DEC BC ;Decrement count 29FA 78 01825 LD A,B ;Done ? 29FB B1 01826 OR C 29FC 20EF 01827 JR NZ,FLS2 ;No - check again 29FE C9 01828 RET ;Yes - RETurn 01829 ; 01830 ; hit - POP ret addr & clr type ahead 01831 ; 29FF F1 01832 FLS4 POP AF ;Pop return address 2A00 01833 CLRTYPE @@KBD ;Clear type ahead 2A00+3E08 01834 LD A,8 2A02+EF 01835 RST 40 2A03 28FB 01836 JR Z,CLRTYPE ;Good - get another 2A05 B7 01837 OR A ;O.K. ? 2A06 C21424 01838 JP NZ,IOERR ;No - I/O Error 01839 ; 01840 ; Erase message line 01841 ; 2A09 0E1E 01842 LD C,EL ;Erase line 2A0B CD1A2A 01843 CALL DISPB ;Fall into RESKFLG 01844 ; 01845 ; RESKFLG - Reset & bits in KFLAG 01846 ; 2A0E 01847 RESKFLG @@FLAGS ;IY => Flag Table 2A0E+3E65 01848 LD A,101 2A10+EF 01849 RST 40 2A11 FD7E0A 01850 LD A,(IY+KFLAG$) ;P/u KFLAG$ 2A14 E6F9 01851 AND 0F9H ;Reset bits 2 & 1 2A16 FD770A 01852 LD (IY+KFLAG$),A ;Stuff in KFLAG$ 2A19 C9 01853 RET ;RETurn 01854 ; 01855 ; DISPB - Output a byte to the Video 01856 ; 2A1A 01857 DISPB @@DSP ;Output byte 2A1A+3E02 01858 LD A,2 2A1C+EF 01859 RST 40 2A1D C8 01860 RET Z ;Good - RETurn 2A1E C31424 01861 JP IOERR ;Bad - I/O error 01862 ; 01863 ; DSPLY - Display line to video 01864 ; 2A21 01865 DSPLY @@DSPLY ;Display 01866 IFEQ 00H,1 01867 LD HL, 01868 ENDIF 2A21+3E0A 01869 LD A,10 2A23+EF 01870 RST 40 2A24 C8 01871 RET Z 2A25 C31424 01872 JP IOERR ;Bad - I/O Error 01873 ; 01874 ; STOP - Display Transfer aborted & Abort 01875 ; 2A28 21CD2A 01876 STOP LD HL,STOP$ ;"Transfer Aborted" 2A2B 01877 @@LOGOT ;Log message 01878 IFEQ 00H,1 01879 LD HL, 01880 ENDIF 2A2B+3E0C 01881 LD A,12 2A2D+EF 01882 RST 40 2A2E CD6629 01883 CALL PMTSYS ;"Insert SYSTEM disk" 2A31 C34924 01884 JP ABORT ;Abort 01885 ; 01886 ; GETSYS2 - Bring in SYS2 01887 ; 2A34 3E84 01888 GETSYS2 LD A,84H 2A36 EF 01889 RST 28H 01890 ; 01891 ; GETSYS3 - Bring in SYS3 01892 ; 2A37 3E85 01893 GETSYS3 LD A,85H 2A39 EF 01894 RST 28H 01895 ; 01896 ; CKDEV - Is the source or Destination a device ? 01897 ; Z - Either Source or Destination is a device 01898 ; 2A3A 3A572C 01899 CKDEV LD A,(FCB1) ;Is source a device? 2A3D FE2A 01900 CP '*' 2A3F C8 01901 RET Z 2A40 3A032C 01902 LD A,(FCB2) ;Is destination a device? 2A43 FE2A 01903 CP '*' 2A45 C9 01904 RET 01905 ; 01906 ; RDGAT - Read GAT of Drive C 01907 ; 2A46 D5 01908 RDGAT PUSH DE ;Save DE & HL 2A47 E5 01909 PUSH HL 2A48 FDE5 01910 PUSH IY ;Save IY 01911 ; 01912 ; Set D = Cyl, E = Sector, HL => Buffer 01913 ; 2A4A 01914 @@GTDCT ;Point IY to DCT 2A4A+3E51 01915 LD A,81 2A4C+EF 01916 RST 40 2A4D FD5609 01917 LD D,(IY+9) ;P/u dir cyl in D 2A50 1E00 01918 LD E,0 ;GAT is sector 0 2A52 21002D 01919 LD HL,GAT ;HL => GAT I/O Buffer 2A55 01920 @@RDSSC ;Read Track D, Sector E 2A55+3E55 01921 LD A,85 2A57+EF 01922 RST 40 01923 ; 01924 ; Restore Registers 01925 ; 2A58 FDE1 01926 POP IY ;Restore IY 2A5A E1 01927 POP HL ;Restore HL & DE 2A5B D1 01928 POP DE 2A5C 3E14 01929 LD A,14H ;Else reset to GAT error 2A5E C9 01930 RET ;RETurn with condition 01931 ; 01932 ; OPENDES - OPEN Destination File 01933 ; 2A5F 21002F 01934 OPENDES LD HL,BUF2 ;HL => Dest I/O Buffer 2A62 11032C 01935 LD DE,FCB2 ;DE => Dest FCB 2A65 1811 01936 JR OPENFIL ;Open the file 01937 ; 01938 ; INITDES - INIT the destination file 01939 ; 2A67 3E3A 01940 INITDES LD A,@INIT ;A = @INIT SVC Number 2A69 180F 01941 JR INITFIL ;Go into OPEN routine 01942 ; 01943 ; OPENSRC - Open Source File 01944 ; 2A6B 11572C 01945 OPENSRC LD DE,FCB1 ;DE => Source FCB 01946 ; 01947 ; Set the File OPEN inhibit flag 01948 ; 2A6E 01949 @@FLAGS ;IY => System Flag Table 2A6E+3E65 01950 LD A,101 2A70+EF 01951 RST 40 2A71 FDCB12C6 01952 SET 0,(IY+SFLAG$) ;Set file open inhibit 01953 ; 2A75 21002E 01954 OPENSR2 LD HL,BUF1 ;HL => Source I/O buffer 2A78 3E3B 01955 OPENFIL LD A,@OPEN ;A = @OPEN SVC number 2A7A 0600 01956 INITFIL LD B,0 ;B = LRL = 256 01957 ; 01958 ; OPEN or INIT the File 01959 ; 2A7C CD0428 01960 GETFILE CALL DOSVC ;OPEN or INIT the file 2A7F C8 01961 RET Z ;RETurn with Z set 2A80 C31424 01962 JP IOERR ;NZ - I/O Error 01963 ; 01964 ; Error & Informative message strings 01965 ; 2A83 43 01966 COPYMS DB 'Copying: ',ETX 6F 70 79 69 6E 67 3A 20 03 2A8D 41 01967 APPDMS DB 'Appending: ',ETX 70 70 65 6E 64 69 6E 67 3A 20 03 01968 ; 2A99 46 01969 DIFLRL$ DB 'Files have different LRLs',CR 69 6C 65 73 20 68 61 76 65 20 64 69 66 66 65 72 65 6E 74 20 4C 52 4C 73 0D 2AB3 44 01970 DSTREQ$ DB 'Destination spec required',CR 65 73 74 69 6E 61 74 69 6F 6E 20 73 70 65 63 20 72 65 71 75 69 72 65 64 0D 2ACD 1D 01971 STOP$ DB BL,'Transfer aborted',CR 54 72 61 6E 73 66 65 72 20 61 62 6F 72 74 65 64 0D 2ADF 46 01972 SPCREQ$ DB 'File spec required',CR 69 6C 65 20 73 70 65 63 20 72 65 71 75 69 72 65 64 0D 2AF2 49 01973 NOINDO$ DB 'Invalid command during ' 6E 76 61 6C 69 64 20 63 6F 6D 6D 61 6E 64 20 64 75 72 69 6E 67 20 3C 44 4F 3E 20 2B0E 70 01974 DB 'processing',CR 72 6F 63 65 73 73 69 6E 67 0D 2B19 53 01975 SAMERR$ DB 'Source and destination disks' 6F 75 72 63 65 20 61 6E 64 20 64 65 73 74 69 6E 61 74 69 6F 6E 20 64 69 73 6B 73 2B35 20 01976 DB ' are the same',CR 61 72 65 20 74 68 65 20 73 61 6D 65 0D 01977 ; 2B43 1D 01978 PMTSYS$ DB BL,EL,' Insert SYSTEM disk ' 1E 20 49 6E 73 65 72 74 20 53 59 53 54 45 4D 20 64 69 73 6B 20 3C 45 4E 54 45 52 3E 2B60 1D 01979 DB BL,ETX 03 01980 ; 2B62 1D 01981 PMTSRC$ DB BL,EL,' Insert SOURCE disk ' 1E 20 49 6E 73 65 72 74 20 53 4F 55 52 43 45 20 64 69 73 6B 20 2B78 69 01982 DB 'in drive :' 6E 20 64 72 69 76 65 20 3A 2B82 30 01983 SRC_DR DB '0 and press ' 20 61 6E 64 20 70 72 65 73 73 20 3C 45 4E 54 45 52 3E 2B95 1D 01984 DB BL,ETX 03 01985 ; 2B97 1D 01986 PMTDST$ DB BL,EL,' Insert DESTINATION disk ' 1E 20 49 6E 73 65 72 74 20 44 45 53 54 49 4E 41 54 49 4F 4E 20 64 69 73 6B 20 2BB2 69 01987 DB 'in drive :' 6E 20 64 72 69 76 65 20 3A 2BBC 30 01988 DEST_DR DB '0 and press ' 20 61 6E 64 20 70 72 65 73 73 20 3C 45 4E 54 45 52 3E 2BCF 1D 01989 DB BL,ETX 03 01990 ; 01991 ; 01992 ; APPEND PARAMETER TABLE 01993 ; 2BD1 80 01994 APPTBL DB 80H ;Use new @PARAM 01995 ; 2BD2 55 01996 DB FLAG!ABB!5 2BD3 53 01997 DB 'STRIP' 54 52 49 50 2BD8 00 01998 DB 0 2BD9 AC24 01999 DW SPARM+1 02000 ; 2BDB 54 02001 DB FLAG!ABB!4 2BDC 45 02002 DB 'ECHO' 43 48 4F 2BE0 00 02003 DB 0 2BE1 6227 02004 DW EPARM+1 2BE3 00 02005 DB 0 02006 ; 02007 ; COPY PARAMETER TABLE 02008 ; 2BE4 80 02009 COPYTBL DB 80H ;New @PARAM 02010 ; 2BE5 54 02011 DB FLAG!ABB!4 2BE6 45 02012 DB 'ECHO' 43 48 4F 2BEA 00 02013 DB 0 2BEB 6227 02014 DW EPARM+1 02015 ; 2BED 93 02016 DB NUM!ABB!3 2BEE 4C 02017 DB 'LRL' 52 4C 2BF1 00 02018 DB 0 2BF2 B525 02019 DW LPARM+1 02020 ; 2BF4 55 02021 DB FLAG!ABB!5 2BF5 43 02022 DB 'CLONE' 4C 4F 4E 45 2BFA 00 02023 DB 0 2BFB A926 02024 DW CPARM+1 02025 ; 2BFD 41 02026 DB FLAG!1 2BFE 58 02027 DB 'X' 2BFF 00 02028 DB 0 2C00 2325 02029 DW XPARM+1 2C02 00 02030 DB 0 ;End of COPY parm table 02031 ; 02032 ; I/O & Storage Buffers 02033 ; 2C03 00 02034 FCB2 DB 0 ;Show closed on LOAD 2C04 02035 DS 31 2C23 02036 TEMBUF DS 16 2C33 02037 FROM DS 16 2C43 20 02038 TO DB ' to ' 74 6F 20 2C47 02039 TO2 DS 16 2C57 00 02040 FCB1 DB 0 2C58 02041 DS 31 2C77 02042 SRCSTR DS 18 2C89 02043 DSTSTR DS 18 2C9B 02044 CLONSAV DS 7 02045 ; 2D00 02046 ORG $<-8+1<+8 02047 ; 2D00 02048 GAT DS 256 2E00 02049 BUF1 DS 256 2F00 02050 BUF2 DS 256 02051 ; 02053 ; 2400 02055 END COPY 2400 is the transfer address 00000 Total errors
[Copyright 1999,2002,2014 Frank Durda IV, All Rights Reserved. Mirroring of any material on this page in any form is expressly prohibited. The official web site for this material is: http://nemesis.lonestar.org Contact this address for use clearances: clearance_2014 at nemesis.lonestar.org Comments and queries to this address: web_software_2014 at nemesis.lonestar.org]