Changes
WriteDSK
,Added link, instructions
=== Introduction === WriteDSK is a tool written by [[Targhan]] for converting dsk images used on emulators back to real floppies. It can read the dsk image from a 720k dos-formatted floppy in drive A or B, or from a serial link with the [[cpcbooster]] connected to a PC with appropriate software. It can write the floppy on drive A or B. It can handle most protected formats. === Links ===[http://www.julien-nevo.com/arkos/tools.html Arkos Download page] === Instruction Manual ===''(extracted from the disk image)'' WRITEDSK/DIRDOS 1.1-------------------By Targhan/Arkos These two little tools -also available in rom- will allow you to transfer a DSKfrom a 720ko disc (formatted on PC or DOSCOPY for example) to a CPC disc. Itworks like DSKCPC from Divine Coding. Of course, Writedsk is much morepowerful :) : New features for V1.1 :------------------------ New interface. You are now able to see how the sectors are organized on thetracks.- A new optional parameter allows you to write directly on the second side ofyour disc, if the destination drive is a 3"5.- Bigger internal buffer, most conventionnal DSKs are transfered in 2 passes.- Ctrl+Shift+Esc to exit anytime.- Correction of a bug that could prevent DIRDOS from working properly.- Correction of a bug that could prevent some PC files from being read.- Managment of tracks unformatting. At the end of the transfert, tracks that arenot coded in the DSK with be unformatted. In a general way, it allows protectedDSKs to work fine.- Writting of different sized sectors allowed, with limitations. A lot ofprotected DSKs can be transfered.- Writting of erased sectors allowed. Same result. Other features :----------------- It recognizes all standard CPC format, from size 0 to 5. Size 6 sectors aren'trecognized.- Standard and Extended DSKs are recognized.- Double sided DSKs too.- You can use ONE drive only for the transfert ! Very useful for those, like me,who have only one 3'5 drive and don't want to use 3'. Both tools will be released once again soon when the Antitec's CPCBOOSTER+ isreleased. New functions will allow tranfering DSKs directly on a CPC disc, aswell as SNApshots into the CPC memory. A developer's dream ! We may also releasesome cool tools for coders in the same rom. HOW TO USE IT-------------|WRITEDSK,"dskname",["SourceDestination[Head]"] Transfert the DSK named "dskname" from Source drive to Destination drive. If thesecond parameter is omitted, the Source is B and the destination A. The DSKname is short (8+3 letters), DOS-like. You may have to use tilde (control+2) ifyou've saved your DSK on PC with a long name. Know that your DSK must always be on the root of your disc. New option since V1.1, the "head" allows to write directly on the second side ofyour disc. It is optional though. Having to switch side between two passes nowbelongs to the past ! The only possibility is "1" though, with indicates side 1.I did this for you not to incidentally erase the side 0, thinking it was thesecond one (In the FDC language, sides are noted 0 and 1, not 1 and 2). Note that the 'head' option is ignored if the DSK is double sided, with islogical. What's more, this option doesn't change the 'side' included to thesector IDs. I should also say that you can ONLY read the PC disc (FAT 12) if the selectedhead of your source drive is 0 (else head 0 is no more accessible, as head 1 isforced. FAT 12 is double sided !). Examples :|WRITEDSK,"thedemo.dsk","AB"|WRITEDSK,"bigofull.dsk"|WRITEDSK,"dia.dsk","AA1" -----------------|DIRDOS,["Source"] DIRDOS performs a CAT on the DOS disc, to see the files on the root. Directoriesare also noted, but can't be explored. The Source drive declaration is optional.By default, the B drive is used. Once again, don't forget to select the side 0 of your drive. Example :|DIRDOS,"a"|DIRDOS THE INTERFACE-------------Nothing crazy. You don't have to understand anything to transfert your DSKs. Letme describe what the columns mean. They all refer to the sectors of the currenttrack to be written. TR = Number of TRack written in the sector ID.SD = Shows the SiDe in the sector ID.ID = Very important, IDentification number of the sector.SZ = Very important too, the sector SiZe. It is the actual size of the sector. Note that, except the SiZe, all this information can be junk, it's only used toidentify a sector. Some protections will have fun at using strange values. In the INFOS columns can come two acronyms :ERA = Means ERAsed. It's just a mark set to the sector, it doesn't mean thesector is actually erased. To read it you must use the 'read erased sector FDCinstruction.CKS = Means Bad CheckSum. To sum up, the FDC will report an error after readingthe sector, believing an error has been made while reading. I'll talk about itlater, but in a practical case it's completely useless, in fact I simply don'tdo anything with this flag. The 'Size' at the left of the screen represents the sector size given to theFormat instruction. So all sectors of the track can be this size, or less. Last remark, note the increasing value at the bottom right when reading the PCdisc : it represents the buffer filling. Just to know how long you still have towait... That's all about the interface. ACKNOWLEDGMENT--------------Although the DSK format is well featured, a lot of emulators don't update itwell, like Winape. If you format a track with size 3 sectors, the track headerwill read size 2 ! The good size has to be found in the sector headers... TheGAP#3 suffers the same way. Approximated FDC emulation allows demos and softwareto run well, but corrections need to be made if you transfert them on CPC.Existing tools like CPDWRITE and CPCTRANS perform these corrections. WRITEDSKtoo. About the GAP, I used the correction table you will find in the DISC+ULTRAnotice. However, I made a lot of changes. Thus, the minimum value is set to #20,the maximum to #4E. Every well built track will work. If the GAP must be lowerthan #20, then the track contains too much sectors for its own good, and it'snot my business ! Bigger than #80 GAP is useless too. If your drive needs itthen you MUST change it quick ! The V1.1 contains a lot of improvments, as I learnt a lot lately (Thanks Ram7 !)Thus, contrary to what I thought, it is possible to have different sizedsectors. The routines I used here are basic, but allow many protections to betransfered. About the 'bad checksum' flag, the only way I see to create it is reallyhardcore. In fact I believe it is set by transfer tools that don't likedifferent sized sectors. Anyway, for now I never found a DSK that tested suchflag, so... So far the only DSK that doesn't work with Writedsk 1.1 is the 5KB Demo 3,because it contains tracks whose sectors are all named the same. 'The Demo' usesthe same technic but work fine though... I may try to find a technic to managethat correctly. About this topic, it is possible that I update WriteDSK to manage specialformats like the ones I'm working on... Just wait and see ! If you have a DSK that doesn't work with WriteDSK, don't hesitate to send it tome, just make sure it works fine on emulators !