CMDRKEY.com Home
  Home    Visit our online store
 

CMD Support



Back to CMD-HD Support

Features of the new HD-DOS+ for the CMD-HD

A new partition type has been added in HD-DOS+ and is known as Extended Native. It is similar to the existing Native partition type but with some added features:


* up to 4GB in size.
* filenames up to 32 characters long
* new format with a Master directory which allows up to 256 root directories

New commands just for Extended Native partitions:

F-P   file pointer command - sets the file pointer to any byte within a file
EC    Create a disk image file
EM    Mount a disk image to another partition
EU    UnMount a disk image and restore the original partition
MR    Make a new root directory within the master directory
CR    Change to a different root directory within the master directory

Modify mode has been implemented in Extended Native partitions. As an example:

OPEN 2,8,2,"FILENAME,M"

This will open an existing file in Modify mode. In this mode, individual bytes within the file can be read from or written to. When first opening the file in Modify mode, the first byte is made ready to read or write to. The F-P command can be used to set the file pointer to any byte within the file.

The F-P command is very fast. It can point to any byte within a file in an Extended Native partition almost as fast as it can the first byte. This is due to the new method used for storing files in these partitions.

Modify mode cannot be used to add additional data to a file. It can only be used to read or write the existing data bytes. If data needs to be added, the file should be closed and reopened in append mode.

The F-P command only works in an extended native partition and only when using Modify mode or Read mode.

There are new attributes in the directory entries for each file. One of these attributes allows you to make a file hidden from normal directory listings. A new command allows you to view the hidden files. Hidden files cannot be deleted using wildcard patterns. To delete a hidden file, the actual filename must be used. This prevents accidental deleting of a file you may have forgotten about.

Another attribute allows you to trash a file, which means it will not show up in a normal directory listing, nor will it show up in a hidden file listing. The file is still there, but appears to be deleted, yet is not really gone. It's data cannot be overwritten which means that it can be recovered if need be. You can also permanently delete any and/or all trashed files. When validating a partition, trashed files are permanently deleted as well.

The EC command will create a disk image file within an Extended Native partition. A disk image file can also be mounted to a partition using the EM command. The EU command will likewise unmount the partition and restore the original contents.

The EC command can create a 1541, 1571, 1581, or Native disk image. A Native image can be anywhere from 64K up to 16MB in size.

Use EM to mount a disk image to a partition. If the partition is an already existing partition, it must be the same type as the disk image. You can also mount the image to a partition that does not already exist. In this case, the type doesn't matter, it will be whatever type the disk image is.

Once mounted to a partition, the disk image can be manipulated just like a normal partition on your HD. You can format it, load and save files, copy files, copy whole disks, etc. For all intents and purposes, it is a normal partition at this time. But it is still stored as a disk image file in the Extended Native partition where you originally created it. The file can be copied to another drive and it will still contain any data you may have placed in it while it was mounted as a partition.

Here's a few examples of how to create a new disk image file:

@EC:MYOWNGAMES.D64,4

This assumes you are already in an Extended Native partition and within the subdirectory where you would like the new disk image file created. The 4 included in the command string tells HD-DOS+ to create a 1541 disk image file. You can use any filename you would like up to 32 characters. It's a standard convention to use .D64 at the end of the filename to help you to identify this as a 1541 disk image, but it's not necessary. HD-DOS+ doesn't care what you use for a filename.

@EC24/GAMES/:GAMEDISK12.D64,4

This would create a disk image file called GAMEDIS12.D64 in partition 24 within the subdirectory named GAMES.

@EC:PART45BACKUP,N,255

This would create a native disk image called PART45BACKUP. It makes this native disk image 255 tracks in size. This would equal a 16MB partition. (Actually, a 16MB partition on a CMD-HD is 64K short of 16MB) You could then use the EM command to mount this as a partition and with MCOPY, you could copy your existing partition 45 to this disk image for archival purposes. Or you could easily make backups of your RAMLink partitions or your FD disks, by simply adjusting the size of the disk image files that you create. A high-density disk formatted for an FD-2000 with one single Native partition would require a disk image that is 25 tracks in size. If you create a native disk image and leave the size parameter off, a disk image with 25 tracks is the default size that will be created.

Using the EM command is simple:

@EM110=PART45BACKUP

This would mount the disk image file called PART45BACKUP to partition 110. It's OK if partition 110 does not exist, the EM command will handle the chore for you. The partition will show up in the partition table when you use the @$=P command.

@EU110

This would unmount the file from partition 110 and if the partition was previously non-existant, it will once again be non-existant. If it was a real partition, the real partition will once again appear and it's original data will be restored.

You can also copy an existing disk image file from another drive to an Extended Native partition and use it as already described. There are also utilities available that can take a disk in your real drive such as a 1541 and create a disk image file on another drive. You can use these utilities to create disk image files of your existing floppy disks. You can also use HD-DOS+ for this task. Just create a disk image using the EC command, and mount it to a partition with the EM command. Then use MCOPY to copy from your real floppy disk in your 1541 (or any other drive) to the partition on your HD. You will now have a backup copy of your disk stored as a disk image file on your HD.

You'll find there is no simpler way to manipulate disk image files than by using your CMD-HD and the software tools you already have and know how to use.

Master Directories

Master Directories are a new feature and are only found in the new Extended Native partitions. When you create a new Extended Native partition and format it, it will have a directory just like a normal native partition. You can use the MD command to create subdirectories just like you do in a native partition. Everything will seem very familiar to you. There is nothing new to learn. It's just a bigger partition. In fact, the minimum size for an Extended Native partition is 16MB, which is the maximum for a Native partition. The Extended Native partition can be much, much bigger. It can be as large as 4GB. 4GB is 256 times larger than 16MB.

A 16MB partition already seems huge to anyone used to using a 1541 drive, so what could we possibly do with 4GB. It would take a tremendous number of Commodore files to fill something this large. Sure it can be broken down into subdirectories, but there is also another feature. When you are in the root directory, you are actually still one directory level down from the top. There is a Master directory residing above the root directory.

When you view the directory through normal means such as with @$, you will be listing the current directory you are in. This would be either the root directory or maybe a subdirectory that resides within this root directory. Use @$$ to view what is known as the Master directory. You'll notice there is only one directory entry in the Master directory. This would be the root directory that you have been using and the one that was created when the partition was first formatted.

Use the MR command to make a new root directory:

@MR:1541DISKBACKUPS

Now use @$$ to view the Master directory and you will see two root directory entries. Do this:

@CR:1541DISKBACKUPS

The CR command will change to a different root directory. This will be the root directory that will be used in this partition until you either use the CR command again or reset the drive. Once the drive is reset, the default root directory will once again be current.

You can have as many as 256 root directories and you can make any one of them the default root directory which will be used when the HD is first powered up or reset. All other root directories are normally not visible until you use the CR command to change to one of them.

Multiple root directories within an Extended Native partition is like having additional multiple partitions. This lets you really make use of that huge 4GB partition. Of course, you don't have to make your Extended Native partition this big. If 100MB is large enough, that OK too.

Extended Foreign Partitions

Just like there is a new Extended Native partition that gives additional power over our existing Native partitions, there is also a new Extended Foreign partition that can be used in place of our existing Foreign partitions. Foreign partitions are rarely used, and likewise Extended Foreign partitions will probably also be rarely used. But they are there is you ever need one. There is no file system features, which means you can't store files and view directories and such. You can only access a Foreign and Extended Foreign partition using direct access methods, by reading and writing whole blocks at a time.

An Extended Foreign partition can be anywhere from 32MB to 8GB in size.

An Extended Foreign partition requires a programmer to write software specific for it. However, there are many possibilities for its use. It can be used to store data that will be later written out to a writeable CD-ROM, for instance. Or maybe raw data can be stored such as music or video data. It just takes thinking and some work on somebody's part to make use of it.

Print Spooler

HD-DOS+ has a new feature that allows you to finally make good use of that auxiliary port on the back. You can plug in a Commodore-ready printer or a parallel printer interface into the auxiliary port and use the HD as a print spooler.

You can configure the HD as either device 4 or 5 and it also be configured to send data to device 4 or 5 out the auxiliary port. You also set up a special partition to be used just for the print spooler. When you are using a program that sends data to a printer, the HD will catch the data instead of the printer. It can capture the data very fast because the data will come over the serial port using JiffyDOS speeds. It will also catch the data over the parallel cable if you have one connected to a RAMLink. When the print data enters the HD, it will be transferred to the printer partition. Almost immediately when the data starts to enter the HD, it will be sent directly out the auxiliary port to the printer.

Most printers can't accept the data as fast as the computer can send it. But the HD can accept it quickly. So, the data will actually build up in the HD's printer partition while it continues to be spooled out to the printer. As soon as the computer is finished sending data, your program will return control to you and you may then continue on with something else. Meanwhile, the HD will continue to send the captured data to the printer. While this is going on, you are still able to use the HD for other purposes such as loading another program or performing some other task with the HD. Just be sure not to turn the HD off or reset it until the printing is finished.

A printer buffer partition can be as large as 32MB, although it's doubtful you would ever need one that large. One or two megabytes is generally sufficient for most people.


 
 
 


Copyright © 2001-2007 Click Here Software Co.
Comments and questions regarding this site
should be directed to support@cmdrkey.com