Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Sep 1998 18:30:59 -0500 (CDT)
From:      jimd@SPAMYOURSELFdutton3.it.siu.edu (Jim Dutton)
Cc:        freebsd-doc@FreeBSD.ORG
Subject:   Finally got ATAPI ZIP working with ATAPI CD-ROM
Message-ID:  <199809152330.SAA14778@dutton3.it.siu.edu>

next in thread | raw e-mail | index | archive | help
I have an ATAPI Iomega/100 ZIP drive on the same "channel" (?) as
an ATAPI Toshiba CD-ROM. Under FreeBSD-2.2.6R, I could use only one of
these two devices - the system would only acknowlege one of them.

With the "atapi.c" patch from Satoh Junichi, FBSD-2.2.6R now recognizes
and accepts both the Atapi CD-ROM and the Atapi ZIP drives.

Using the ZIP drive was a little bit of a mystery. Starting with
the FBSD FAQ item#8.4 (I have a new removable drive, how to I use it?), I
wound up with the following, with regards to an ATAPI ZIP drive
instead of the SCSI ZIP drive in the FAQ:

- -- -  - - - - - - - - - - - - - -

For an MS-DOS device (where the ZIP media is MS-DOS preformatted, and
the "/zip" directory is already defined):

	mount -t msdos /dev/wfd0 /zip

Normal MS-DOS caveats apply: whilst the ZIP media is accessible via
normal Unix commands, all file/directory names are truncated to MS-DOS
standards.

For a UNIX device (again, "/zip" already exists):

	/etc/disktab:

	zip100|zip 100:\
 	       :ty=removable:se#512:nc#96:nt#64:ns#32:\
	       :pa#196608:oa#0:ba#4096:fa#512:ta=4.2BSD:\
	       :pb#196608:ob#0:bb#4096:fb#512:tb=4.2BSD:\
	       :pc#196608:oc#0:bc#4096:fc#512:tc=4.2BSD:


	dd if=/dev/zero of=/dev/rwfd0
	disklabel -r -w wfd0c zip100 zip1
	newfs -T zip100 wfd0c
	mount /dev/wfd0c /zip

- - - -- - - - - - - - - - - - - - -

Comments:

1) the "zip100" entry in "/etc/disktab" already existed; all that was
changed was to add the type flags ("ta=4.2BSD", etc.).

2) I don't know offhand if all three disktab partition definitions are
really necessary (perhaps they are, perhaps they aren't); FDISK will
report FOUR partitions. I would suspect that only ONE partition is
required ("pc" ?).

3) the original FAQ entry suggestion of using

	dd if=/dev/zero of=/dev/.... count=2

did not appear to prepare enough of the disk, and NEWFS attempts would
report "not enough disk space" (or "out of disk space"). I don't know
if it is really necessary to "format" the entire ZIP "disk", but I did.

4) the original FAQ entry suggestion of using

	disklabel -Brw ... auto

didn't work as "/usr/mdec/wfdboot" doesn't exist. Perhaps including "-b
boot1" would have resolved this? Also, the "auto" parameter was not
able to recognize the "media (disk) type".

4) leaving the media MS-DOS formatted appeared to offer more
free/available space (as reported by DF), by about 10MB (?)

- - - - - - - - - - - - - - - - - - - - -

Stats from various commands:

...../root: dd if=/dev/zero of=/dev/rwfd0
dd: /dev/rwfd0: end of device
196609+0 records in
196608+0 records out
100663296 bytes transferred in 4030.920802 secs (24973 bytes/sec)


...../root: disklabel wfd0
# /dev/rwfd0c:
type: unknown
disk: zip100
label: zip1
flags: removeable
bytes/sector: 512
sectors/track: 32
tracks/cylinder: 64
sectors/cylinder: 2048
cylinders: 96
sectors/unit: 196608
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0           # milliseconds
track-to-track seek: 0  # milliseconds
drivedata: 0 

3 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  a:   196607        0    4.2BSD      512  4096     0   # (Cyl.    0 - 95*)
  b:   196607        0    4.2BSD      512  4096     0   # (Cyl.    0 - 95*)
  c:   196607        0    4.2BSD      512  4096     0   # (Cyl.    0 - 95*)


...../root: newfs -T zip100 wfd0c
Warning: Block size and bytes per inode restrict cylinders per group to 5.
/dev/rwfd0c:    196608 sectors in 48 cylinders of 1 tracks, 4096 sectors
        96.0MB in 10 cyl groups (5 c/g, 10.00MB/g, 4448 i/g)
super-block backups (for fsck -b #) at:
 32, 20512, 40992, 61472, 81952, 102432, 122912, 143392, 163872, 184352,


...../root: df -k /zip
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/wfd0c      92607        0    85198     0%    /zip


...../root: dmesg
[..]
Sep 14 ... /kernel: wdc1 at 0x170-0x177 irq 15 on isa
Sep 14 ... /kernel: wdc1: unit 0 (atapi): <TOSHIBA CD-ROM XM-6202B/1108>,
            removable, accel, ovlap, dma, iordis
Sep 14 ... /kernel: wcd0: 5512Kb/sec, 256Kb cache, audio play, 255 volume levels,
            ejectable tray
Sep 14 ... /kernel: wcd0: no disc inside, unlocked
Sep 14 ... /kernel: wdc1: unit 1 (atapi): <IOMEGA  ZIP 100       ATAPI/23.D>,
            removable, intr, iordis
Sep 14 ... /kernel: wfd0: medium type unknown (no disk)
Sep 14 ... /kernel: wfd0: buggy Zip drive, 64-block transfer limit set
Sep 14 ... /kernel: sb0 at 0x220 irq 5 drq 1 on isa
[...]

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-doc" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199809152330.SAA14778>