Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 7 Oct 2000 15:20:31 -0700 (MST)
From:      John Reynolds <jjreynold@home.com>
To:        "Kenneth D. Merry" <ken@kdm.org>
Subject:   Re: what part of the driver locks the CD tray?
Message-ID:  <14815.41391.607241.353903@whale.home-net>
In-Reply-To: <20001005225426.A45446@panzer.kdm.org>
References:  <14813.21325.718668.456937@whale.home-net> <20001005225426.A45446@panzer.kdm.org>

next in thread | previous in thread | raw e-mail | index | archive | help

[ On Thursday, October 5, Kenneth D. Merry wrote: ]
> 
> Yes.  To prevent removal:
> 
> camcontrol cmd cd0 -v -c "1e 0 0 0 1 0"
> 
> To allow removal:
> 
> camcontrol cmd cd0 -v -c "1e 0 0 0 0 0"

These commands worked for my plain CD-ROM drive on cd0 but did not work for my
SCSI CD-RW on cd1

  cd1 at ahc0 bus 0 target 4 lun 0
  cd1: <YAMAHA CRW4416S 1.0g> Removable CD-ROM SCSI-2 device 
  cd1: 8.333MB/s transfers (8.333MHz, offset 31)
  cd1: cd present [239755 x 2048 byte records]
  
When I run the "lock" command (s/cd0/cd1), I get:

  camcontrol: error sending command
  (pass2:ahc0:0:4:0): PREVENT ALLOW MEDIUM REMOVAL. CDB: 1e 0 0 0 1 0 
  (pass2:ahc0:0:4:0): NOT READY asc:3a,1
  (pass2:ahc0:0:4:0): Medium not present - tray closed

Is the command different for CDRW drives? There is no media in either drive but
the command for locking/unlocking on cd0 works regardless of media.

Thanks Kenneth,

-Jr

ps: if I put media into the CD-RW drive and execute the clock command I get
this:

  camcontrol: error sending command
  (pass2:ahc0:0:4:0): PREVENT ALLOW MEDIUM REMOVAL. CDB: 1e 0 0 0 1 0 
  (pass2:ahc0:0:4:0): UNIT ATTENTION asc:28,0
  pass2:ahc0:0:4:0): Not ready to ready change, medium may have changed

?

-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
John Reynolds         Chandler Capabilities Engineering, CDS, Intel Corporation
jreynold@sedona.ch.intel.com  My opinions are mine, not Intel's. Running
jjreynold@home.com          FreeBSD 4.1-STABLE. FreeBSD: The Power to Serve.
http://members.home.com/jjreynold/  Come join us!!! @ http://www.FreeBSD.org/
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=


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




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