Radice Shaek Service |Manual TRS-8O° COLOR COMPUTER DISK INTERFACE Catalog Number 26-3022 CUSTOM MANUFACTURED IN U.S.A. BY RADIO SHACK BAA DIVISION OF TANDY CORPORATION SYSTEM DESCRIPTION The TRS-80 Color Computer Disk Interface utilizes the WD1793 disk controller chip’ to provide a double density interface for mini-floppy disk drives. This interface will support up to’ four drives with 35 tracks per drive. The Interface also contains an 8K x 8 ROM which contains the assembly code for Disk Basic. Figure 1 is a block diagram of the Disk Interface. The 8K x 8 ROM is connected directly to the processor address and data busses and is located at hex C000. An 8-bit register is also connected to the data bus. This register allows the processor to have command over eight disk interface control signals. Logic is also provided for clock generation, device selection, and processor halt/restart operation. To fully understand the operation of the Color Computer Disk Interface it is necessary to refer to the data sheets for. the WD1791, the WD1691, and the WD2143. The part numbers to’ use when ordering these data sheets are found in the Parts Lists in the back of this manual. INTERRUPT AND WAIT Peal LOGIC CLOCK CIRCUITRY NMI | MHZ B8KX8 ; CONTROL —_ Y >, REGISTER SIGNALS ROM OUT OUTPUT DATA BUS BUFFER PLL DISK CONTROLLER COMPUTER > nS INTERFACE } PRE - COMPENSATION nYCw VN bacpscemmenramen DEVICE DISK SELECTION INTERFACE AND CLOCK GENERATION FIGURE 1. BLOCK DIAGRAM DISASSEMBLY Carefully peel back the product label to expose the screw positioned in the middle of the case top and remove this screw. Gently pry the case loose at the ends with a small screwdriver. Remove the two screws fastening the PC board to the case bottom and remove the RF shield from the board by carefully prying off the tri-mount fasteners. ASSEMBLY Reconnect the RF shield to the PC board so that the shiny side of the shield is away from the board. Be sure that the corner edges are folded under the shield and the fasteners are at the P2 end of the board. The flat end of the fasteners should be on the shield side of the board. Place the PC board in the case bottom and install the two 1/4" screws. Match up the hole in the middle of the case top with the plastic boss in the case bottom and snap the case together. Replace the 1/2" screw in the case top and carefully press down the product label. THEORY OF OPERATION Clock Generation The master clock frequency used on the Disk Interface board is 4 MHz. The clock circuit uses a series resonant 4 MHz crystal, Yl, and two gates from a 74LS04 hex inverter, U6. Appropriate resistor and Capacitor values are added to produce a 4 MHz oscillator circuit. A third inverter gate is used to buffer the clock before it is fed into a 74LS74 chip, Ul. This IC is used as a divide-by-4 counter to yield a 1 MHz clock used by the WD1793. Computer Interface The disk interface to the processor is composed of four parts: an 8K x 8 ROM, a control register, the WD1793, and the halt-interrupt logic. The 8K x 8 ROM simply adds the disk I/O commands to Extended Color BASIC. The control register allows the processor’ to enable double density and precompensation, select and start one of four drives, and enable or disable the wait logic. The function of each bit of the control register is shown in the Disk Memory Map, Figure 2. The WD1793 contains four registers which may be accessed by _ the processor. These are the status/command register, the track register, the sector register, and the data register. The status register keeps track of any error which has occurred and tells’ the WD1793 what operation to perform. The track register keeps a record of the current track and is automatically incremented or decremented by the WD1793. The sector register should be loaded with the desired sector during a read or write operation. The data register is used during any read or write operation for transfer of data between the processor and the disk drive. For a detailed description of these registers, please consult the WD1793 data sheet. HEX ADDRESS DISK CONTROLLER USAGE BIT 0 DRIVE SELECT 1 BIT 1 = DRIVE SELECT 2 BIT 2 = DRIVE SELECT 3 BIT 3 = MOTOR ON FF 40 BIT 4 = START PRECOMPENSATION BIT 5 = DOUBLE DENSITY ENABLE BIT 6 = DRIVE SELECT 4 BIT 7 = WAIT ENABLE FF 48 1793 STATUS/COMMAND REGISTER FF 49 1793 TRACK REGISTER FF4A 1793 SECTOR REGISTER FF 4B 1793 DATA REGISTER FIGURE 2. COLOR DISK INTERFACE MEMORY MAP To allow the CPU to keep up with the double density interface, the data request line from the WD1793 is gated with halt enable from the control register. The resulting signal is used to control the processor halt input. The interrupt request from the WD1793 is gated with the double density enable signal from the control register and this line is used to generate a non-maskable interrupt to the CPU. With the HALT/NMI logic, a disk read operation will operate as follows. First the CPU loads the FDC command register with the desired read operation. Next, the double density enable and halt enable control bits, D5 and D7, are set. The CPU is then immediately halted until the data register contains the first byte of data. When this data is received, the data request line of the WD1793 goes high removing the CPU from the halt state. The CPU then loads the byte of data from the WD1793 and _ stores it in memory. After the WD1793 data register has been accessed, the data request line goes low and the CPU is again halted. This halt and load process continues until the WD1793 generates an interrupt to indicate that the read command has been completed. This interrupt clears the halt enable control bit, D7, and breaks the CPU out of the tight read and store loop. A write operation is similar with the exception that the halt occurs after a data byte has been loaded into the data register. Disk Communication The major read, write, and step functions of the disk interface are performed by the WD1793. This chip will provide every major disk interface function for a single density interface with the exception of deriving a clock from the incoming data stream. However, for a double density interface, three support chips are required. These three chips are U12, a WD1691; Ul14, a WD2143; and Ull, a 74LS629. The WD2143 is a four phase clock generator chip. The 74LS629 is a voltage controlled oscillator chip. The WD169l ties these chips together to provide precompensation and phase-locked clock generation for the double density interface. Precompensation is used in the double density interface for tracks greater than 21. When precompenstion is needed, the FD1793_ sets either the EARLY or LATE signal high. This information is used by the WD169l1 to select one of three clock phases from the WD2143. (The fourth phase is used to reset the strobe input to the clock chip.) The second phase of the clock is used for EARLY and phase three is used for LATE. A timing diagram of this sequence is shown in the WD1691 data sheet. To read the incoming data from the disk, the WD1793 requires a_ clock which is synchronized with the data. This function is achieved by a phase lock loop. The 74LS629 provides a_ stable voltage controlled oscillator and is adjusted to free-run at 2 MHz. This 2 MHz _ signal is divided by 8 in the WD1691 phase comparator for a_ frequency of 0.25 MHz, roughly equal to the incoming clock from the _ disk. However, the phase comparator controls the voltage input to the 'LS629 to force the clock to exactly match the incoming data stream. For a more detailed description of the phase lock loop, please refer to the WD169l data sheet. Drive Interface The remaining circuitry of the Disk Interface is used to condition Signals connected to the drive. All of the output’ signals are buffered by a 7416 gate, U3, an open-collector inverter. The input Signals are terminated by three 150 ohm pull-up resistors, R14, R3, and R2. The read and write data signals are pulse-width adjusted with the write signal set at 450 ns, and the read signal set at 200 ns. ADJUSTMENTS The disk interface has three potentiometers which require adjustment: R15, R8, and R16. To adjust R15 and R8, the’ interface should be in the idle condition (no command currently in operation). Adjust R15 for a1.4V level on pin 2 of Ull. Adjust R8 to provide a 2 MHz square wave at pin 16 of U12. R16 controls the amount of write precompensation and must_ be adjusted while executing a continuous write command. This potentiometer should be adjusted to yield pulses 200 ns_ wide at pin 4 of U12. SYMBOL Cl C2 C3 C4 C5 C6 C7 C8 C9 C10 Cll Cl2 C13 C14 C15 C16 Cl7 C18 C19 C20 C21 C22 C23 C24 OF a0 C26 Car C28 C29 Y1 Ul U2 U3 U4 U5 U6 U7 U8 U9 U10 U1ll U12 U13 U14 COLOR COMPUTER DISK INTERFACE PARTS LIST MAN DESCRIPSTION PART NO. Capacitors 180pF, 50V, ceramic 8301184 180pF, 50V, ceramic 8301184 O.luF, 50V, mono. axial 8374104 0.022uF, 50V, cramic 8303224 O.luF, 50V, mono. axial 8374104 0.022uF, 50V, ceramic 8303224 470pF, 50V, ceramic 8301474 1OOpF, 50V, ceramic 8301104 180pF, 50V, ceramic 8301184 O.luF, 50V, mono. radial 8384104 lOOpF, 50V, ceramic 8301104 Of.luF, 50V, mono. axial 8374104 0.022uF, 50V, ceramic 8303224 62pF, 50V, ceramic 8300603 180pF, 50V, ceramic 8301184 0.022uF, 50V, ceramic 8303224 0.47uF, 100V, polyester 8354475 0.022uF, 50V, ceramic 8303224 10uF, 16V, elect. axial 8316101 0.022uF, 50V, ceramic 8303224 1OOpF, 50V, ceramic 8301104 l0OuF, 16V, elect. axial 8316101 0.022uF, 50V, ceramic 8303224 0.022uF, 50V, ceramic 8303224 O.luF, 50V, mono. axial 8374104 0.022uF, 50V, ceramic 8303224 O.luF, 50V, mono. axial 8374104 0.022uF, 50V, ceramic 8303224 470pF, 50V, ceramic 8301474 Crystal 4 MHz, series resonant 8409010 Integrated Circuits 74LS74, dual D flip-flop 8020074 7416, hex inverter 8000016 7416, hex inverter 8000016 74LS00, quad 2-in NAND 8020000 74LS04, hex inverter 8020004 74LS04, hex inverter 8020004 74LS221, dual one-shot 8020221 MCM14174B, hex D flip-flop 8030174 74LS02, quad 2-in NOR 8020002 MC14013B, D flip-flop 8030013 74LS629, dual VCO 8020629 WD1691, floppy support logic 8040691 WD1793B, floppy formatter 8030793 WD2143-01, four-phase clock 8040143 R.S. PART NO. ACC1LO4QJCA ACC 223QJCP ACCO14QJCA ACC 223QUJCP ACC471QJCP ACC1O1LQJCP ACC10O04QJAP ACC10O1QJCP ACC104QJCA ACC 223QUJCP ACC 223QJCP ACC101QJCP ACC 223QUJCP ACC 223QJCP ACC1O4QJCA ACC 223QUJCP ACC1O4QJCA ACC 223QJCP ACC 471QJCP AMX 280 4 AMX 3558 AMX 4228 AMX 4228 AMX 3550 AMX 3552 AMX 3552 AMX 3810 AMX 4663 AMX 4471 AXX 3041 AMX 4472 UL5 R1 150 ohm, 1/4W, 5% R2 150 ohm, 1/4W, 53% R3 150 ohm, 1/4W, 5% R4 1.5K, 1/4W, 5% R5 6.8K, 1/4W, 5% R6 910 ohm, 1/4W, 53% R7 910 ohm, 1/4W, 5% R8 50K, trim pot RQ 47K, 1/4W, 5% R10 10K, 1/4W, 5% Rll 47K, 1/4W, 5% R12 10K, 1/4W, 53% R13 47 ohm, 1/4W, 5% R14 150 ohm, 1/4W, 5% R15 100K, trim pot R16 1K, trim pot R17 750 ohm, 1/4W, 5% R18 3.9K, 1/4W, 5% R19 220 ohm, 1/4W, 53% R20 220 ohm, 1/4W, 53% MISCELLANEOUS Description Quantity Data Sheet, WD1691 Data Sheet, WD179X-02 Data Sheet, WD2143 Socket, 14-pin DIP 8 Socket, 16-pin DIP 3 Socket, 18-pin DIP 1 Socket, 20-pin DIP 1 Socket, 24-pin DIP 1 Socket, 40-pin DIP 1 Case Top 1 Case Bottom 1 Cable, ext. disk interface 1 Fastener, tri-mount 2 Label, cartridge ID 1 Shield, RFI 1 Screw, #6-19 x 1/2", PFH 1 Screw, #6-19 x 1/4", PPH 2 MCM68A364, 64K ROM Resistors 8045364 8207115 8207115 8207115 8207215 8207268 8207191 8207191 8279350 8207347 8207310 8207347 8207310 8207047 8207115 8279410 9279210 8207175 8207239 8207122 8207122 Man. Part No. 8509008 8509003 8509006 8509009 8509001 8509002 8719149 8719150 8709205 8559033 8789494 8729079 8569111 8569077 AMX 4895 ANO142EEC AN0142EEC AN0O142EEC AN0206EEC AN0262 EEC AN0192EEC AN0192EEC AP 7168 AN0340 EEC AN0281 EEC AN0340 EEC AN0281EEC AP0835 AN0185 EEC AN0237EEC R.S. Part No. MS-2601061H MS -2601061J MS-2601061L AJ6581 AJ6701 AJ 6760 AJ6579 AJ 6580 —= ae ees oom ~ v vores ang =< 26 - . Ov R > i 1? alle ES wie Ova ve = 4 : Ga 2 « © ais Ny , 2259 SSA i> 1. 2iv9 Sun am re) a ny A 1I7GS LENO on pore NO WOW un ' 4 oy] '9 ey fc v mn Ge — ee a a = _ ww oF 4 z p<] rb] wor ww PC ” >) Jl a RDA 12 ul (3-1) \3 j! 130 | IRDA 7438 oi 29] IRDA RET ui S 0 4 2e | weT viz 7438 q ~ 5 6 \ 5 27] IWPT RET 7406 1 Ul o Tl] 2s LINXP ‘ 7438 R48 LP) Hine RET APSEN (2-1) 2.15K o 1% y cre SEL : RI7 (2-8) P2 | J2 1.5K U4 c NO [> FS peer Reommt) >|? > 74LS04 BRN/AWHT ig | 19 NSEL WRITE PROTECT D +5V (2-8) (3-8) R9 150 +5V REO/YEL | | | , BAN/YEL| , | 2 Sais > 22k S$RI2 -TP2 } an r i > |X t 14 RIO — * BLK/YEL . 9], 17 117 _ + 339 ORNZYEL is | 16 Re ; INDEX/SECTOR ; 2 8 2x Rie TRANSDUCER < VN L 6ex () D ar aw, NONE | 00 Nor scae owe [SHEET 4g 8 | 7 | 6 | 6 | 4 | 3 | 2 | 1 CADDS 1/82 RADIO SHACK eG DIVISION OF TANDY CORPORATION U.S.A.: FORT WORTH, TEXAS 76102 CANADA: BARRIE, ONTARIO L4M 4W5 TANDY CORPORATION AUSTRALIA BELGIUM U.K. 280-316 VICTORIA ROAD PARC INDUSTRIEL DE NANINNE BILSTON ROAD WEDNESBURY RYDALMERE, N.S.W. 2116 5140 NANINNE WEST MIDLANDS WS10 7JN Printed in U.S.A.