Path: utzoo!utgpu!watmath!isishq!f171.n221.z1.FIDONET.ORG!izot From: izot@f171.n221.z1.FIDONET.ORG (Geoffrey Welsh) Newsgroups: comp.sys.cbm Subject: autobooting kermit from a 1581 Message-ID: <1904.242D7A42@isishq.FIDONET.ORG> Date: 26 Mar 89 05:36:32 GMT Sender: ufgate@isishq.FIDONET.ORG (newsout1.25) Organization: FidoNet node 1:221/171 - Izot's Swamp, Kitchener ON Lines: 56 > From: dave@zehntel (Dave Funk) > Message-ID: <802@zehntel.UUCP> > Well, I did that, and it works! The only thing I haven't quite figured > out is how to also overwrite the first byte in the sector (seems this is > reserved for the sector length). It is a simple matter to use a disk > editor to do this, but I would prefer my program to handle it. I know > it can be done - disk editors do it and Fred Bowen's 'autoboot 128' program > must do it. The first TWO bytes (bytes 0 & 1) are used to link to the next track & sector (or, if the sector is the last in the file, the track link contains zero and the sector link points to the last used byte). CBM drive manuals state that, when the exact contents of a buffer are to be copied to disk (i.e. the first two bytes are not to be set to anything but the first two bytes of the buffer), use the "U2:" command in stead of the "B-W:" (block-write) command. Here's how it might go: 10 OPEN 1,8,15 : REM command channel - necessary for any major work 20 OPEN 2,8,14,"#" : REM allocate a buffer & a data channel 30 FOR I = 0 TO 255 40 PRINT#2, CHR$( DATA( I ) ); : REM send data to buffer - rewrite as needed 50 NEXT I 60 PRINT#1,"U2:14 0 1 0" : REM write buffer accessed via channel 14 to 1,0 70 CLOSE 2 : CLOSE 1 : REM let's not leave open files for BASIC to close! > It seems to me that one could convert any C128 5.25" autoboot disk to a > 1581 autoboot disk this way (as long as nothing is copied protected). > You would just have to make sure to do *this* copy and allocation first, > followed by a copy of all the files on the disk. > > Does this seem reasonable or did I just luck out in this particular case? Basically, as long as track 1 sector 0 is free, any disk on any drive can be made to autoboot. There is no reason why most copy-protected disks could not be made to autoboot on their original format drive; the common techniques of wiping sectors or tracks or half-tracking should not be affected by 1,0 unless that sector is affected by the copy-protect scheme (very unlikely). ============================================================================ Usenet: watmath!isishq!izot | 66 Mooregate Crescent Internet: Geoffrey.Welsh@f171.n221.z1.fidonet.org | Suite 602 FidoNet: Geoffrey Welsh on 1:221/171 | Kitchener, Ontario PunterNet: 7/GEOFFREY WELSH | N2M 5E6 CANADA BBS: (519) 742-8939 24h/7d 9600 USRobotics HST | (519) 741-9553 ============================================================================ | "I don't need a disclaimer. No one pays any attention to what I say." | ============================================================================ -- Geoffrey Welsh - via FidoNet node 1:221/162 UUCP: ...!watmath!isishq!171!izot Internet: izot@f171.n221.z1.FIDONET.ORG