home *** CD-ROM | disk | FTP | other *** search
/ ftp.pasteur.org/FAQ/ / ftp-pasteur-org-FAQ.zip / FAQ / pc-hardware-faq / part2 < prev    next >
Text File  |  1998-03-23  |  68KB  |  1,434 lines

  1. Path: senator-bedfellow.mit.edu!bloom-beacon.mit.edu!news.kodak.com!news-pen-14.sprintlink.net!206.229.87.26!news-east.sprintlink.net!news-peer.sprintlink.net!news.sprintlink.net!Sprint!cpk-news-hub1.bbnplanet.com!cam-news-hub1.bbnplanet.com!news.bbnplanet.com!nntprelay.mathworks.com!bigboote.WPI.EDU!worcester.com!not-for-mail
  2. From: ralf@alum.wpi.edu (Ralph Valentino)
  3. Newsgroups: comp.sys.ibm.pc.hardware.video,comp.sys.ibm.pc.hardware.comm,comp.sys.ibm.pc.hardware.storage,comp.sys.ibm.pc.hardware.cd-rom,comp.sys.ibm.pc.hardware.systems,comp.sys.ibm.pc.hardware.networking,comp.sys.ibm.pc.hardware.chips,comp.sys.ibm.pc.hardware.misc,comp.answers,news.answers
  4. Subject: comp.sys.ibm.pc.hardware.* Frequently Asked Questions (FAQ) Part 2/5
  5. Followup-To: comp.sys.ibm.pc.hardware.misc
  6. Date: 22 Mar 1998 19:29:52 -0500
  7. Organization: Worcester Wares
  8. Lines: 1411
  9. Sender: ralf@worcester.com
  10. Approved: news-answers-request@MIT.EDU
  11. Distribution: world
  12. Expires: 30 Apr 1998 00:00:00 GMT
  13. Message-ID: <6f4ae0$7l4@ftp.worcester.com>
  14. Reply-To: ralf@alum.wpi.edu
  15. NNTP-Posting-Host: ftp.worcester.com
  16. Summary: This is a monthly posting containing a list of Frequently
  17.      Asked Questions (and their answers) pertaining to hardware
  18.      and IBM PC clones.  It should be read by anyone who wishes
  19.      to post to any group in the comp.sys.ibm.pc.hardware.*
  20.      hierarchy.
  21. Xref: senator-bedfellow.mit.edu comp.sys.ibm.pc.hardware.video:243869 comp.sys.ibm.pc.hardware.comm:30678 comp.sys.ibm.pc.hardware.storage:138005 comp.sys.ibm.pc.hardware.cd-rom:62014 comp.sys.ibm.pc.hardware.systems:67678 comp.sys.ibm.pc.hardware.networking:22479 comp.sys.ibm.pc.hardware.chips:213391 comp.sys.ibm.pc.hardware.misc:114203 comp.answers:30579 news.answers:126109
  22.  
  23. Archive-name: pc-hardware-faq/part2
  24. Last-modified: 1997/11/10
  25. Version: 1.25
  26.  
  27. S) 3.0 IO controllers/interfaces
  28.  
  29. Q) 3.1  *How do IDE/MFM/RLL/ESDI/SCSI interfaces work?
  30.  
  31. Q) 3.2  How can I tell if I have MFM/RLL/ESDI/IDE/SCSI?
  32.  
  33. [From: ralf@wpi.edu (Ralph Valentino)]
  34.  
  35. The most reliable way to tell what type of drive you have is to call
  36. the manufacturer with the model number and ask.  There is an extensive
  37. list of phone numbers in the References section of the FAQ. 
  38.  
  39. That aside, the first thing to check is the number of pins on the
  40. drive's connector(s).  The second thing to check is the CMOS setup,
  41. assuming, of course, that it is in a working system.
  42.  
  43. SCSI = 1 cable: 50 pins (note 1,2)
  44.   usually set up as "not installed" in the CMOS
  45. IDE  = 1 cable: 40 pins
  46.   no reliable way to tell from the CMOS
  47. RLL  = 2 cables: 34 pins & 20 pins
  48.   always has 26 sectors per track
  49. MFM  = 2 cables: 34 pins & 20 pins
  50.   always has 17 sectors per track (note 3)
  51. ESDI = 2 cables: 34 pins & 20 pins (note 4)
  52.   usually set up as type #1 in the CMOS and auto-configured at boot time
  53.  
  54. If you've narrowed it down to RLL/MFM or ESDI but it isn't in a
  55. working system, there's no easy way to narrow it down any further just
  56. by looking at the drive.
  57.  
  58. note 1: The QIC-2 tape drive interface also has 50 pins
  59. note 2: To differentiate single ended and differential SCSI, see the scsi-faq
  60. note 3: Some people attempt to set up MFM drives as RLL with varying success,
  61.         this method will only tell you what it is set up as.
  62. note 4: While ESDI uses the same type of cables as RLL and MFM, the
  63.         signals are very different - do not connect ESDI to RLL or MFM!
  64.  
  65.  
  66. Q) 3.3  Do caching controllers really help?
  67. [From: backbone!wayne@tower.tssi.com (Wayne Schlitt)]
  68.  
  69. The short answer, is that if you are using a multi-tasking
  70. operating system with a good memory manager, caching controllers
  71. should be ignored.  If you are running DOS or Windows, then *maybe*
  72. they will help, but I am not sure that they are a good buy.  
  73.  
  74. There are lots of people who have said "I put a caching controller in
  75. my computer, and it runs faster!".  This is probably true, but they
  76. never have measured the speed increase compared to putting the same
  77. memory into main memory instead.  More importantly, the caching
  78. controllers cost more money than non caching controllers, so you
  79. should be able to add _more_ main memory instead of buying a caching
  80. controller.
  81.  
  82. The following is a shortened up version of a much longer article.  If
  83. you want a copy of the longer article, send me email at
  84. "wayne@cse.unl.edu".
  85.  
  86. *** Why a multi-tasking operating system?
  87.  
  88. A multi-tasking operating system can allow the application to continue
  89. immediately after it does a write, and the actual disk write can
  90. happen later.  This is known as write behind.  The operating system
  91. can also read several blocks from the file when the application
  92. requests just part of the first block.  This is known as read ahead.
  93. When the application requests the block later on, the block will
  94. already be there and the OS can then schedule some more reads.
  95.  
  96. A multitasking operating system is required because these operations
  97. can cause interrupts and processing when control has been given back to
  98. the application.  
  99.  
  100. Basically, operating systems such as DOS, MS-Windows, MacOS and such
  101. do not allow true preemptive multitasking and can not do the read a
  102. heads and the write behinds.  For these systems, the latency of a disk
  103. drive is the most important thing.  The application does not regain
  104. control until the read or write has finished. 
  105.  
  106. *** The controller can't speed up the disk.
  107.  
  108. Remember, the bottleneck is at the disk.  Nothing that the controller
  109. can do can make the data come off the platters any faster.  All but the
  110. oldest and slowest controllers can keep up with all but the newest and
  111. fastest disks.  The SCSI bus is designed to be able to keep *several*
  112. disks busy without slowing things down.
  113.  
  114. Speeding up parts of the system that are not the bottleneck won't help
  115. much.  The goal has to be to reduce the number of real disk accesses.
  116.  
  117. *** First, isn't the caching controller hardware and isn't hardware
  118. *** always faster than software?
  119.  
  120. Well, yes there is a piece of physical hardware that is called the
  121. caching controller, but no, the cache is not really "in hardware".
  122. Managing a disk is a fairly complicated task, complicated enough that
  123. you really can't implement the controller in combinatorial logic. 
  124.  
  125. So, just about all disk controllers and for that matter all disk
  126. drives have a general purpose computer on them.  They run a little
  127. software program that manages the communication between the main cpu
  128. and the disk bus, or the disk bus and the disk.  Often this cpu is put
  129. in with a bunch of other logic as part of a standard cell custom chip,
  130. so you might not see a chip that says "Z80" or such.
  131.  
  132. So, we are really not comparing "hardware" with "software", we are
  133. comparing "software on the controller" with "software on the main
  134. cpu".
  135.  
  136. *** Ok, why can the OS win?
  137.  
  138. Assume that you have a bunch of memory that you can either put into
  139. main memory and have the OS manage the cache, or put on a caching
  140. controller.  Which one will be better?  Let us look at the various
  141. cases. 
  142.  
  143. For a cache hit you have:
  144.  
  145. If the OS does the caching, you just have the OS's cache checking
  146. latency.
  147.  
  148. If the card does the caching, you will have the OS's cache checking
  149. latency, plus the I/O setup time, plus the controller's cache checking
  150. latency, plus you have to move the data from the card to main memory.
  151. If the controller does DMA, it will be taking away from the memory
  152. bandwidth that the main CPU needs.  If the controller doesn't have
  153. DMA, then the main CPU will have to do all the transfers, one word at
  154. a time.
  155.  
  156. For a cache miss, you have:
  157.  
  158. If the OS does the caching, you have the OS's cache checking latency
  159. plus the set up time for the disk I/O, plus the time it takes for the
  160. disk to transfer the data (this will be a majority of the time), plus the
  161. cost of doing either the DMA or having the CPU move the data into main
  162. memory. 
  163.  
  164. The caching controller will have all of the above times, plus it's own
  165. cache checking latency.
  166.  
  167. As you can see, the caching controller adds a lot of overhead no
  168. matter what.  This overhead can only be offset when you get a cache
  169. hit, but since you have the same amount of memory on the controller
  170. and the main cpu, you should have the same number of cache hits in
  171. either case.  Therefore, the caching controller will always give more
  172. overhead than an OS managed cache.
  173.  
  174. *** Yeah, but there is this processor on the controller doing the
  175. *** cache checks, so you really have a multi-processor system.
  176. *** Shouldn't this be faster than a single processor?  Doesn't this
  177. *** allow the main cpu to do other things while the controller manages
  178. *** the cache?
  179.  
  180. Yes, this really is a multi-processor system, but multi-processors are
  181. not always faster than uni-processors.  In particular, multi-processor
  182. systems have communication overhead.  In this case, you are
  183. communicating with the controller using a protocol that is fairly
  184. expensive, with outb instructions and interrupts and such.  The
  185. overhead of communicating with this other processor is greater than
  186. the overhead of just checking the cache on main cpu, even if the main
  187. cpu is very slow.  
  188.  
  189. The multi-processor aspect just doesn't help out when you are talking
  190. about managing a cache.  There is just too much communication overhead
  191. and too little processing for it to be a win.
  192.  
  193. *** Ok, but couldn't the caching controller do a better job of
  194. *** managing the cache?
  195.  
  196. Both the controller and the OS are going to be executing a piece of
  197. software, so in theory there isn't anything that the slower cpu on the
  198. controller can do that the OS can't do, but the OS can do things that
  199. the controller can't do.
  200.  
  201. Here are some of the things that the OS can do better:
  202.  
  203. * When you read a block from a file, the OS can read several more
  204.   blocks ahead of time.  Caching controllers often will read an entire
  205.   track in order to simulate this file read a head, but the rest of
  206.   the file isn't always on the same track, only the OS knows where the
  207.   blocks are really going to be at.  This can lead to wasted time and
  208.   cache memory reading data that will never be used.
  209.  
  210. * In order to improve file system reliability, some writes _must_
  211.   complete immediately, and _must_ complete in the order that they are
  212.   given.  Otherwise, the file system structures may not be left in a
  213.   coherent state if the system crashes.
  214.  
  215.   Other writes can be completed as time is available, and can be done
  216.   in any order.  The operating system knows the difference between
  217.   these cases and can do the writes appropriately.
  218.  
  219.   Caching controllers, on the other hand, don't know if the write that
  220.   it was just given _must_ be written right away, or if it can wait a
  221.   little bit.  If it waits when it shouldn't, you are risking your
  222.   file system and data.  
  223.  
  224. * Sometimes, you want a large disk cache if you are accessing lots of
  225.   data off the disk.  At other times, you want a small disk cache and
  226.   more memory left to programs.  The operating system can balance
  227.   these needs dynamically and adjust the amount of disk cache
  228.   automatically.
  229.  
  230.   If you put the memory on a caching controller, then that memory can
  231.   _only_ be used for disk caches, and you can _never_ use more.
  232.   Chances are, you will either have too much or too little memory
  233.   dedicated to the cache at any give time. 
  234.  
  235. * When a process closes a file, the operating system knows that the
  236.   blocks associated with that file are not as likely to to be used
  237.   again as those blocks associated with files that are still open.
  238.   Only the operating system is going to know when files are closed,
  239.   the controller won't.  Similar things happen with processes.
  240.  
  241. * In the area of Virtual Memory, the OS does an extremely better job
  242.   of managing things.  When a program accesses a piece of memory, the
  243.   CPU will do a hardware level check to see if the page is in memory.
  244.   If the page is in memory, then there will basically be no delay.  It
  245.   is only when the page isn't in memory that the OS gets involved.
  246.  
  247.   Even if all of those extra pages are sitting in the
  248.   caching controller's memory, they still have to be moved to main
  249.   memory with all the overhead that that involves.
  250.  
  251.   This is why dynamic caches vs program memory is so important.
  252.  
  253. *** What is the "Memory Hierarchy" and how does this relate to
  254. *** caching controllers?
  255.  
  256. The basic idea of a memory hierarchy is to layer various types of
  257. memory, so that the fastest memory is closest to the cpu.  Faster
  258. memory is more expensive, so you can't use only the fastest type and
  259. still be cheap.  If a piece of data isn't in the highest (fastest)
  260. level of the hierarchy, then you have to check the next level down.
  261.  
  262. In order for a memory hierarchy to work well, you need to make sure
  263. that the each level of the hierarchy has much more storage then the
  264. level above it, otherwise you wont have a high hit rate.
  265.  
  266. The hierarchy on a 486 goes something like this:
  267.  
  268. 8 regs << 8k on chip cache << 256k off chip cache << main memory << disk
  269.  
  270. If you are going to put something between main memory and disk, it
  271. needs to be much larger than main memory in order for it to be
  272. effective. 
  273.  
  274. *** What about all these neat things that a caching controller can do
  275. *** such as elevator seeking, overlapping seeks with reads and writes,
  276. *** scatter/gather, etc...
  277.  
  278. These are nice features, but they are all done by either the OS or a
  279. good SCSI controller anyway.  None of these things are at all related
  280. to supporting the cache, so you shouldn't buy a caching controller for
  281. just these features.
  282.  
  283. *** Ok, you have talked about things like Unix, OS/2 and Windows NT,
  284. *** but what about DOS and MS-Windows?
  285.  
  286. Well, here things get a lot grayer.  First, older versions of DOS have
  287. notoriously bad disk cache programs.  Since neither DOS nor MS-Windows
  288. are preemptive multi-tasking systems, it is much harder to do read
  289. ahead.  Also, since DOS/MS-Windows users are used to being able to
  290. power off their computers at any time, doing write behind is much more
  291. dangerous.  DOS and MS-Windows also can crash much easier than these
  292. other OS's, so people might reboot for many reasons.
  293.  
  294. Caching controllers usually leave the hard disk light on when they
  295. have data that hasn't been written out, and people don't usually power
  296. their computer off until that light goes out.  This lets the
  297. controllers do write behind fairly safely.  (But you can still loose
  298. power, so this isn't risk free.)  They also do crude read a heads by
  299. prereading entire tracks.
  300.  
  301. DOS also runs in real mode and real mode can only access 640K of
  302. memory.  This mean that a disk cache can be real helpful.
  303. Unfortunately, to do a software based disk cache, the cpu has to be
  304. switched into protected mode in order to access memory beyond the 640K
  305. boundary and then you have to switch back into real mode.  Intel,
  306. however forgot to make it easy to switch back to real mode.   All in
  307. all, this switching back and forth ends up being real expensive.  This
  308. _might_ be more expensive than just using a caching controller, I
  309. don't know.
  310.  
  311. So, it is possible that if you configure DOS to not use a cache, and
  312. get a caching controller, then you might be a head.  I really don't
  313. know much about this area.  I have not done any real timings of this.
  314.  
  315. *** So, when would you ever want to buy a caching controller?
  316.  
  317. The answer is not too often, but there are a few cases that I can
  318. think of:
  319.  
  320. * You have filled up all your SIMM slots on your motherboard and in
  321.   order to add more memory you would have to throw some out.  This is
  322.   a real shaky reason.  You can always sell your old memory, or move
  323.   it to another computer.  The jump from 4 1MB SIMMs to 4 4MB SIMMs is
  324.   large, but you will be much better off in the long run with more
  325.   main memory.
  326.  
  327. * You have maxed out your memory and you need it all for programs and
  328.   data.  If you can't put any more memory on the mother board, then
  329.   you don't have many choices.
  330.  
  331. * If you have a bunch of slow (100ns-120ns) memory left over from say
  332.   a 286 or something and you can't use it on your motherboard because
  333.   it is too slow, then maybe adding it to a caching controller
  334.   will help.  Be careful however, if your hit rates on the caching
  335.   controller are too low, then you may be just adding overhead without
  336.   getting any benefits.
  337.  
  338. * If you are stuck with a bad OS because that's what your applications
  339.   run on, then you might be better off with a caching controller.
  340.  
  341. *** What about those disk drives that come with caches, are they bad too?
  342.  
  343. Don't confuse caching disk controllers with cache on disk drives.  The
  344. latter is actually useful.  The little cpu on the disk drive has to
  345. read every byte that comes off the disk in order to see when the
  346. sector that you are interested in has come under the heads and to do
  347. any error detection and correction.  The disk also has to have buffers
  348. in case the bus is busy, and to sync up the speeds of the bus and the
  349. heads.
  350.  
  351. Since all this data is going though the cpu on disk drive and you have
  352. to have a buffer anyway, just making the buffer larger and saving the
  353. entire track is an easy win.  Saving a couple of the most frequent
  354. tracks is also a win.
  355.  
  356. Most of these caches on the disk drives are fairly small (64k-256k),
  357. and a single memory chip will give you about that amount of memory
  358. anyway, so you aren't wasting many resources.  This also allows the OS
  359. to always assume that interleaving is not necessary to get full disk
  360. throughput, even if it does a fair amount of processing between disk
  361. requests. 
  362.  
  363.  
  364. Q) 3.4  Do IDE controllers use DMA?
  365.  
  366. No, they do not.  This is a rumor that keeps popping up.  This may
  367. change on the next revision of the standard.
  368.  
  369. Q) 3.5  Why won't my two IDE drives work together?
  370.  
  371. [From: jruchak@mtmis1.mis.semi.harris.com (John Anthony Ruchak)]
  372.  
  373. Assuming that the drives are attached to the same controller and they
  374. work properly when attached one-at-a-time, you probably don't have
  375. them configured properly for Master/Slave operation.
  376.  
  377. When operating 2 IDE drives, one must be designated as "Master" and
  378. the other as "Slave."  There are jumpers on every IDE drive to
  379. configure this.  Check your hard drive manuals for the jumper settings
  380. for your drives.  In general, it doesn't matter which is which - just
  381. pick one as master, and make the other slave.
  382.  
  383. In your CMOS configuration, Drive 1 should have the parameters (heads,
  384. cylinders, etc.) that match the drive you set as "Master" and Drive
  385. 2's parameters should match those of the "slave" drive.  In operation,
  386. the Master will appear as drive C: and the slave as drive D:.
  387.  
  388. Because not all hard drive manufacturers follow the IDE specifications
  389. closely enough, drives from 2 different manufacturers may not work well
  390. together.  In this case, changing master -> slave and slave -> master
  391. (along with the appropriate CMOS changes) may help.  If it doesn't,
  392. then trying two drives from the SAME manufacturer is the only avenue
  393. you have left.
  394.  
  395. Q) 3.6  Which is better, VLB or ISA IDE?
  396. [From: pieterh@sci.kun.nl]
  397.  
  398. If a simple answer is what you want, then yes, in general VLB IDE
  399. controllers are better than ISA ones.  If you are purchasing or
  400. putting together a computer, the relatively small price difference
  401. makes the choice for a VLB controller a sensible one.
  402.  
  403. However, if you already have an ISA controller and are wondering
  404. whether it's worth upgrading to VLB, it's not that easy.  VLB may be
  405. faster in principle, the question is if you're going to notice it.
  406.  
  407.  
  408.  *** The Bottlenecks
  409.  
  410. Let's take a look at what the limiting factors are in the path the
  411. data travels from your drive platter to the CPU.
  412.  
  413. 1. Raw data transfer from the drive platter.  To find out what this
  414.    rate is, you need the spec sheet for your drive.  Remember that
  415.    it is dependent on the cylinder, so a single drive can give
  416.    different results depending on where on the drive you're testing.
  417.    
  418.    Anyway, this transfer rate is 1 to 2 MB/s on most IDE drives,
  419.    depending on data density and rotational speed.
  420.  
  421. 2. The data has to be digested by the drive's onboard controller,
  422.    which not only mediates between the drive hardware and the IDE
  423.    bus, but also manages the buffer cache.  Let's hope it's both
  424.    fast and intelligent (not always the case *sigh*).
  425.    
  426. 3. Data transfer over the IDE/ATA bus (2-3MB/s with standard
  427.    timing).  The actual speed depends on the timing used; some
  428.    drives and controllers support faster timing.  Enhanced IDE
  429.    (IDE-2) can transfer up to 11 MB/s.
  430.  
  431. 4. Transfer from the interface to the CPU (ISA: max 5 Mb/s, VLB:
  432.    10-80 MB/s depending on CPU clock, wait states, interface...)
  433.  
  434. A generic IDE interface is usually not able to get the most out
  435. of the ISA and IDE bandwidths (3 and 4); a typical upper limit is
  436. about 2 MB/s if you use block transfers (see below), 2.5 MB/s if
  437. you're willing to push the ISA bus clock a little (more about
  438. that later on).
  439.  
  440. Still, it's clear that on all but the fastest drives the raw data
  441. transfer rate to/from the drive platter (1) will determine the
  442. maximum performance you're going to get.  If you're getting
  443. transfer rates near this limit, you can't significantly improve
  444. your throughput whatever you do.
  445.  
  446.  
  447.  *** Tuning Your Harddisk
  448.  
  449. Suppose your harddisk throughput is lower than you think is
  450. possible with your drive.  How can you tune your system to improve
  451. hard disk performance?  I'll go through points 1-4 again and
  452. indicate what you can do to widen up the bottlenecks a little.
  453.  
  454. 1. Drive platter to head transfer.
  455.     - Sorry, there's nothing you can do short of getting a new
  456.       drive.
  457.       
  458. 2. The drive controller.
  459.     - Many modern drives understand "block transfer", also known as
  460.       multi-sector I/O or read/write multiple.    Although the newest
  461.       BIOSes have this feature built in, most of us will have to
  462.       use a driver.  More about that at the end of this section.
  463.       
  464.       What is block transfer?  Normally, for each sector the
  465.       computer wants to read from or write to the drive, it has to
  466.       issue a separate command.  When you're transfering 2 MB/s,
  467.       that means you're sending the drive 4,000 commands each
  468.       second.  Each command has to be issued by the CPU, transferred
  469.       over the ISA and IDE buses, interpreted and acted upon by the
  470.       drive's onboard controller.  Every such command takes a little
  471.       time.
  472.    
  473.       By using block transfer mode, it is possible to read or write
  474.       more than one sector (usually 4 to 32) using a single command.
  475.       This greatly cuts down command overhead, as you can imagine,
  476.       and may very well have a dramatic effect on a badly performing
  477.       system.  In most cases, it will improve performance by 5-20%.
  478.       
  479.       Unfortunately some older drives have inferior support of this
  480.       feature and actually slow down...  or in exceptional cases
  481.       even hose your data.
  482.  
  483. 3. The IDE bus.
  484.     - With most drives you can use faster IDE bus timing, but your
  485.       interface has to support this.  Modern IDE interface chips
  486.       often have completely programmable timing; these can be
  487.       exceptionally fast if the software supports this feature and,
  488.       of course, if the drive can keep up.  Some controllers use
  489.       jumpers to configure timing.
  490.  
  491.       The last word in IDE bus bandwidth is of course the Enhanced
  492.       IDE bus, which allows exceedingly fast transfers if both
  493.       drives and interface support it.
  494.  
  495.       If you cannot use improved timing with a new VLB interface,
  496.       the IDE bus will prove to be as much as a bottleneck as the
  497.       ISA bus was.
  498.  
  499.     - Not all interfaces are created equal, some are better
  500.       engineered.  With the current VLB hype, there's bound to be
  501.       a friend who has an old (ISA) interface gathering dust; try
  502.       that one.
  503.  
  504. 4. The ISA bus.
  505.     - The official speed of the ISA bus is about 8 MHz, but most
  506.       cards, especially modern ones, will work fine on 11 MHz or
  507.       more (some will even take as much as 20 MHz).  If you don't
  508.       mind experimenting, it may be worthwhile to see if your
  509.       ISA cards run reliably at a higher bus clock.  This is
  510.       especially interesting if your drive nears the 2MB/s mark.
  511.  
  512.       The BIOS setup has to support this, of course.
  513.  
  514.       *WARNING* Pushing the ISA bus clock beyond spec often works
  515.       well, but there is always the risk that it DESTROYS YOUR
  516.       DATA.  Make a backup before attempting this and thoroughly
  517.       verify correct operation before entrusting critical jobs to
  518.       a "pushed" system.
  519.  
  520.     - Finally, if you need more than the 2.5-3 MB/s or so you can
  521.       squeeze out of a good ISA controller, VLB is the way to go.
  522.       Be aware that the controllers on the market are of variable
  523.       quality; VLB alone isn't going to be enough if you need the
  524.       highest performance.  It has occurred that a VLB interface
  525.       proved to be, all things equal, slower than the ISA one it
  526.       replaced!
  527.  
  528.       Take special note of the drivers: they must be stable and
  529.       support whatever software you intend to use (DOS, Windows
  530.       32-bit VxD, OS/2).  Without a driver loaded, the VLB
  531.       interface will perform no better than an ISA controller.
  532.  
  533. A final word about block transfer drivers.  VLB controllers are
  534. usually shipped with a TSR that, among other things, enables block
  535. transfers (usually designated "Turbo" mode)---this is often where
  536. most of the performance gain actually comes from.  But block mode
  537. is equally possible using ISA based interfaces.  Popular block
  538. transfer drivers are Drive Rocket and DiskQwik.  You can get a
  539. crippled version of the latter from Simtel:
  540.  
  541.     pub/msdos/diskutil/dqwik110.zip
  542.  
  543. If you're using Linux, you can use Mark Lord's IDE performance
  544. patches to enable block mode.  In true multitasking operating
  545. systems, block transfers have the additional advantage of greatly
  546. reducing CPU load.
  547.  
  548.  
  549.  
  550. Q) 3.7  How do I install a second controller?
  551. [From: strople@ug.cs.dal.ca (PAUL LESLIE STROPLE)]
  552.  
  553. The following should solve about 95% (9.5?) of second controller
  554. problems, if only to tell you it can't be done!
  555.  
  556. Generic Second Controller Installation:
  557.  
  558. 1) Normally the MFM/IDE/RLL controller is set up as the primary, and
  559. the ESDI/SCSI as the secondary; One reason for this is because the
  560. ESDI/SCSI controller cards are usually more flexible in their set up
  561. and secondly this method seems to work (probably due to reason one).
  562.  
  563. 2) Your primary controller is set up using all the normal defaults:
  564.    - Floppy  at primary address(3F0-3F7).
  565.    - Hard disk enabled, at primary addresses (1F0-1F7),
  566. BIOS address C800 and interrupt 14.
  567.  
  568. 3) Your secondary controller is set up as:
  569.    - Floppy drives disabled
  570.    - Hard disk controller enabled, secondary address(170- 177) and
  571.      interrupt 15.
  572.    - NOTE: onboard bios set to D400, or D800 can be used, if there is a
  573.      conflict.
  574.  
  575. 4) Computer BIOS Setup:
  576.    - Any drive(s) on the primary controller (MFM/IDE), should be
  577.      entered in the BIOS setup as usual.
  578.    - You DO NOT enter the drive types for the hard disks on the
  579. secondary controller, even if there are only two drives in the entire
  580. system i.e., if one drive on each controller you only enter the drive
  581. type of the hard disk on the primary controller -- the 2nd drive type
  582. is left as not installed (0).
  583.  
  584. Operating System:
  585.  
  586. If you do the above steps you now have the hardware setup correctly;
  587. your only other problem may be with the operating system.
  588.  
  589. Different OSs handle secondary controllers differently; as well,
  590. different controllers handles same OSs differently (scared yet?).
  591.  
  592. For example: with DOS you may require a device driver (available from
  593. the manufacture or through third party companies, such as Ontrack
  594. Computer Systems -- more on Ontrack later). Some flavors of UNIX
  595. handle a mixture of controllers better than others (e.g., IA 5.4 had
  596. probs mixing ESDI and SCSI controllers under certain conditions).
  597.  
  598. Procedure:
  599.  
  600. You should verify that your secondary controller, and associated hard
  601. drives, are working properly (you can try this by installing it as the
  602. primary system -- removing existing system first!).  Follow above
  603. steps 1 to 4, pray, and turn on system! If it still won't work you may
  604. need additional drivers. First check with the supplier or manufacture
  605. (I know, for example, a DTC ESDI controller comes with the DOS drivers
  606. included, and it works perfectly).
  607.  
  608. I am not sure of operating systems supported by Ontrack Data Systems.
  609. I know that their DOS driver can assist secondary controllers, even
  610. allowing two IDEs to co-exist. Likewise, the drivers can also install
  611. virtually any drive, regardless of what is supported by the BIOS.
  612.  
  613. BIG NOTE: The features required in a secondary controller are normally
  614. not found on a $30.00 IDE controller. The best thing to do it, if
  615. possible, is to get a guarantee from the supplier/manufacture that if
  616. it doesn't work (and they can't make it) then they will take it back.
  617.  
  618. Ontrack supplies a complete range of hard disk products and services
  619. -- from driver software, data recovery services, to media and data
  620. conversions (including tape backups).  The product I know them from is
  621. DiskManager.
  622.  
  623. Disk Manager is a utility for hard disk management. It will allow you
  624. to setup and install virtually any hard disk, regardless of disk's
  625. layout and BIOS options available. Disk Manager (version greater than
  626. 5.2.X, or there abouts) includes a driver for co-resident controllers.
  627. For driver to work the co-res board must be able to hit the above
  628. addresses and must be WD1003 AT command set compatible (this includes
  629. most IDE and ESDI boards).
  630.  
  631. DM contains a number of features, including full diagnostics.  You may
  632. not need to know the disk's geometry, as there are numerous layouts
  633. stored internally. All you need to do is select the correct model and
  634. DM does the rest.
  635.  
  636. To contact Ontrack: U.S.  (800)-872-2599; UK 0800-24 39 96 this is
  637. either an address or phone number! outside U.K. (but NOT U.S.)
  638. 44-81-974 5522
  639.  
  640.  
  641. Q) 3.8  >What is EIDE/Fast-ATA/ATA-2/ATAPI what advantages do they have?
  642.  
  643. This topic is posted separately as the "Enhanced IDE/Fast-ATA/ATA-2 FAQ"
  644. and archived along side this FAQ.  Refer to section one for
  645. instructions on retrieving this file.
  646.  
  647. Newsgroups: comp.sys.ibm.pc.hardware.storage,comp.sys.ibm.pc.hardware.misc,
  648.             comp.answers,news.answers
  649. Subject: Enhanced IDE/Fast-ATA/ATA-2 FAQ [* of *]
  650. From: pieterh@sci.kun.nl (Maintainer)
  651. Summary: This FAQ addresses issues surrounding Enhanced IDE, ATA-2,
  652.     ATAPI and Enhanced BIOSes. It includes practical questions,
  653.     background information and lists of net resources.
  654. Archive-name: pc-hardware-faq/enhanced-IDE
  655.  
  656.  
  657. Q) 3.9  Which is better, SCSI or IDE?
  658. [From: ralf@alum.wpi.edu (Ralph Valentino)]
  659.  
  660. IDE vs SCSI
  661.  
  662. Non-issues:
  663. 1) SCSI and IDE devices cost approximately the same for the same
  664.    features (size, speed, access time).  Shop around for good prices.
  665.  
  666. Advantages of IDE:
  667. 1) faster response time (low request overhead)
  668. 2) hard drive interface is compatible with RLL/MFM/ESDI: any driver
  669. for one (including the main system BIOS) will run the other.
  670. 3) IDE controllers are considerably cheaper ($150 and up) than SCSI
  671.    host adapters. 
  672. 4) Will always be the boot device when mixed with SCSI.
  673.  
  674. Advantages of SCSI:
  675. 1) Supports up to 7 devices per host adapter.  This saves slots,
  676. IRQ's, DMA channels and, as you add devices, money.
  677. 2) Supports different types of devices simultaneously the same host
  678. adapter (hard drives, tape drives, CDROMs, scanners, etc).
  679. 3) SCSI devices will work in other systems as well (Mac, Sparc, and
  680. countless other workstations and mainframes).  If you change platforms
  681. in the future, you will still be able to use your SCSI devices.
  682. 4) Automatically configures device type, geometry (size), speed and
  683. even manufacturer/model number(SCSI-2).  No need to look up CMOS
  684. settings.
  685. 5) Busmastering DMA (available in all but a few cheap SCSI host
  686. adapters) decreases amount of CPU time required to do I/O, leaving
  687. more time to work on other tasks (in multitasking OS's only).
  688. 6) Software portability - drivers are written for the host adapter,
  689. not the specific device.  That is, if you have a CDROM driver for your
  690. host adapter, you can purchase any brand or speed SCSI CDROM drive and
  691. it will work in your system.
  692. 7) Will coexist with any other type of controller (IDE/RLL/MFM/ESDI)
  693. or host adapter (other SCSI cards) without any special tricks.  SCSI
  694. host adapters do not take up one of the two available hard drive
  695. controller port addresses.
  696. 8) greater bandwidth utilization (higher throughput) with multiple
  697. devices.  Supports pending requests, which allows the system to
  698. overlap requests to multiple devices so that one device can be seeking
  699. while the second is returning data.
  700. 9) Ability to "share" devices between machines by connecting them to
  701. the same SCSI bus.  (note: this is considerably more difficult to do
  702. than it sounds).
  703. 10) Bridges are available to hook RLL and ESDI drives to your SCSI host
  704. adapter.  (note: these tend to be prohibitively expensive, though).
  705.  
  706. Warnings:
  707. 1) With otherwise equal drives, IDE will perform better in DOS due to
  708. low command overhead.  SCSI, however, will perform better in
  709. multitasking OS's (OS/2, Unix, NT, etc).  If you see speed comparisons
  710. (benchmarks), make sure you know what OS they were run under.
  711. 2) Most benchmarks only test one aspect of your system at a time, not
  712. the effect various aspects have on each other.  For instance, an IDE
  713. drive may get faster throughput but hurt CPU performance during the
  714. transfer, so your system may actually run slower.  Similar confusions
  715. arise when comparing VLB and EISA host adapters.
  716. 3) When comparing two systems, keep in mind that CPU, memory, cache,
  717. and bus speed/type will all effect disk performance.  If someone gets
  718. great I/O performance with a particular controller/drive combination
  719. on his Pentium, you should not expect your 386SX-25 to get such I/O
  720. performance even with the exact same controller/drive combination.
  721. 4) Similarly sized or even priced drives may not perform equally, even
  722. if they're made by the same manufacturer.  If you're going to compare
  723. two drives, make sure they have the exact same model number.  (IDE
  724. drives usually have an 'A' and SCSI drives usually have an 'S'
  725. appended to their model number).
  726.  
  727.  
  728. Q) 3.10  Can MFM/RLL/ESDI/IDE and SCSI coexist?
  729.  
  730. The PC is limited to two drive controllers total.  SCSI, however, is a
  731. "host adapter" and not a drive controller.  To the rest of your
  732. system, it appears more like an ethernet card than a drive controller.
  733. For this reason, SCSI will always be able to coexist with any type
  734. drive controller.  The main drawback here is that on most systems, you
  735. must boot off a disk on the primary drive controller, if you have one.
  736. That means if you have SCSI and IDE in your system, for example, you
  737. can not directly boot from the SCSI drive.  There are various ways to
  738. get around this limitation, including the use of a boot manager.
  739.  
  740. Q) 3.11  What's the difference between SCSI and SCSI-2? Are they compatible?
  741.  
  742. The main difference between SCSI and SCSI-2 are some new minor
  743. features that the average person will never notice.  Both run at a
  744. maximum 5M/s.  (note: Fast and Wide SCSI-2 will potentially run at
  745. faster rates).  All versions of SCSI will work together.  On power up,
  746. the SCSI host adapter and each device (separately) determine the best
  747. command set the speed that each is capable of.  For more information
  748. on this, refer to the comp.periphs.scsi FAQ.
  749.  
  750. Q) 3.12  How am I suppose to terminate the SCSI bus?
  751.  
  752. Some basic rules on termination:
  753.  
  754. 1. The SCSI bus needs exactly two terminators, never more, never less. 
  755. 2. Devices on the SCSI bus should form a single chain that can be
  756.    traced from the device at one end to the device at the other.  No
  757.    'T's are allowed; stub length should be kept as short as possible.
  758. 3. The device at each end of the (physical) SCSI bus must be
  759.    terminated, all other devices must be unterminated.
  760. 4. All unused connectors must be placed _between_ the two terminated devices.
  761. 5. The host adapter (controller) is a SCSI device.
  762. 6. Host adapters may have both an internal and external connector; these
  763.    are tied together internally and should be thought of as an "in"
  764.    and "out" (though direction has no real meaning).  If you have only
  765.    internal or external devices, the host adapter is terminated
  766.    otherwise it is not.
  767. 7. SCSI ID's are logical assignments and have nothing to do with where
  768.    they go on the SCSI bus or if they should be terminated.
  769. 8. Just because your incorrectly terminated system happens to work
  770.    now, don't count on it continuing to do so.  Fix the termination.
  771.  
  772. Examples:
  773.  
  774.       internal      external           internal            external
  775.     T------|-----|------T          T------|-------|-----|------|------T
  776.  drive   drive   HA    cdrom      tape  unused unused   HA   drive  drive
  777.  
  778.         internal             external             external
  779.      T------|-----T      T------|------T          T------T
  780.    drive  drive   HA     HA    tape   cdrom       HA    cdrom
  781.  
  782. "T" = terminator   "|" = connector (no terminator)   "HA" = Host Adapter
  783.  
  784. Q) 3.13  Can I share SCSI devices between computers?
  785.  
  786. There are two ways to share SCSI devices.  The first is removing the
  787. device from one SCSI host adapter and placing it on a second.  This
  788. will always work if the power is off and will usually work with the
  789. power on, but for it to be guaranteed to work with the power on, your
  790. host adapter must be able to support "hot swaps" - the ability to
  791. recover from any errors the removal/addition might cause on the SCSI
  792. bus.  This ability is most common in RAID systems.
  793.  
  794. The second way to share SCSI devices is by connecting two SCSI busses
  795. together.  This is theoretically possible, but difficult in practice,
  796. especially when disk drives are on the same SCSI chain.  There are a
  797. number of resource reservation issues which must be resolved in the
  798. OS, including disk caching.  Don't expect it to 'just work'.
  799.  
  800. Q) 3.14  What is Thermal Recalibration?
  801.  
  802. When the temperature of the hard drive changes, the media expands
  803. slightly.  In modern drives, the data is so densely packed that this
  804. expansion can actually become significant, and if it is not taken into
  805. account, data written when the drive is cold may not be able to be
  806. read when the drive is warm.  To compensate for this, many drives now
  807. perform "Thermal Recalibration" every degree C (or so) as the drive
  808. warms up and then some longer periodic interval once the drive has
  809. reached normal operating temperature.  When thermal recalibration
  810. takes place, the heads are moved and the drive may sound like you are
  811. accessing it.  This is perfectly normal.
  812.  
  813. If you're attempting to access the drive when thermal recalibration
  814. occurs, you may experience a slight delay.  The only time this becomes
  815. important is when you're doing real-time operations like recording /
  816. playing sound or video.  Proper software buffering of the data should
  817. be able to hide this from the application, but software seldom does
  818. the proper thing on its own.  Because of this, a few companies have
  819. come out with special drive models for audio/video use which employ
  820. special buffering techniques right on the drive.  These drives, of
  821. course, cost significantly more than their counterparts.  Some other
  822. drives offer a way to trigger thermal recalibration prematurely (thus
  823. resetting the timer), so if your real-time operation is shorter than
  824. the recalibration interval, you can use this to assure your operation
  825. goes uninterrupted.  Disabling or delaying recalibration is dangerous
  826. and should be completely avoided.  For more information on the thermal
  827. recalibration characteristics of a drive, contact the drive
  828. manufacturer directly.
  829.  
  830. Q) 3.15  Can I mount my hard drive sideways/upside down?
  831.  
  832. Old hard drives always had specific requirements for mounting while
  833. most modern hard drives can be mounted in any orientation.  Some
  834. modern hard drives still have mounting restrictions; the only way to
  835. be sure is to read the documentation that comes with the drive or
  836. contact the manufacturer directly and ask.  Restrictions may be model
  837. specific so be sure you know the exact model number of your drive.  A
  838. common misconception is that it is always safe to mount the circuit
  839. board side up, this is not the case.  When in doubt, look it up.
  840.  
  841. Failure to follow the mounting instructions can result in a shortened
  842. lifetime.
  843.  
  844.  
  845. Q) 3.16  How do I swap A: and B:
  846. [From: rgeens@wins.uia.ac.be (Ronald Geens)]
  847.  
  848. To swap A: and B: drives :
  849. 1) open up your machine to see if look at the cable that interconnects
  850. the 2 drives.
  851. 2) if the cable is twisted, there is no problem, just switch the
  852. connectors from 1 drive to the other.And change the bios-setup.
  853.  
  854. [Note: "B:" is in the center of the cable, "A:" is at the end, after
  855.  the twist.]
  856.  
  857. 3) if the cable isn't twisted (which is very,very rare), it's a little
  858. harder: leave the cables as they are, but change the jumpers on the
  859. drive. (this sounds a lot tougher, but it can usually be done without
  860. to much hassle.  When the cable connecting the 2 drives is just a flat
  861. one (like the harddisk cable) then you must play with the jumpers on
  862. the drives: Most of the time, there is a jumper with 4 pins, with the
  863. following layout:
  864.                                _
  865.                               |1|
  866.                  |2*3|
  867.                               ---
  868.  
  869. Where the * is the 4th unnumbered pin. Normally the A: drive will have a 
  870. jumper on pin 2 & 4 and the B: drive on 1 & 4. Just change these jumpers 
  871. around, (i.e. new A: 2&4, new B: 1&4) and change the BIOS configuration.
  872. 4) Don't panic if it doesn't work, just make sure all cables are
  873. conected properly and if that doesn't work just restore everything to
  874. its old state.
  875. PS. By twisted cable, I mean that between the A: and B: drive, a few
  876. wires of the flat cable are turned around.
  877.  
  878. [From: sward+@CMU.EDU (David Reeve Sward)]
  879.  
  880. I have found two ways to do this: I originally switched their
  881. positions on the cable attached to the controller, and changed the
  882. BIOS to reflect this.  I recently got a gsi model 21 controller for my
  883. IDE drive, and this controller allows you to specify which drive is A:
  884. and B: in software (it lights the LEDs in turn and asks which is A:
  885. and which is B:).  This did not require a cable change (but I still
  886. changed by BIOS).
  887.  
  888.  
  889. Q) 3.17  My floppy drive doesn't work and the light remains on, why?
  890.  
  891. If you've played around with the floppy cables at all, chances are you
  892. put one of them on backwards.  In general, floppy cables aren't keyed
  893. to prevent this.  Carefully find pin 1 on all floppy drives and the
  894. floppy controller and make sure they all line up with pin 1 on the
  895. cable.  If you have trouble with this, "How do I find pin 1..."
  896. elsewhere in this FAQ may be of some help.
  897.  
  898. Q) 3.18  What is a 16550 and do I need one?
  899.  
  900. The 16550 is a UART with two 16 byte FIFOs.  A UART is the part of a
  901. serial port that takes byte-wide (characters) data and converts it to
  902. bit-wide (serial) data, and visa versa.  The FIFO is a buffer which
  903. can hold characters until the CPU is ready to remove it or until the
  904. serial line is ready to transmit it.  The 'normal' UART in the PC (the
  905. 8250 or 16450) only has 1-byte FIFOs.  The additional 15 bytes can be
  906. useful when the CPU is busy doing other things - if the CPU isn't able
  907. to remove data fast enough, it will be lost.  The OS or program has to
  908. explicitly support 16550 to make full use of its advantages.
  909.  
  910. A very important thing to note is that under DOS, the CPU doesn't have
  911. anything else to do, so the 16550 is wasted.  Only under multitasking
  912. operating systems does it really become useful.  The 16550 will *not*
  913. make your file transfers any faster, it will only prevent data from
  914. being lost and relieve your CPU of some overhead.  If you notice
  915. system performance dropping like a rock when file transfers are
  916. occurring, a 16550 may be helpful.  If you see re-transmissions (bad
  917. packets) or "FIFO overrun's" during file transfers under a
  918. multitasking OS, try the same thing under DOS - if the errors go away,
  919. then chances are a 16550 will be useful.  If they remain, then your
  920. problem is likely to be elsewhere.
  921.  
  922. Q) 3.19  Are there any >4 channel serial port cards?
  923. [From: wkg@netcom.com (William K. Groll)]
  924.  
  925. Here is a partial listing of vendors or serial port cards with greater
  926. than 4 ports.  In almost all cases cables and/or interface panels are
  927. required to make the physical connection to the phone lines. Some of
  928. these interfaces can be almost as expensive as the cards themselves,
  929. so find out what is needed before you order. Prices, if available in
  930. their current (late '94 or early '95 issue) catalog/price-list, are
  931. given below and do not include cables, connector panels, etc. unless
  932. noted. Some also offer driver software, either included with the card
  933. or at additional cost. Some of the cards have an on-board processor to
  934. handle the communications, while other lower cost boards require the
  935. main CPU to perform all of the housekeeping chores.
  936.  
  937. These are primarily manufacturers/distributors of industrial PCs for
  938. embedded applications, but they will sell mail-order in single
  939. quantities. I have not personally used _any_ of these cards, but
  940. believe the vendors to be reputable businesses. They offer warranties
  941. and some technical support, but as always ask before you buy and
  942. "caveat emptor".
  943.  
  944. Another source for information on this type of card is manufacturers
  945. of BBS software.
  946.  
  947.  
  948. Advantech (408)245-6678, fax 245-8268
  949.     PCL-844, 8-port Intelligent RS-232 Card
  950.  
  951. Axiom (909)464-1881, fax 464-1882
  952.     C218, Intelligent 8-port Async Card; 
  953.     C216, 16-port Intelligent RS-232 Interface Card
  954.  
  955. Contec (800)888-8884, fax (408)434-6884
  956.     COM-8SF(PC), Intelligent RS-232 Interface with 8 ports 
  957.     (up to 4 boards/system): $495
  958.  
  959. CyberResearch (800)341-2525, fax (203)483-9024
  960.     many models from 4 to 32 ports, $359 to $2895 
  961.     (appears to include cost of connectors)
  962.  
  963. Industrial Computer Source (800)523-2320, fax (619)677-0898
  964.     many models from 4 to 32 ports, $399 to $1099
  965.  
  966. Personal Computing Tools (800)767-6728, fax (617)740-2728
  967.     various 4, 8, and 16-port cards, $299 to $999
  968.  
  969. QuaTech (800)553-1170, fax 434-1409
  970.     various models with 4 or 8 ports, $299 to $675
  971.  
  972. Sealevel Systems (803)843-4343, fax 843-3067
  973.     3420, 8-port RS-232 card: $499 (includes cable with connectors)
  974.  
  975.  
  976.  
  977. Q) 3.20  Should I buy an internal or external modem?
  978. [From: arnoud@ijssel.hacktic.nl (Arnoud Martens)]
  979.  
  980. While low speed modems are often only produced as an internal PC card,
  981. most modem manufacturers provide two versions of their higher speed
  982. modems:
  983.  
  984. 1: internal ISA bus card, specially designed to work with the
  985. standard PC bus. You just plug it in and configure it to use on
  986. port.
  987.  
  988. 2: external modem that has to be connected to the serial ports of
  989. your PC (com 1-4), using a serial RS232 cable.
  990.  
  991. In most cases the functionality of these two is equal. There are
  992. however some differences in using, maintaining and buying these
  993. modems. It is very difficult to give an definite answer as to which one
  994. is better, it completely depends on your own situation. Some of the
  995. points that are in favor of an external modem are:
  996.  
  997.   * It has lights showing the status of the connection, this can be
  998.     useful in those (rare) cases that you have problems with the
  999.     connection.
  1000.  
  1001.   * It can be used on a wide range of systems. External modems
  1002.     are connected using a RS232 cable, a standard that most computer
  1003.     systems support. So you can as easily use your external modem
  1004.     on a Mac, Amiga or Unix box as on your PC. 
  1005.  
  1006.   * It doesn't consume power inside the PC (it uses a normal net
  1007.     adapter), and doesn't produce any heat inside your PC.
  1008.  
  1009. On the other hand the internal modem has also a couple of advantages
  1010. compared to an external modem:
  1011.    
  1012.   * It is always cheaper, Somewhere in the order of 10% less compared
  1013.     to the same external modem.
  1014.  
  1015.   * It doesn't need special serial hardware since it has already
  1016.     been integrated on the board, which will make it even more
  1017.     cheaper. 
  1018.    
  1019. So basically if portability of your modem is an issue, you are better
  1020. of with an external modem. But if you only intend to use the modem
  1021. with your PC and don't have any power problems, an internal modem is
  1022. the best choice.
  1023.  
  1024.  
  1025. Q) 3.21  What do all of the modem terms mean?
  1026. [From: arnoud@ijssel.hacktic.nl (Arnoud Martens)]
  1027.  
  1028. A modem (MOdulator-DEModulator) is a device capable of converting digital
  1029. data from your computer into an analog signal that is suitable for
  1030. transmission over low band width telephone lines. A modem thus makes it
  1031. possible to connect two computers over a telephone line and exchange data
  1032. between them.
  1033.  
  1034. Basically a modem picks up the phone, and dials a number. A modem on
  1035. the other side will pick up the phone and the two modems will
  1036. negotiate which protocol to use. When they agree the actual
  1037. transmission of data can begin.
  1038.  
  1039. The major feature of a modem is the speed that it can achieve
  1040. connecting to other modems. This speed is often expressed in baud or
  1041. bits per second. The first is a feature of the line and specifies how
  1042. much of the bandwidth of the phone channel is used and is fixed to
  1043. 2400 baud. A baud is defined as the number of lines changes per
  1044. second. Bits per second is the actual amount of data transmitted in
  1045. one second. Most modems are capable of sending more than one bit per
  1046. line transition by using very intelligent signal modulation
  1047. techniques. So the bps can be eight times higher compared to the baud
  1048. rate.
  1049.  
  1050. The modulation techniques that a modem uses are standarized by the
  1051. ITU-T ( former CCITT), so that modems of different brands can connect
  1052. to each other as they use the same modulation schemes. These standards
  1053. are often incorporated in a protocol definition that is referred to by
  1054. the letter V followed by a number. The most common protocols are:
  1055.  
  1056.     V21: (300 baud)
  1057.     V22bis: (2400 baud)
  1058.     V32: (9600 baud)  
  1059.     V32bis: (14400 baud)
  1060.  
  1061. A modem is often advertised only by its fastest protocol, most of these
  1062. modems "speak" slower protocols as well.
  1063.  
  1064. There are also standards on using data compression by the modem, such as MNP5
  1065. and V42bis, and error control protocols (V42 and MNP4). These standards can
  1066. reduce the transmitted data by a factor four, by using advanced compression
  1067. techniques. 
  1068.  
  1069. To give you an idea a how fast fast is in modem technology: V32bis transmits
  1070. somewhat like 1600 characters per second (that is ~33% of 1 page of
  1071. text). Transferring a file of 1Mb takes about 12 minutes. Using V42bis can
  1072. speed up transmission to 4000 characters per second for uncompressed data.
  1073.  
  1074. Apart from these standardized protocols there are also faster protocols which
  1075. are supported by some modem manufacturers. But remember anything faster than
  1076. 14k4 is *not yet* standarized, and often different manufacturers use their
  1077. own modulation scheme that allows only their own modems communicate at that
  1078. speed. The most common high speed protocols are:
  1079.  
  1080.     V32 terbo (19200 baud)
  1081.     V34 (28800 baud) or Vfast. 
  1082.  
  1083. The standard for V34 is being worked on, it will be released somewhere in
  1084. 1994. Some modem manufacturers already sell modems with the (prelimenary) V34
  1085. standard. If you are serious about buying a fast modem, upgradability to this
  1086. standard should be provided by the manufacturer.
  1087.  
  1088. When you use your modem it is important to differentiate between command
  1089. status and connect status of your modem. When you are connected to an another
  1090. modem everything you send to the modem, will be transmitted to the other
  1091. modem. In command mode everything you type will be recieved and interpreted
  1092. by the modem. Command mode allows you to change the default settings for
  1093. youyr modem.
  1094.  
  1095. In command mode it is likely that your modem will respond to the Hayes AT
  1096. command set. "AT commands" all have prefix AT, and can be used to change the
  1097. (default) settings of your modem. To check if your modem works, fire up a
  1098. terminal program (such as kermit), connect to your modem (in kermit c
  1099. [ENTER]) and issue AT [ENTER], if your modem works it should respond with
  1100. OK. For a list of all "AT commands" see the manual of your modem, as most AT
  1101. commands are modem specific.
  1102.  
  1103. If you buy a fax-modem, you should pay attention to a couple of things. First
  1104. the modem must support Class 2 fax commands, furthermore automatic fax mode
  1105. selection is a big pro. That means if you receive a call the modem is capable
  1106. of detecting a fax message or a modem connection and act properly (start up a
  1107. fax receiving program or spawn something like a login process on the
  1108. connection).
  1109.  
  1110. Finally there is no best modem to get, brands and qualities change very fast,
  1111. as do the prices. If you are interested in buying one, subscribe to the
  1112. newsgroup comp.dcom.modems, most postings in this group are very brand
  1113. oriented and you will recognize fast enough which users are satisfied over
  1114. their modems and which are not.
  1115.  
  1116.  
  1117. Q) 3.22  Why does my fast modem connect at a lower speed?
  1118.  
  1119. For 28.8 modems that connect at lower speeds such as 22, 24 or 26.4,
  1120. this is perfectly normal.  The usable channel capacity of the
  1121. telephone system with a ideal connection is just over 28.8k.  In
  1122. reality, you'll very rarely see a 28.8k connection so don't expect
  1123. it.  When the two modems connect, they will evaluate the connection
  1124. quality and pick a corresponding speed.  If you have your modem set up
  1125. correctly, it will retrain every once in a while and increase or
  1126. decrease your connection speed based on the current line quality.
  1127.  
  1128. For modems that connect at considerably lower than expected speeds
  1129. (such as 2400 for a 9600+ modem), there are two possibilities.  The
  1130. first possibility is that the remote modem can't handle the higher
  1131. speed.  There is nothing you can do about this except call a faster
  1132. modem.  The other possibility is that you have your serial port / comm
  1133. software set up incorrectly.
  1134.  
  1135. When you connect your PC to another machine through modems, there are
  1136. actually three connections being made: PC1 to modem1, modem1 to modem2
  1137. and modem2 to PC2.  The speed of the modem (2400,9600,14.4,28.8) is
  1138. the rate (more or less) at which the modem1 will speak to modem2.  The
  1139. PC to modem connections are based on the speed your COM port is set
  1140. to.  If you set the COM port speed to 2400, the modem to modem speed
  1141. will drop accordingly.  For this reason, you want to set the COM port
  1142. speed at least as high as the modem to modem speed.  In actuality, the
  1143. modem to modem protocol may support compression and achieve data
  1144. transfers faster than the connection speed so you want to set your COM
  1145. port higher than your modem to modem connection.  For a 28.8 modem,
  1146. set the COM port to 38.4k, 57.6k, or 115k.  While higher is always
  1147. (potentially) better, some software/operating systems have trouble
  1148. with very high COM port speeds, so start with 38.4k and see how it
  1149. goes.
  1150.  
  1151. Q) 3.23  >What kinds of sound cards are available?
  1152.  
  1153. This is covered in the comp.sys.ibm.pc.soundcard FAQ, archive name:
  1154. PCsoundcard/soundcard-faq.  Please refer to this document for more
  1155. information.
  1156.  
  1157. Q) 3.24  Where can I find EISA/VLB sound and IO cards?
  1158.  
  1159. Chances are that you won't be able to find them anywhere, and if you
  1160. do, they won't be worth the money.  Sound and IO cards have very low
  1161. bandwidth requirements, over 10 times lower than the ISA bandwidth and
  1162. over 60 times lower than the EISA bandwidth.  For this reason, there
  1163. is no advantage in placing them on the more expensive EISA/VLB cards
  1164. when the less expensive ISA will more than suffice, especially
  1165. considering than all ISA cards will work in an EISA/VLB slot.
  1166.  
  1167. Q) 3.25  Where can I get DOS drivers for my ethernet card?
  1168. [From: ralf@alum.wpi.edu (Ralph Valentino)]
  1169.  
  1170. The first thing you need is a low level packet driver for your
  1171. ethernet card.  This driver links your card specific functions to a
  1172. common software interface allowing higher level software to read
  1173. and write to your ethernet card without knowing any of the hardware
  1174. specifics.  Ethernet cards usually come with a packet driver.  If you
  1175. didn't get one, try contacting the card manufacturer (they may have a
  1176. www/ftp site, see the references section of this FAQ).
  1177.  
  1178. Another option is using publicly available packet drivers.  The Crynwr
  1179. packet driver collection is free, supports a significant number of
  1180. cards and comes with sources and documentation.  You can find this
  1181. package in the "pktdrvr" subdirectory on any of the Simtel mirrors.
  1182. For instance:
  1183.  
  1184.    wuarchive.wustl.edu:/systems/ibmpc/simtel/pktdrvr/
  1185.    ftp.uu.net:/systems/msdos/simtel/pktdrvr/
  1186.  
  1187. The files of interest are:
  1188.  
  1189.   pktdrvr11.zip  -  executable
  1190.   pktdrvr11a.zip pktdrvr11b.zip pktdrvr11c.zip  -  sources
  1191.  
  1192. The included instructions explain how to install them.  The file
  1193. "software.doc" (within the zip archive) contains pointers to a number
  1194. of other useful protocol drivers, which is the next thing you need.
  1195.  
  1196. The protocol driver sits on top of the packet driver and implements
  1197. one of the many standard protocols (IPX, TCP/IP, etc).
  1198.  
  1199. IPX protocol drivers, needed for many multiplayer games, can be found
  1200. in the same "pktdrvr" directory as the Crynwr packet drivers.  Files
  1201. of interest are:
  1202.  
  1203.     novel.zip  - IPX protocol driver from BYU
  1204.     intelpd.zip - IPX protocol driver from Intel (newer)
  1205.  
  1206. Either of the above will do.
  1207.  
  1208. For a quick TCP/IP implementation allowing telnet and file transfers
  1209. with both Unix and other DOS machines with very little setup, try
  1210. Kermit.  You can get Kermit from the Columbia University distribution
  1211. site:
  1212.  
  1213.    kermit.cc.columbia.edu:systems/msdos/msvibm.zip
  1214.                                   - everything you need for DOS and more
  1215.  
  1216. To make a connection, type:
  1217.  
  1218.    set tcp/ip address *.*.*.* (where *.*.*.* is your IP address)
  1219.    set port tcp/ip *.*.*.*    (where *.*.*.* is the destination IP address)
  1220.    connect
  1221.  
  1222. Remember to type "set file type binary" at the Kermit prompt on both
  1223. ends if you are transfering binary files (anything but unarchived
  1224. text).  See the documentation and on-line help for time transfer
  1225. optimization as well as how to set the rest of the TCP/IP related
  1226. parameters (netmast, broadcast address, bootp server, nameserver, etc)
  1227. if you are interfacing to an existing network.
  1228.  
  1229. Another program of interest is NCSA Telnet.
  1230.  
  1231.     ftp.ncsa.uiuc.edu:PC/Telnet/tel23bin.zip - binaries
  1232.     ftp.ncsa.uiuc.edu:PC/Telnet/tel23src.zip - sources
  1233.  
  1234. Many commercial protocol drivers/applications are also available,
  1235. including Windows for Workgroups, PC/TCP, WIN/TCP and PC-NFS, to name
  1236. a few.  See your local software store for information on these.
  1237.  
  1238.  
  1239.  
  1240. Q) 3.26  How does the keyboard interface work?
  1241.  
  1242. [From: jhallen@world.std.com (Joseph H Allen)]
  1243.  
  1244. The IBM keyboard is connected to the computer through a serial interface
  1245. similar to a COM port.  When you press a key, the keyboard sends a
  1246. "scan-code" for that key to the computer.  When you release the key, the
  1247. keyboard sends a release code to the computer.  If you hold down one key and
  1248. press and release another key, the computer will receive the scan-code for
  1249. the held key and a scan and release code for the other key.  Since the
  1250. release code for the held key was not received, the computer knows that the
  1251. held key was down while the other key was pressed.  In this way, the
  1252. computer can handle the Shift, Alt and Ctrl keys (and any key could work
  1253. like a shift key, since all keys work alike).  The ROM BIOS in the computer
  1254. buffers the data from the keyboard, translates the scan-codes to ASCII and
  1255. handles the operation of the shift and lock keys.  The keyboard itself also
  1256. has a small buffer and there is hardware flow-control for preventing
  1257. overruns.  All of this seems simple and quite elegant, but by the time we
  1258. get to the AT keyboard the details of the implementation are so complicated
  1259. as to ruin an otherwise ideal keyboard.
  1260.  
  1261. The XT keyboard's interface almost captures the above elegance (indeed it is
  1262. the only elegant thing about the XT, IMHO).  The interface uses a 5-pin DIN
  1263. connector with these signal assignments:
  1264.  
  1265.      1     CLK/CTS (open-collector)
  1266.      2     RxD
  1267.      3     RESET
  1268.      4     GND
  1269.      5     +5V
  1270.  
  1271. When the keyboard has a byte to send to the computer, it shifts 9 bits out
  1272. to the data line (RxD) with nine clock pulses on the CLK line.  The data
  1273. format is 1 start bit, followed by 8 data bits.  The baud rate is roughly
  1274. 2000 bits per second and is not precisely defined.  Once a byte is
  1275. completely transmitted, the computer holds the Clear-To-Send (CTS) line low
  1276. to prevent the keyboard from sending any more bytes until the keyboard
  1277. interrupt handler reads the current one.  Usually a simple 9-bit clearable
  1278. TTL shift register is used to receive keyboard data.  The 9th bit of the
  1279. shift register is used to drive an open-collector buffer connected to the
  1280. CTS line.  When the start-bit gets all of the way through the shift
  1281. register, it holds the CTS line low itself.  Once the CPU reads the
  1282. assembled byte, it has only to clear the shift register to release the CTS
  1283. line and allow another byte to be received.  Three TTL chips or a single PAL
  1284. can implement an entire XT keyboard interface.
  1285.  
  1286. The data bytes which the XT sends are also simple.  Codes 0-127 are the
  1287. scan-codes.  Codes 128-255 are the release codes- they're the same as the
  1288. scan codes, but with the high bit set.  The XT keyboard has only 84 keys, so
  1289. not all of the scan-codes are used.
  1290.  
  1291. The only problems with the XT keyboard are the lock-status lights
  1292. (Caps-lock, Scroll-lock and Num-lock) and the key repeat mechanism.  The
  1293. lock-status lights can get out of sync with the computer's idea of which
  1294. lock keys are activated, but this only happens if someone resets the
  1295. keyboard by unplugging it temporarily.  When you hold a key down long
  1296. enough, the keyboard starts repeating the scan-code for that key.  The
  1297. release code is still only transmitted once, when the key is released.  The
  1298. problem here is that the delay to the start of the repeats and the repeat
  1299. rate were made too slow.  Of course, the keyboard really doesn't have to
  1300. handle repeat at all, since the computer knows when keys are pressed and
  1301. released and has a timer itself.  Old XT keyboard TSRs allowed you to adjust
  1302. the repeat delay and rate by duplicating the key repeat mechanism in the
  1303. computer.
  1304.  
  1305. Once IBM found that it had a nearly perfect keyboard it, of course, decided
  1306. that it had to be almost completely redesigned for the AT.  The keyboard
  1307. didn't have to be redesigned- there were enough extra scan-codes for the
  1308. AT's 101 key keyboard and the repeat mechanism could simply have been moved
  1309. to the BIOS.  But no, they had to redesign everything.  Sigh.
  1310.  
  1311. The AT uses a 5-pin DIN and the PS/2 uses a smaller connector with the same
  1312. signals:
  1313.  
  1314.      1     CLK/CTS (open-collector)
  1315.      2     RxD/TxD/RTS (open-collector)
  1316.      3     Not connected or Reset
  1317.      4     GND
  1318.      5     +5V
  1319.  
  1320. Now the interface is bi-directional.  When the computer wants to send a byte
  1321. to the keyboard, it asserts RTS and releases CTS.  If you're lucky, the
  1322. keyboard isn't deciding to transmit at the same time and it responds by
  1323. giving 10 clock pulses (at about 10000 baud) on the CLK line.  The computer
  1324. shifts a frame out on TxD on rising clock edges.  The frame format is now 1
  1325. start bit, 8 data bits and 1 odd parity bit.  The keyboard takes RTS being
  1326. held low as the first start bit, and the first data bit should be sent on
  1327. TxD after the first clock edge is received.  Yes, now you need a full UART
  1328. for the keyboard interface since you have to both transmit and receive and
  1329. generate and check parity (but it's still not RS-232- that would have been
  1330. too logical).  Why do you need parity checking on a three foot long keyboard
  1331. cable?  Because collisions can occur since the lines are so overloaded with
  1332. signals with different meanings and parity provides the means for detecting
  1333. these collisions.
  1334.  
  1335. The AT documentation says that pin 3 is "reserved", so the keyboard has to
  1336. provide its own reset.  But on the original AT, pin 3 was still Reset and
  1337. IBM's own keyboards at that time needed Reset (original AT keyboards won't
  1338. work on some old clones because of this).  Don't ask me... I don't
  1339. understand why they did this.
  1340.  
  1341. The protocol on the keyboard interface is now much more complicated.  These
  1342. bytes are defined:
  1343.  
  1344. Commands
  1345.  
  1346.   ED <byte>                 Set leds depending on byte
  1347.                               bit 0 is Scroll lock
  1348.                               bit 1 is Num lock
  1349.                               bit 2 is Caps lock
  1350.  
  1351.   EE                        Echo EE (for testing?)
  1352.   F0 <mode>                 Select mode 1, 2 or 3
  1353.   F2                        Send keyboard I.D.
  1354.   F3 <byte>                 Set repeat delay and rate
  1355.                               byte is: 0ddbbaaa
  1356.                               delay is (dd+1)*250 msec
  1357.                               rate is (8+aaa)*2^bb*4 msec
  1358.  
  1359.   F4                        Clear buffer
  1360.   F5                        Restore default settings and wait for enable
  1361.   F6                        Restore default settings
  1362.   FA                        Acknowledge
  1363.   FE                        Error- please retransmit
  1364.   FF                        Reset keyboard
  1365.  
  1366. Status returns
  1367.  
  1368.   00                        Buffer overflow
  1369.   AA                        Self-test passed
  1370.   F0 <scan-code>            Release code
  1371.   FA                        Acknowledge last command
  1372.   FD                        Self-test failed
  1373.   FC                        Self-test failed
  1374.   FE                        Last command in error; re-send
  1375.   E0 scan/release code      Extended keys in Mode 2
  1376.  
  1377. The computer and keyboard must acknowledge each command and key code with
  1378. either FA if there was no error, or FE if the last command/key-code should
  1379. be re-sent.  There are three modes of operation for the keyboard, depending
  1380. on which scan code assignments you want (these can often be set by a switch
  1381. on the back of keyboard, except that if mode 1 is selected from the switch,
  1382. the protocol is eliminated an the keyboard works exactly like an original XT
  1383. keyboard- newer keyboards only support modes 1 and 3).  In mode 1, the
  1384. keyboard gives XT scan-codes.  The keyboard handles the cursor keypad (which
  1385. didn't exist on the XT) by simulating pressing or releasing a shift key
  1386. (depending on whether shift or num-lock are pressed) and sending codes from
  1387. the numeric keypad.  Mode 2 works like mode 1, except that when the keyboard
  1388. does the weird stuff with the numeric keypad it prefixes everything with E0
  1389. and the release codes are the scan-codes prefixed with F0.  In mode 3, each
  1390. key gets a unique code and the release codes work as in mode 2: the release
  1391. are the scan-codes prefixed by F0.
  1392.  
  1393. When the AT keyboard is first reset it's supposed to send an AA if its
  1394. self-test passed or FD or FC if it failed.  But before it does this, it
  1395. sends a continual stream of AAs with the parity incorrect.  Once the
  1396. computer sends an FE to indicate that there is a parity error, the keyboard
  1397. stops sending bad AAs and sends a correct AA or an FD or FC.  This sounds
  1398. like someone made a quick fix in the keyboard firmware for mis-matched reset
  1399. timing (the keyboard always finishes resetting before the computer so the
  1400. computer could miss the AA/FD/FC).
  1401.  
  1402.  
  1403.  
  1404. Q) 3.27  Can I fake a keyboard so my computer will boot without it?
  1405.  
  1406. [From: jhallen@world.std.com (Joseph H Allen)]
  1407.  
  1408. () The IBM Keyboard - how do you use a computer without a keyboard?
  1409.  
  1410. Sometimes a PC needs to be set up as a "turn-key" system with no keyboard
  1411. for security reasons, or simply because the application doesn't need a
  1412. keyboard.  This causes a dead-lock problem when the system is booting: The
  1413. BIOS will detect that there is no keyboard and display the message "keyboard
  1414. failure - press F1 to continue," and the system becomes stuck.
  1415.  
  1416. There is usually a BIOS set-up option for disabling the keyboard test.
  1417. Check the manual for your motherboard.  If your BIOS does not have
  1418. this option, you're essentially screwed because there's no simple
  1419. solution.  You can't wire the DIN to fake the existence of a keyboard
  1420. since the BIOS checks for a self-test result code generated by the
  1421. keyboard.  You have to implement a small protocol (byte-by-byte
  1422. handshaking and ACK/NAK) to simulate a keyboard up to its self test.
  1423. There are adaptors available which contain a small microcontroller
  1424. programmed to do this.  Another solution is to replace your BIOS with
  1425. one which has the keyboard test disable option.  However, you have to
  1426. find one which matches your motherboard.
  1427.  
  1428.  
  1429.  
  1430.  
  1431. ===============
  1432. Ralph Valentino  (ralf@worcester.com) (ralf@alum.wpi.edu) 
  1433. Senior Design Engineer, Instrinsix Corp.
  1434.