Return-path: 
Received: from RUBY.VCU.EDU by ANACIN.NSC.VCU.EDU (PMDF V4.3-10 #8240)
 id <01IG225VQOK08WYS9W@ANACIN.NSC.VCU.EDU>; Mon,
 03 Mar 1997 06:57:48 -0500 (EST)
Received: from vms.eurokom.ie (vms.eurokom.ie)
 by Gems.VCU.EDU (PMDF V5.0-8 #13707) id <01IG226EYG409JNT6W@Gems.VCU.EDU> for
 JIM@ANACIN.NSC.VCU.EDU; Mon, 03 Mar 1997 06:58:18 -0400 (EDT)
Received: from vms.eurokom.ie by vms.eurokom.ie (PMDF V5.0-6 #8109)
 id <01IG2EHZIAXC001CA3@vms.eurokom.ie>; Mon, 03 Mar 1997 12:57:16 +0100 (CET)
Date: Mon, 03 Mar 1997 12:57:16 +0100 (CET)
From: Peter Coghlan 
Subject: Update to Microvax FAQ
To: JIM@ANACIN.NSC.VCU.EDU, rdd@digex.net
Message-id: <01IG2EHZKNOY001CA3@vms.eurokom.ie>
X-VMS-To: IN%"JIM@ANACIN.NSC.VCU.EDU", IN%"rdd@digex.net"
X-VMS-Cc: PCOGHLAN
MIME-version: 1.0
Content-transfer-encoding: 7BIT


Jim and Robert,

    Can you please update my contribution to the Microvax FAQ with the
text below? The procedure currently on offer is very old and contains some
errors. Thanks in advance

                            Peter.


-----------------------  Cut here -------------------------------------------
$!
$! PatchDvDriver.Com  V1.6          By: Peter Coghlan 10-Aug-1996
$!				        Peter.Coghlan@EuroKom.Ie
$!
$! This procedure is a hack to enable the use of a 1.44Mb 3.5in floppy drive on
$! a Vaxstation 2000 or Microvax 2000 instead of the designed for 5.25in 1.2Mb
$! devices.
$!
$! I have used it successfully with a standard off-the-shelf 3.5in high density
$! floppy drive intended for use in a PC connected in place of an RX33. These
$! can be happliy mounted in a Vaxstation 2000 using a mounting kit intended
$! to mount a 3.5in drive in a 5.25in PC drive slot. It should also work with
$! a standard RX23 drive.
$!
$! Patches are made to the device driver which controls the floppy drive
$! (DVDRIVER.EXE) which cause it to treat the drive as a 3.5in 1.44Mb (RX23)
$! floppy drive instead of the designed for 5.25in 1.2Mb drive (RX33).
$!
$! It was designed for use with and has been tested with VMS V5.5-2. It also
$! may work with VMS V6.1. Code has been included to deal with VMS V5.5-1
$! where the offsets of the data to be patched are different. I do not know
$! whether this works or not as I do not have a 5.5-1 system with a floppy.
$! This code might also work with earlier versions of VMS.
$!
$! As with all such procedures, ensure you have a good backup of your system
$! before proceeding. Also ensure you test the patched driver using floppies
$! which do not contain valuable data. As always, everything is at your own
$! risk.
$!
$! After running this procedure, reboot the machine to bring the new driver
$! into use. Note that this procedure only changes the way VMS sees the disk
$! drive. It does not affect the way the console code sees it. This causes the
$! following two limitations :
$!
$!    TEST 70 cannot be used to format 1.44Mb disks. In practice this is not
$!    a serious problem as the following alternatives are available :
$!
$!      o Preformated (for MSDOS) disks can be used as the sector size, number
$!        of sectors per track and number of cylinders is the same. These disks
$!        can be turned into Files-11 disks using the INITIALIZE command.
$!
$!      o If Pathworks is installed, the FORMAT command of the PCDISK utility
$!        can be used. Although this creates a MSDOS formatted disk, as noted
$!        above, this is not a problem. Use the command RUN SYS$SYSTEM:PCDISK
$!        to start up the utility.
$!
$!      o Write a small program which assigns a channel to the device and calls
$!        SYS$QIO using the IO$_FORMAT function code and P1 set to 2.
$!
$!      o A VMS machine with a real RX23 or a PC with a 3.5in High Density disk
$!        drive can be used for formatting.
$!
$!    It is usually too much trouble to shut down the machine in order to use
$!    TEST 70 anyway!.
$!
$!    1.44Mb 3.5in disks cannot be used to boot from. If it is required to boot
$!    from the floppy drive, then 1.2Mb disks must be written. It does not 
$!    matter that these are 3.5in rather than 5.25in. 1.2Mb disks can be built
$!    by bringing the original unmodified DVDRIVER into use. This can be done by
$!    renaming the new version of DVDRIVER.EXE created by this procedure and
$!    rebooting the machine.
$!
$! In order to successfully use an RX33 drive again, the patched version of
$! DVDRIVER.EXE should be renamed or otherwise removed and the machine
$! rebooted.
$!
$! Cluster considerations:
$!
$! RX23/RX33 drives are not served to the cluster by default. If access is
$! required from other cluster nodes, issue a SET DEVICE /SERVED command for
$! the device on the node where it is directly connected. This will need to be
$! repeated after each system startup.
$!
$! Only machines which have directly attached floppy drives need to have their
$! DVDRIVER.EXE patched. If the drive is served to other members of the cluster
$! they will see it correctly without needing any patches.
$!
$! If the cluster boots from a common system disk and a mixture of RX23 and
$! RX33 drives are present, the patched DVDRIVER.EXE should be moved from
$! sys$common and placed in the appropriate specific directories for those
$! nodes which have RX23 drives attached. All nodes will then be able to see
$! all served and directly attached RX23 and RX33 drives correctly. Care should
$! be taken at system upgrades to ensure that patched drivers are removed from
$! node specific directories before beginning the upgrade procedure.
$!
$! Anything which attempts to format (not initialize) a floppy disk must be
$! done on the machine to which the drive is directly attached. This limitation
$! is nothing to do with whether DVDRIVER is patched or not but is worth
$! mentioning here as it is not obvious (to me anyway!).
$!
$! Changes in V1.6 :	Preserve default device and directory settings.
$!			Update documentation (ie these comments).
$!
$! Changes in V1.5 :	Fix handling of IO$_FORMAT so that the FORMAT command
$!			of the PCDISK component of Pathworks works correctly.
$!
$! Changes in V1.4 :	Update documentation (ie these comments).
$!
$! Changes in V1.3 :	Add support for VMS V5.5-1.
$!
$ Set NoOn
$ Default = F$Environment("Default")
$ Set Default Sys$Common:[Sys$Ldr]
$
$ If F$Extract(1, 5, F$GetSyi("Version")) .Ges. "5.5-2"
$ Then
$
$ Write Sys$Output "Using patch offsets for VMS V5.5-2 and later"
$
$ Patch /New_Version DvDriver
! Fix MSCP Media Id
Replace /Hex /Long
013B
25658021
Exit
25658017
Exit
! Fix device type
Replace /Hex /Byte
013F
24
Exit
37
Exit
! Fix device type
Replace /Instruction
0643
"MOVB #24,B^4D(R5)"
Exit
"MOVB #37,B^4D(R5)"
Exit
! Fix total block count for Format function
Replace /Instruction
0C95
"MOVZWL #0960,W^00C4(R5)"
Exit
"MOVZWL #0B40,W^00C4(R5)"
Exit
! Fix Sectors per track for Format function
Replace /Instruction
0C9C
"MOVB #0F,B^50(R5)"
Exit
"MOVB #12,B^50(R5)"
Exit
! Fix device type
Replace /Instruction
18DD
"MOVB #24,B^4D(R5)"
Exit
"MOVB #37,B^4D(R5)"
Exit
! Fix total block count for other functions
Replace /Instruction
18F0
"MOVL #00000960,W^00C4(R5)"
Exit
"MOVL #00000B40,W^00C4(R5)"
Exit
! Fix Sectors per track for other functions
Replace /Instruction
18F9
"MOVB #0F,B^50(R5)"
Exit
"MOVB #12,B^50(R5)"
Exit
Update
$
$ Else
$
$ Write Sys$Output "Using patch offsets for VMS V5.5-1"
$ 
$ Patch /New_Version DvDriver
! Fix MSCP Media Id
Replace /Hex /Long
013B
25658021
Exit
25658017
Exit
! Fix device type
Replace /Hex /Byte
013F
24
Exit
37
Exit
! Fix device type
Replace /Instruction
0643
"MOVB #24,B^4D(R5)"
Exit
"MOVB #37,B^4D(R5)"
Exit
! Fix total block count for Format function
Replace /Instruction
0C94
"MOVZWL #0960,W^00C4(R5)"
Exit
"MOVZWL #0B40,W^00C4(R5)"
Exit
! Fix Sectors per track for Format function
Replace /Instruction
0C9B
"MOVB #0F,B^50(R5)"
Exit
"MOVB #12,B^50(R5)"
Exit
! Fix device type
Replace /Instruction
18DC
"MOVB #24,B^4D(R5)"
Exit
"MOVB #37,B^4D(R5)"
Exit
! Fix total block count for other functions
Replace /Instruction
18EF
"MOVL #00000960,W^00C4(R5)"
Exit
"MOVL #00000B40,W^00C4(R5)"
Exit
! Fix Sectors per track for other functions
Replace /Instruction
18F8
"MOVB #0F,B^50(R5)"
Exit
"MOVB #12,B^50(R5)"
Exit
Update
$
$ Endif
$
$ Set Default 'Default'
$