Академический Документы
Профессиональный Документы
Культура Документы
Single/Double Density
NEC Electronics Inc. Floppy-Disk Controller
Description Features
The uPD765A/B is an LSI floppy disk controller (FDC) Address mark detection circuitry is internal to the FDC
chip which contains the circuitry and control functions which simplifies the phase-locked loop and read elec-
for interfacing a processor to 4 floppy disk drives. It is tronics. The track stepping rate, head load time, and
capableof either IBM 3740singledensity format (FM), or head unload time are user-programmable. The
IBM System 34 double density format (MFM) including uPD765A/uPD765B offers additional features such as
double-sided recording. The uPD765A/B provides con- multi-track and multi-side read and write commands
trol signals which simplify the design of an external and single and double density capabilities.
phase-locked loop and write precompensation circuitry.
FM, MFM Control
The FDC simplifies and handles most of the burdens as-
sociated with implementing a floppy disk interface. Variable recording length: 128,256, .8192 bytes/
sector
Hand-shaking signals are provided in the uPD765A/B
which make DMA operation easy to incorporate with the IBM-compatible format (single- and double-
aid of an external DMA controller chip, such as the sided, single- and double-density)
uPD8257. The FDC will operate in eitherthe DMA or non- Multi-sector and multi-track transfer capability
DMA mode. In the non-DMA mode the FDC generates
Drive up to 4 floppy or micro floppydisk drives
interrupts to !he processor every time a data byte is to
be transferred. In the DMA mode, the processor need Data scan capability-will scan a single sector or
only load the command into the FDC and all data an entire cylinder comparing byte-for-byte host
transfers occur under control of the FDC and DMA memory and disk data
controllers. Data transfers in DMA or non-DMA mode
There are 16 commands which the uPD765A/uPD765B Parallel seek operations on up to four drives
will execute. Most of these commands require multiple Compatible with uPD8080/85, uPD8086/88, V-series
8-bit bytes to fully specify the operation which the and uPD780 (Z80@) microprocessors
processor wishes the FDC to perform. The following
commands are available. Single-phase clock: 8 MHz maximum
Read Data Read Deleted Data 3 +5V only
Read ID Write Data Z80 is a registered trademark of the Zilog Corporation
Specify Write ID (Format Write)
Read Diagnostic Write Deleted Data Pin Configuration
Scan Equal Seek
Scan High or Equal Recalibrate
Scan Low or Equal Sense Interrupt Status
Version Sense Drive Status.
Ordering Information
Device Number Package Type Max Freq. of Operation
uPD765AC2 40-pin plastic DIP 8 MHz
uPD765B 40-pin plastic DIP 8 MHz
NECEL-000324 5-3
uPD765A/uPD765B NEC
Pin Identification RD (Read Strobe)
No. Symbol Function The RD input allows the transfer of data from the FDC
1 RESET Reset input to the data bus when low and either C Sor DACK is
2 RD Read control input asserted.
3 WR Write control input
Chip select input
WR (Write Strobe)
4 C
S
5 A0 Data or status select input TheWR input allows the transfer of data to the FDC
6-13 DB0-DB7 Bidirectional data bus from the data bus when low. Disabled when C
Sis high.
14 DRQ DMA request output
A0 (Data/Status Select)
15 DACK DMA acknowledge input
TC Terminal count input The A0 input selects the data register (A0 = 1) or status
16
register (A0=O) contents to be accessed through the
17 INDEX Index input
data bus.
18 INT Interrupt request output
19 CLK Clock input CS(Chip Select)
20 GND Ground
The FDC is selected when CS is low, enabling RD and
21 WCLK Write clock input WR.
22 WINDOW Read data window input
23 R DATA Read data input DBo-DB7 (Data Bus)
24 SYNC VCO sync output DBo-DB7 are a bidirectional 8-bit data bus. Disabled
25 W E Write enable output when CSis high.
26 MFM MFM output
27 SIDE Head select output DRQ (DMA Request)
28 29 USn US1 FDD unit select output The FDC asserts the DRQ output high to request a DMA
30 WDATA Write data output transfer.
31, 32 P S 0 PS1 Preshift output
33 FLT/TRK0 Fault/track zero input DACK (DMA Acknowledge)
34 WPRT/2SIDE Write protect/two side When the DACK input is low, a DMA cycle is active and
input the controller is performing a DMA transfer.
35 READY R e a d y input
36 HDLD Head load output TC (Terminal Count)
37 FLTR/STEP Fault reset/step output When t h e T C input is high, it indicates the termination of
38 LCT/DIR Low current direction a DMA transfer. It terminates data transfer during Read/
output Write/Scan commands in DMA or interrupt mode.
39 m/SEEK Read/write/ seek output
40 kc DC power ( +5 V) INDEX (Index)
The INDEX input goes high at the beginning of a disk
Pin Functions track.
Vcc(+5v)
+5 V power supply.
5-5
uPD765AIuPD765B NEC
Block Diagram DC Characteristics
Th= -1O’C to +70°C,Vcc
__= +5V%lO%
Limits Teal
Parameter Symbol Min Typ Max Unit Conditions
Input voltage -0.5 v
IOW
Input load 10
current high
Input load -10
current low
Output leakage 10
current high
Absolute Maximum Ratings Output leakage -10
TA = 250C current low
Power supply voltage, VCC - 0 5 to +7v
Input voltage, V1 -0.5 to +7v Capacitance
Output voltage, VO - 0 . 5 1 0 +7v
Operating temperature, TOpT - 1OOC to +7ooc Limits Test
Storage temperature, TSTG -65°C to +150°C Parameter Symbol Min Typ Max Unit Conditions
Input clock 20 pF (Note 1)
Comment: Exposing the device to stresses above those listed
in the Absolute Maximum Ratings could cause permanent
damage. The device should not be operated under conditions Input 10 pF (Note 1)
outside the limits described in the operational sections of this capacitance
specification. Exposure to absolute maximum rating condi- output 20 pF [Note 1)
COUT
tions for extended periods may affect device reliability. capacitance
Note:
(1) All pinsexcept pin under test tied to AC ground.
5-6
NEC uPD765A/uPD765B
DRQ Reset
When an overrun occurs, the uPD765A needs DACK
input to reset DRQ. If DACK is not available, an
external DMA controller continues to operate even after
the FDC enters the R-Phase (Result Phase), and stored
result status may be transferred accidentally as ordinary
data.
On the other hand, the uPD765B resets DRQ auto-
matically just before the R-Phaseentry and independent
of the DACK input. See AC Characteristics for DRQ
reset timing.
Clock Synchronization
The uPD765B does not require synchronization
between the CLK and WCLK inputs.
Version Command
The Version command distinguishes the uPD765B
from other devices. The ST0 response to the Version
command is:
Part No. ST0 Value
uPD765A 80H
uPD765B 90H
5-7
uPD765AIuPD7656
AC Characteristics
= -10 to = V
Parameter Symbol Min Typ Max Unit Conditions Parameter Symbol Min Typ Max Conditions
Clock period 120 125 500 CLK WCLK cycle time 16 MFM = 0
240 250 ns CLK 8 MFM = 1
Clock active 40 WCLK active time 250 350 ns Note 4
(high, low)
Clock rise 20 CLK WCLK 0 n s
time delay only
Clock fall 20 ns WCLK. RDATA and 20 ns
time WINDOW time
- -
DACK 0 WCLK, and 20 ns
setup time to RO WINDOW fall time
- -
CS, DACK 0 ns Preshift time 20 ns
hold time from from WCLK
width 200 WCLK 20 100 ns
delav
Data access 140 = 100
from 20 100 ns
DB to float delay 10 85 ns
time from RDATA 40 ns
- - time
CS. OACK AW 0
setup time to WR I Window cycle time 2 MFM=O
OACK 0 ns 1
hold time Window hold time 15 ns
width 200 ns from RDATA
Data setup time to 100 ns Window setup time 15 ns
to RDATA
Data hold time from 0 ns setup time 12 CLK
to SEEK Notes 4, 5
time from ns Non-DMA SEEK setup time 7
+ mode to DIR
+ 135 Direction setup time
INT delay time from to step
hold time 5.0
+ 135 from step t
cycle time 13 Step active time 6 7 8 Notes 4.5
ns (Note 4)
(high)
DACK 140 ns Step cycle time 33 Note 2Note 2
delav
Fault reset 8.0 10
DRQ DACK 200 n s time (high)
delay ns (Note 4)
Write data width
DACK width AA ns
+ 15
hold time 15 CLK
TC width 1
after seek Notes 3.4.
Reset width 14 5
DRQ INT 60 7 7 SEEK hold time 30 CLK
response time only from DIR Notes 4, 5
INT DACK 1 DIR hold time 24
ineffective after step
Index pulse 4
AC Characteristics (cont)
Parameter Symbol Min Typ (1) Max Unit Conditions
delay from DRQ 800 ns S-MHz CLK
Note 4
delay 250 ns
from DRQ
12
response time
from DRQ
Notes:
(1) Typical values for TA = 25°C and nominal supply voltage.
( 2 ) Under software controLThe range is from ms 1to 16ms at 8-Mhz
clock period, and 2 ms to 32 ms at 4-Mhz clock period.
(3) When one device is executing a SEEK operation, SENSE DRIVE
STATUS is executed on another device.
(4) Double these values for a 4-MHZ clock period
(5) Thedrivesiderating has a variance of ~5Ons from the minimum
value.
liming Waveforms
Processor Read Operation Processor Write Operation
CS, DACK
liming Waveforms (Cont) Seek Operation
0.45
s t e p
Clock (WCLK, Waveform for AC Test
Output
Overrun Operation Only)
Clock
Operation
FLJ Reset
I
Fault Reset
Write Enable
Terminal Count
I
0 or
Write Data
0
Normal 0 0 Reset
0
I
Early 0
Invalid
5-10
NEC uPD765A/uPD765B
Write Clock
No. Name Function
Table 1. Status/Data Register Addressing Data In/Out Out FDC and Into Processor
(DIO) Out Processor and Into FDC
A0 RD WR Function
0 0 1 Read main status register
0 1 0 Illegal
0 0 0 Illegal
1 0 0 Illegal II
C
1 0 1 Read from data register
1 1 0 Write into data register
5-l 1
uPD765A/uPD765B NEC
Table 3. Status Register Identification Table 3. Status Register Identification (cont)
Pin Pin
NO. Name Function NO. Name Function
Status Register 0 Status Register 1 (cont)
D7, D6 IC D7=0 and D6=0 D2 ND During execution of Read Data. Read De-
(Interrupt Code) Normal termination of command, (NT) (No Data) leted Data Write Data. Write Deleted Data
Command was completed and properly ex- or Scan command, if the FDC cannot find
ecuted the sector specified in the IDR(2)Register,
this flag is set.
D7=0 and D6=1
Abnormal termination of command, (AT) During execution of the Read ID command.
Execution of command was started but if the FDC cannot read the ID field without
was not successfully completed. an error, then this flag IS set.
D7=1 and D6=0 During execution of the Read Diagnostic
Invalid command issue, (IC) Command command. if the starting sector cannot be
which was issued was never started found, then this flag is set.
D7=1 and D6=1 D1 During execution of Write Data, Write De-
Abnormal termination because during NW(Not Writeable) leted Data or Write ID command. if the FDC
command execution the ready srgnal from detect: a write protect srgnal from the
FDD changed state F D D . t h e n this f l a g i s S e t
D65 SE When the FDC completes the Seek com- Do MA This bit is set if the FDC does not detect the
(Seek End) mand, this flag IS set lo 1 (high). (Missing Address IDAM before 2 index pulses It is also set if
If a fault srgnal IS received from the FDD, or Mark) the FDC cannot find the DAM or DDAM af-
D4 EC
if the track 0 srgnal fails to occur after 77 ter the IDAM is found. MD bit of ST2 is also
(Equipment Check)
step pulses (Recalibrate Command) then ser at this time.
this flag is set Status Register 2
D3 NR When the FDD IS in the not-ready state and D7 Not used. This bit IS alwavs 0 (low)
(Not Ready) a Read or Write command IS Issued, this De CM During execution of the Read Data or Scan
flag IS set If a Read or Write command is (Control Mark) command, if the FDC encounters a sector
issued to side 1 of a single-sided drive, which contains a deleted data address
then this flag IS set mark, this flag is set Also set if DAM is
D2 HD This flag IS used to indicate the state of the found during Read Deleted Data
(Head Address) head at interrupt. DD If the FDC detects a CRC error in the data
D5
D1 US: This flag IS used to indicate a drive unit (Data Error in field then this flag is set
(Unit Select 1) number at interrupt. Data Field)
D0 Us0 This flaa is used to Indicate a drive unit DA W C This bit IS related to the ND bit, and when
(Unit Select 0) number at interrupt (Wrong Cylinder) the contents of C(3) on the medium is dif-
ferent from that stored in the IDR. this flag
Status Register 1
is set
D7 EN When the FDC tries to access a sector be-
D3 SH During execution of the Scan command. if
(End of Cylinder) yond the final sector of a cylinder, this flag
(Scan Equal Hit) the condition of “equal” is satisfied, this
IS s e t
flag is set.
Not used. This bit is always 0 (low)
D2 SN During execution of the Scan command, if
When the FDC detects a CRC(1) error in ei- (Scan N o t S a t i s f i e d ) the F D cannot find a sector on the cylin-
DE(Data Error) ther the ID field or the data field, this flag is der which meets the condition. then Cthis
set flag is set
D4 OR If the FDC is not serviced by the host sys- D1 BC This bit is related to the ND bit. and when
(Overrun) tem during data transfers within a certain (Bad Cylinder) the contents of C on the medium is differ-
time interval. this flaa is set. ent from that stored in the IDR and the con-
D3 Not used. This bit is alwavs 0 (low). tents of C IS FFH. then this flag IS set
Do MD When data IS read from the medium, if the
(Missing Address FDC cannot find a data address mark or
Mark in Data Field) deleted data address mark, then this flag
is set
NEC uPD765A/uPD765B
5-13
uPD765A/ uPD765B
W EOT
W GPL
DTL
Data transfer between the main system and FDD
Status after command execution
ST2
C Sector ID information after command execution
H
R
R N
Write Deleted Data
Command W MT MF 0 0 1 0 1 Command codes
W X X X X X HD US,
W C Sector Information prior to The 4 bytes
W are compared against header on floppy disk
W R
- p - - - - - N -
W EOT
w GPL
w DTL
Execution Data transfer between the FDD and main system
Result Status information after command execution
ST1
ST2
C Sector ID information after command execution
H
R N
Read Diagnostic
Command w 0 MF SK 0 0 0 1 0 Command codes
W X X X X X HD
W Sector prior to command execution
W H
w R
W N
W EOT
W GPL
w DTL
Data transfer between the FDD and main system FDC reads all
data fields from index hole to EDT.
Result Status information after command execution
ST1
ST2
C Sector ID Information after command
H
5-15
Table 4. Set (Notes
instruction Code
Remarks
Read
Command W 0 MF 0 0 1 0 Command codes
W X X X X X HD US,
Executron The first correct ID on the cylinder stored data
register.
Status information after command execution
ST1
ST2
C Sector ID read during executron phase from floppy
H
N
ID
Command W MF 1 1 1 C o m m a n d codes
w X X X X X HD US,
W N Bytes/sector
W SC Sectors/track
W GPL Gap3
W byte
FDC formats an entire track.
Result Status information after command execution
ST1
ST2
C In this case, the ID has no
H
R -
R N
Scan Equal
Command W MT SK 1 0 0 0 1 Command codes
W X X X X X US,
W C Sector command execution
W H
w
W
W EOT
w GPL
W STQ
Execution Data between the and main
Result Status after command execution
ST1
ST2
C Sector ID information after command
H
fl
N
Note:
(1) Symbols used this table are described at the end of this section
should equal 1 for all operations.
(3) X Don’t care, usually made to equal 0.
5-16
Table 4. Instruction Set (Notes
code
Phase Remarks
Scan or
Command MT MF SK 1 1 0 0 1 Command codes
X X X X X HD US,
C Sector ID to command
H
N
EOT
GPL
STP
Data comoared between the FDD and
Result Status after command execution
ST1
ST2
C Sector ID Information after command
R -
R N
Scan High Equal
Command W MT MF SK 1 1 1 0 Command codes
w X X X X X US,
w C Sector ID information prior to command execution
w
W
W N
W EDT
W GPL
w STP
Execution Data compared between the FDD and system
Result Status Information after command
ST1
ST2
C Sector ID information after command
H
R -
R
5-17
Table 4. Instruction Set (Notes I,
Version
Command w x x x 1 0 0 0 0 Command codes
Indicates 7658
indicates
Seek
Command W 0 0 0 0 1 1 1 1 Command c o d e
W X X X X X HD US,
W NCN
Execution Head IS positioned over proper cylinder on diskette
Invalid
Command W Codes Invalid Command codes (No op- goes state)
Note:
(1) Symbols used in this table are described at the end of this section.
(2) should equal 1 for all operations.
(3) Don’t care, usually made to equal 0.
System Configuration
Figure 2 shows an example of a system using a
5-18
Data Format
[MFM Mode]