[comp.unix.internals] SCSI read works, SCSI write doesn't

raja@bombay.cps.msu.EDU (Narayan S. Raja) (09/22/90)

Hi.  We have a somewhat mystifying problem
with a peripheral connected to a sparcstation-1
(SunOS 4.1) over the SCSI port.

Incidentally, the peripheral device happens
to be a laser range scanner (never mind what
that is), the software on which emulates a
SCSI disk, e.g. /dev/rsd1c.  So when you 
boot up, the SCSI controller "sees" an external 
SCSI disk connected (say "sd1").

The problem is:  we are able to read data from
this device, but it will not respond to any
commands sent to it.  (Commands are sent to it
by "writes" to the emulated SCSI disk, /dev/rsd1c).  

But the "write" function exits normally (i.e. does
not return -1)!!  What's going on?

We also performed the following test:

  1. We connected a REAL external (shoebox)
       disk to the same SCSI port, mounted
       it, and "touch"ed a file on it.  No
       problem.  So the SCSI port itself is
       OK both for reads and writes.


So something is either wrong with the special
connector going to the laser scanner (in a
screwy way which doesn't indicate that writes
are failing), OR something is not set up right
for our program to write properly.  (Yes, we
"open" the file for read/write).

Any help would be deeply appreciated.  Email
preferred:   raja@cpswh.cps.msu.edu
             raja%cpswh.cps.msu.edu@uunet.uu.net


Narayan Sriranga Raja.