Changeset 320 in xtideuniversalbios
- Timestamp:
- Mar 11, 2012, 9:08:31 AM (13 years ago)
- google:author:
- gregli@hotmail.com
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
wiki/SerialDrives.wiki
r319 r320 25 25 == Getting Started == 26 26 27 * 1. Connect the two machines via the serial connection. * 27 === 1. Connect === 28 28 29 * 2. Open a command prompt, and run the SerDrive utility on the server. * Arguments are described below. In its simplest form: 30 {{{ C:/> SerDrive MyImage.img }}} 31 If you do not already have an image, you can obtain boot floppies of FreeDOS from. 29 Connect the two machines via the serial cable. 30 31 === 2. Start the Server === 32 33 Open a command prompt, and run the SerDrive utility on the server. Switches are described below. In its simplest form: 34 {{{ C:/> SerDrive ImageFile.img }}} 35 If you do not already have an image, you can obtain boot floppies of FreeDOS at [http://www.fdos.org/bootdisks/ www.fdos.org] and possibly at the FreeDOS home page at [http://www.freedos.org www.freedos.org] (although they tend to distribute FreeDOS as a CD-ROM image). 32 36 SerDrive will use the first available COM port by default, at a speed of 9600 baud (which is reliable, but relatively slow, you will likely want to increase this for continued use). 33 37 34 * 3. Boot the client computer. During drive detection, hold down the Alt key, and at the end of drive detection, the BIOS will display "Serial Master on COM Detect". * The BIOS will now scan the available COM ports on the client (COM 1-7), looking for a server. 38 === 3. Boot the Client === 39 40 Boot the client computer. * During drive detection, hold down the Alt key, and at the end of drive detection, the BIOS will display "Serial Master on COM Detect". * The BIOS will now scan the available COM ports on the client (COM 1-7), looking for a server. You can also configure the BIOS with XTIDECFG to always boot from the serial port (see below). 35 41 36 42 If a server is found, the floppy and/or hard disk emulated will appear in the boot menu for the BIOS. You can now proceed as normal. 37 43 38 SerDrive is stateless, and flushes writes to the image files immediately. You can start and stop the server at will, although this is not recommended. If the server is stopped and a disk access is attempted by the client, that request will result in an error on the client. Also, changing the image file without also rebooting the client may result in unexpected behavior and possible data loss.44 If you have problems, start by adding the {{{-v}}} switch to SerDrive and it will report on each connection request and sector transferred. If that still doesn't work, you may want to try a basic serial communications program to see if you can send and receive characters across the serial port. Depending on your version of Windows, it may include a serial communications program, or you could try a program such as [http://www.kermitproject.org/ Kermit]. 39 45 40 46 = Performance = … … 44 50 It depends. Using high speed UARTs at a speed of 460K, performance is on par with floppy disk drives of the vintage era, without any of the seek time or interleave factors to slow it down (we're assuming the server PC is very fast and is caching heavily used sectors in memory). With this level of throughput, serial drives are slower than a vintage hard disk, but not by much, and the system is completely usable. 45 51 46 Using slow speed UARTs, at a speed of 38.4K, which is commonly the top speed for vintage serial ports, the serial drives are quite slow. However, if this is used infrequently, say when it is needed to bootstrap an OS in order to format a locally attached hard disk, the delay can be worth it, and less hassle than finding a working floppy disk drive and floppy disk with the required image.52 And then there is the bootstrap scenario. Imagine you find yourself with a PC without a working floppy disk drive, or the system floppy disk you want to boot is unreadable. With only a standard COM port, common back in the day, you can still boot this machine and FDISK and/or FORMAT an attached hard disk. It will take some time, no question about it, the top speed of many of these vintage COM ports was 38.4K. But it will eventually boot. 47 53 48 Here's how various drives compare :54 Here's how various drives compare on performance, including the serial drives: 49 55 50 56 || || *5.25" DSDD Floppy* || *3.5" HD Floppy* || *Original IBM PC XT Hard Disk* || *38.4K Baud Serial Drive* || *460K Baud Serial Drive* || 51 || Theoretical Max, Bytes per Second || 31K || 62K || 87K || 3.8K || 46K || 52 || Observed Speed, Bytes per Second || || || || 3.7K || 42K Read, 37K Write || 53 || Time to Boot MS-DOS 3.3, Seconds || || || || || || 57 || Theoretical Max Speed, Bytes per Second || 31K || 62K || 87K || 3.8K || 46K || 58 || Observed Speed, Bytes per Second || || 42K || || 3.7K || 42K Read, 37K Write || 59 || Time to Boot MS-DOS 3.3, Seconds || || 14.5 || || 30.5 || 3.6 || 60 || Time to Burst Read 274,688 bytes, Seconds || || 6.6 || || 72.1 || 6.9 || 61 62 So, how can boot time be so much faster with the serial connection than a floppy disk, yet burst read speed be worse? There is a lot of overhead with seeking between tracks, waiting for the motor to spin the desired sector under the read head, etc. that goes away with the serial connection. Even at a baud rate of 38.4K, 30 seconds is of course slow to boot, but completely reasonable for a boostrapping scenario. 54 63 55 64 Note that at high speed, write performance for serial drives is slightly worse than read performance - the BIOS code is optimized for read performance. 56 65 57 To help measure performance, SerDrive's "-v"switch with a value of 1 or higher will also display performance measurements for transfers of more than 100 sectors at a time.66 To help measure performance, SerDrive's {{{-v}}} switch with a value of 1 or higher will also display performance measurements for transfers of more than 100 sectors at a time. 58 67 59 68 Performance number Notes: 60 69 * Serial drive theoretical max taken by dividing bit rate by 10, allowing for start and stop bits. Wikibooks has a discussion of [http://en.wikibooks.org/wiki/Serial_Programming:RS-232_Connections#Data_Transmission_Rates Data Transmission Rates] based on RS-232 serial communications overhead, in the Wikibook _[http://en.wikibooks.org/wiki/Serial_Programming:RS-232_Connection Serial Programming/RS-232 Connections]_. 61 * Floppy disk characteristics from Scott Mueller's _[http://books.google.com/books?id=E1p2FDL7P5QC&pg=PA649 Upgrading and Repairing PCs]_, Page 649.70 * Floppy disk characteristics from Scott Mueller's _[http://books.google.com/books?id=E1p2FDL7P5QC&pg=PA649 Upgrading and Repairing PCs]_, 15th Anniversary Edition (2004), Page 649. 62 71 * IBM PC XT Hard Disk performance as calculated based on maximum throughput and sector interleave by Steve Gibson in [http://books.google.com/books?id=CD8EAAAAMBAJ&pg=PA36 "The Ways and Means of Faster Data Throughput"], _InfoWorld_, March 7, 1988, Page 36. 63 72 * Observed speeds and timings done on an original 4.77 MHz 8088 based IBM PC 5150. 64 73 65 74 = Configuring with XTIDECFG = … … 73 82 * {{{ Usage: SerDrive [options] imagefile [[slave-options] slave-imagefile] }}} * 74 83 75 * _Specify Disk Geometry:_ -g [cyl:head:sect] * 84 You can stop SerDrive by pressing Ctrl-C. SerDrive is stateless, and flushes writes to the image files immediately. You can start and stop the server at will, although this is not recommended. If the server is stopped and a disk access is attempted by the client, that request will result in an error on the client. Also, changing the image file without also rebooting the client may result in unexpected behavior and possible data loss. 76 85 77 Geometry in cylinders, sectors per cylinder, and heads. -g also implies CHS addressing mode (default is LBA28). 86 * _Specify Disk Geometry:_ {{{-g}}} [cyl:head:sect] * 78 87 79 * _Create New Disk Image:_ -n [megabytes] * 88 Geometry in cylinders, sectors per cylinder, and heads. {{{-g}}} also implies CHS addressing mode (default is LBA28). 89 90 * _Create New Disk Image:_ {{{-n}}} [megabytes] * 80 91 81 92 Create new disk with given size or use -g geometry. Maximum size is 137438 MB (the LBA28 size limit). Floppy images can also be created, such as "360K". Default disk size is 32 MB disk, with a CHS geometry 65:16:63. 82 93 83 * _Emulator Pipe Mode:_ -p[pipename] *94 * _Emulator Pipe Mode:_ {{{-p}}} [pipename] * 84 95 85 96 Named Pipe mode for emulators. Pipe name must begin with "\\", default is "\\.\pipe\xtide". 86 97 87 * _Specify COM Port:_ -cCOMPortNumber *98 * _Specify COM Port:_ {{{-c}}} COMPortNumber * 88 99 89 100 COM Port to use (default is first found). The usage message will also list the available COM ports on this system. 90 101 91 * _Specify Baud Rate:_ -bBaudRate *102 * _Specify Baud Rate:_ {{{-b}}} BaudRate * 92 103 93 104 Baud rate to use on the COM port. If the client machine has a hardware rate multipler (for high speed operation), then that will impact this setting: … … 102 113 Note that in Windows' Device Manager, a high speed COM port may still show that it's maximum speed is 128K baud. Do not be alarmed, this setting has no impact on what SerDrive does with the Windows API, where the higher speeds are available. No manual setup of the serial port is required before SerDrive runs. 103 114 104 * _Disable Operation Timeout:_ -t*115 * _Disable Operation Timeout:_ {{{-t}}} * 105 116 106 117 Disable timeout, useful for long delays when debugging. 107 118 108 * _Read Only Disk:_ -r*119 * _Read Only Disk:_ {{{-r}}} * 109 120 110 121 Treat the disk as a Read Only disk, SerDrive will not allow writes. 111 122 112 * _Verbose:_ -v[level] *123 * _Verbose:_ {{{-v}}} [level] * 113 124 114 125 Reporting level 1-6, with increasing information as the number increases. This switch can be very useful for seeing the secot-by-secotr traffic between the PC and the hard disk. 115 126 116 The "-v"switch with a value of 1 or higher will also display performance measurements for block transfers of more than 100 sectors.127 The {{{-v}}} switch with a value of 1 or higher will also display performance measurements for block transfers of more than 100 sectors. 117 128 118 129 * _ImageFiles:_ ImageFileName * … … 161 172 Floppy and hard disk image files can be shared between the XTIDE Universal BIOS and other emulators, such as [http://bochs.sourceforge.net Bochs]. One nice feature of this is that bootable images can be created and tested in an emulated enivornment, copmlete with multiple floppy and CD-ROM drives, and then the resulting image can be used with physical hardware through the BIOS. 162 173 163 Bochs was heavily used in the development of the serial code, as its debugger offers control over the emulated system that is hard to accomplish on actual hardware. You can run the XTIDE Universal BIOS in Bochs as an installed option ROM, and interface with Bochs' emulate IDE hard disks and serial ports. To support serial ports, SerDrive's "-p" switch can be used to run over a Win32 named pipe instead of a physical COM port, and Bochs can be set to emulate a COM port over a named pipe. In addition, it can be set to emulate a specific baud rate from the client (Bochs), using the standard "-b" switch. The "-t"switch is useful to prevent the server from timing out on operations, if a breakpoint is hit in the BIOS code.174 Bochs was used in the development of the serial code, as its debugger offers control over the emulated system that is hard to accomplish on actual hardware. You can run the XTIDE Universal BIOS in Bochs as an installed option ROM, and interface with Bochs' emulate IDE hard disks and serial ports. To support serial ports, SerDrive's {{{-p}}} switch can be used to run over a Win32 named pipe instead of a physical COM port, and Bochs can be set to emulate a COM port over a named pipe. In addition, it can be set to emulate a specific baud rate from the client (Bochs), using the standard {{{-b}}} switch. The {{{-t}}} switch is useful to prevent the server from timing out on operations, if a breakpoint is hit in the BIOS code. 164 175
Note:
See TracChangeset
for help on using the changeset viewer.