back to buchty.net
Casiorama
back to main page

How to use a PC 3.5" HD disk drive with your FZ-1
Trying to reach me?
Recently I bought a used FZ-1 with a dead disk drive. Fortunately, the disk controller itself was alright, but the drive was broken.  Casio, however, decided to implement the standard Shugart bus instead of the (nowadays widely used) PC/AT disk bus which -- at first sight -- drives a normal PC disk drive useless as replacement part.

Suggestions, questions, acclamation, or simply curiosity about who that guy is you might want to place here:

rainer@buchty.net

To fight spam, I'm running RBL-based filtering and Greylisting, so if your ISP's mail server is blacklisted or doesn't play according to the SMTP RFC, you might encounter bounces.

Floppy mysteries part 1: Japan spins faster...

For some kind of reason (there must be one...) the so-called Japanese 3.5" floppies spin with 360rpm like the old 5.25" drives instead of 300rpm as the rest of the world does. Casio, in their eternal wisdom, decided to use such a non-standard configuration.

If you have a working JU-386 and you want to make it PC-compatible in terms of rotation speed, you need to change the settings at JP1 on the motor PCB (not controller PCB!) as shown in the below table. Installing a switch at pins 1/2 therefore allows you to switch between conventional 300rpm (and therefore allow disks being read/written with your PC) and Casio's own 360rpm for legacy disks.

RPMData Rate JP1 setting
3002501-2 short
3-4 open
3603001-2 open
3-4 open
JU-386 Jumper settings for adjusting the drive's rotation speed

Unfortunately, almost no floppy I've seen so far—apart from the aforementioned Panasonic JU-386 used in the FZ-1—has a "speed select" switch although the commonly used motor controllers have such an input which put me instantly in hunting mode when opening a TEAC FD-235 (of which I got a few so an eventually killed drive wouldn't be that big issue here). Having done so, I played around with a Mitsumi/Newtronics D359.

In case you did the same with other drives, just let me know and I'll include it in the below table.

Drive ModelDrive ControllerModification
TEAC
FD-235/HF
BA6478HF
(Rohm)
Remove W61, attach a switch to W61's pads; solder W61 between two poles of the switch to allow either W61 to be present (300rpm) or not (360rpm)
Mitsumi/Newtronics
D359T3
LB1810
(Sanyo)
see BA6478HF, but use pin 12 of LB1810; notice that 360rpm will be selected by applying Vcc, 300rpm by GND.
generic BA6478HF
(Rohm)
Desolder and isolate pin 3 of controller; attach a switch to pin 3 which allows pulling that pin to GND (300rpm) or Vcc (360rpm).
generic BA6492BFS
(Rohm)
see BA6478HF, but use pin 29 instead of pin 3
generic LB1810
(Sanyo)
see Mitsumi/Newtronics D359/T3
Drive modifications for switching between 300 and 360rpm

Looking at the datasheets of various Rohm and Sanyo FDD spindle drivers, the following applies:

RPM
Manufacturer300360600
Rohm  0-1V  4-5V  2-3V 
Sanyo  0-0.8V  2-5V see LB1817M
Toshiba 0-2V  3-5V ---

Pins
ManufacturerTypeSpeed SelectOsc Input(s)
Rohm BA6477FS 6 7
BA6478HF 3 4
BA6486FS 6 7
BA6492BFS2930
Sanyo LB1810 12 ???
LB1817M see below16/17
LB1890M 1517/18
LB1910 5 6
LB1913 5 6
ToshibaTA8463F 1517

The LB1817M gives even more flexibility and provides a total of 3 divider inputs (MS1 to MS3), resulting in the following speed table:

RPMMS1 (12)MS2 (11)MS3 (10)
300LLH
360HLH
600LLL
600LHH
720HLL
720HHH
1200LHL
1440HHL
LB1817M rotation speeds
(based on 1MHz crystal)

In case you want to upgrade machines to supporting HD disks even though their controller only copes with DD speeds (like the WD177x line of FDCs or PAULA on the Commodore Amiga), you have two essential options:

  • Use switchable input clocks (might eventually require switchable PLL components, too) and go for uniform 300rpm setting, this is what e.g. this approach describes.
  • Tweak the Rohm BA6492 or Sanyo LB1817 to half the clock rate and then switch between 300 and 600rpm mode, resulting in 150 and 300 rpm operation.

Floppy mysteries part 2: The PC/AT floppy bus

Let's first have a look at the PC/AT floppy bus (a lot of people, including me before doing some recherche work, think that it's the original Shugart bus - this is wrong) bus which is the standard interface for disk drives since the great success of the PC architecture. It's using a 34pin connector where all odd-numbered pins are grounded, only even-numbered pins carry control signals:
 
 
Pin
Direction
Name
Description
2 out /REDWC Density Select
4 -
unused
 
6 -
unused
 
8 in /INDEX Index Pulse
10 out /MOTEA Motor Enable A
12 out /DRVSB Drive Select B
14 out /DRVSA Drive Select A
16 out /MOTEB Motor Enable B
18 out /DIR Step Direction
20 out /STEP Step Pulse
22 out /WDATA Write Data
24 out /WGATE Write Enable
26 in /TRK00 Track 0
28 in /WPT Write Protect
30 in /RDATA Read Data
32 out /SIDE1 Head Select
34 out /DSKCHG Disk Change
PC/AT FDD Connector

What's the real standard: The Shugart Bus

The original Shugart bus doesn't differ much from this layout but enough to make a standard PC drive pretty unusable together with the FZ-1. But there's hope, just compare the pinout (again all odd-numbered pins but without pins 1 and 3 are grounded, for some unknown reason Casio left these unconnected - grounding them does not cause any harm to drive or FZ-1):
 
 
Pin
Direction
Name
Description
2 -
unused
Head Load (not used with the FZ-1) 
4 out /BUSY drive lamp lights when low (same as /DS0)
6 out /DS3 Drive Select 3 (tied to Vcc)
8 out /INDEX Index Pulse
10 out /DS0 Drive Select 0
12 out /DS1 Drive Select 1 (tied to Vcc)
14 out /DS2 Drive Select 2 (tied to Vcc)
16 out /MOT Motor Enable
18 out /DIR Step Direction
20 out /STEP Step Pulse
22 out /WDATA Write Data
24 out /WGATE Write Enable
26 in /TRK00 Track 0
28 in /WPT Write Protect
30 in /RDATA Read Data
32 out /SIDE1 Head Select
34 in /READY low when FDD is available
Shugart Bus Connector

Back in the days, a number of standards coexisted. Hence, the disk-drive vendors put more or less effort in making a drive configurable for either Shugart or PC use. If you have the choice, go for these drives:

  • Panasonic JU257 Rev. (I'll look it up next time I open my DSS-1, promised): this wonderful drive is fully jumperable
  • TEAC FD235HD Rev. 3xxx: also this drive is fully jumperable, but makes an adventure game of it.
  • TEAC FD235HD Rev. A529: this drive is also fully jumperable, but makes even more an adventure game of it. Close D2/E2 (RDY# to Pin 34) and remove E1/E2 (DC# to Pin 34). Also close A1/B1 (Pin 10 to DS0).
  • Mitsumi/Newtronics D359Tx: once you remove the bottom cover, you'll find solder-in jumpers for configuration. Not as comfortable as the JU257, but never the less flexible.
The most common drive in circulation probably is the TEAC FD235HF. It is, however, strongly targeted towards the PC market and exists in a plethora of different revisions. Earlier revisions typically at least offer solder-in jumpers for Pin 34 configuration, later ones require trace-cutting and rewiring. The information given here most likely applies to other drives using the same controllers:
  • Rev. 218-U (IR4N09A): Select Drive 0 via jumper; remove all other jumpers. Remove solder-jumper at S27 (DC#) and close the solder-jumper ad S29 (RDY#).
  • Rev. 4291 and 4430 (T4A34F): Select Drive 0 via jumper; remove solder-jumper S18 (DC#), close solder-jumper S19 (RDY#).
  • Rev. 5291-U (T4A34F): Select Drive 0 via jumper; cut trace at pin 69 (DC#), wire pin 68 (RDY#) to the floppy connector, pin 34.
  • Rev. 6291 (BH95060GKS2): Select Drive 0 via jumper; cut trace from floppy connector pin 34 to floppy controller and rewire pin 34 to the controller pin 10 (RDY#).
  • Rev. 7291-U5 (BH95060GKS2): There's two solder-jumpers for selecting the drive ID, solder it to DS0, rest see 6291.
  • Rev. 8291-U5 (TRN9510A): Unknown (yet) for lack of controller datasheet. Judging from a published NEC FD1231H hack, RDY# is on pin 32, DC# on pin 55.
  • Rev. A291-U5 (TB604HF): Unknown (yet) for lack of controller datasheet.

Likewise, a number of revisions of the Panasonic JU257 and the Mitsumi/Newtronics D359 exist that are more or less easy adjustable.

(In case you're an Amiga user who came here by Google, the above procedures apply to you, too, but don't forget to wire DC# to floppy connector pin 2. The Amiga needs both!)

Here you'll find a plethora of information and further links -- most of it in German, but your favorite online translator should do a half-way sensible job here.

See also here if and how your disk drive's pin 34 behaviour can be changed from disk change to disk ready as needed for proper FZ-1 (or DSS-1) operation.
 

Hackware
As you can see, only a few lines differ. Casio never planned to use up to 4 floppies in one system, thus /DS1 to /DS3 are disabled (tied to Vcc). Only /DS0 is functional and electrically identical to /BUSY so you can treat this pair as one single signal.

/READY is something unsual to the PC world -- according to the service manual, the FDD grounds this signal when all of the following conditions are satisfied:

  • all the voltages are supplied
  • the floppy disk's rotation is over 84% of the normal rotation speed
  • a floppy disk is loaded
  • /DIR is set to 0
  • head is on track 0 at power on
To make it short: It shows that the drive is accessible. Since the uPD72065 knows about parameters like head (un)load times and seek time, there's no real need for this signal. However, the FZ-1 does not only need it but even strictly relys on it (see below).
 
 

The interface

According to the above tables the interface cable allowing to connect a PC disk drive to your Casio FZ-1 looks like this:
 
Casio FDD Connector
PC/AT FDD Connector
Description
Pin Name Pin Name
10
/DS0 14
12
/DRVSA
/DRVSB
Drive 0 Select
16
/MOT 10
16
/MOTEA
/MOTEB
Motor 0 Enable
8
/INDEX
8
/INDEX Index Pulse
18
/DIR
18
/DIR Step Direction
20
/STEP
20
/STEP Stepping Pulse
22
/WDATA
22
/WDATA Write Data
24
/WGATE
24
/WGATE Write Gate / Write Enable
26
/TRK00
26
/TRK00 Track 0 Signal
28
/WPT
28
/WPT Write Pulse
30
/RDATA
30
/RDATA Read Data
32
/SIDE1
32
/SIDE1 Side Select (0=Head 1)
odd
GND
odd
GND Ground
Casio FDD Connector Casio FDD Connector Description
Pin Name Pin Name
34
/READY
10
/DS0 Drive Ready / Disk Changed
Casio to PC/AT FDD Interface Cable

Normally, 3.5" PC drives are jumpered to be drive 1 (that's why they need that cable crossing). If you don't want to change the drive jumpering, wire /DS0 and /MOT with their "B" counterparts, otherwise "A".

What you also need to do, is connecting /READY to /DS0 as shown in the table's second half. Although it might work for other systems, the FZ-1 doesn't accept the /DSKCHG signal as /READY.

Attention: In my special case using the /MOT line for motor control resulted in a permanently spinning floppy. This may result from a defective NAND gate which drives that line -- I just didn't care. Instead of using the /MOT line I wired /DS0 to /MOTEx which works perfectly for me.
 
 

Disadvantages

The FZ-1 OS unfortunately relys on the /READY signal, which during normal operation mainly shows the presence of a disk, therefore it has no error routines dealing with no disk present or a disk being removed during load/save. When operating with a faked /READY signal such as shown above the FZ-1 OS doesn't encounter any error - and keeps on performing the desired disk operation forever. All you can do in this situation is switching your FZ-1 off and on again ...

As long as you take care of your disks being fed into the drive before performing any disk operation, there's no disadvantage besides the fact that usual PC disk drives are thinner than the original one resulting in a small space between drive and drive cover.

See this website from Frank Durda IV to check if your drive can easily be converted from disk change to disk ready behaviour on pin 34.