uweseimet / scsi2pi

Advanced performant SCSI/SASI emulation and tools for the PiSCSI/RaSCSI board
https://www.scsi2pi.net
BSD 3-Clause "New" or "Revised" License
9 stars 2 forks source link

s2pdump: Generate device data information for s2p property files, including mode pages #16

Closed uweseimet closed 9 months ago

uweseimet commented 9 months ago

With the -I option s2pdump shall print device property data than can directly be used for s2p property files. Besides ID, LUN, INQUIRY data and the block size s2pdump should also generate mode page data properties by querying all mode pages. With this information the properties of an emulated device are very close to those of the real device the data were derived from.

This feature allows the advanced cloning of drives. In addition to cloning the drive's sector data you can also clone other drive properties.

>s2pdump -I -i 5
----------------------------------------
Board ID is 7
----------------------------------------
Scanning target ID:LUN 5:0
Vendor:               'PLEXTOR '
Product:              'CD-ROM PX-40TS  '
Revision:             '1.11'
Device Type:          CD-ROM/DVD/BD/DVD-RAM
SCSI Level:           SCSI-2
Response Data Format: SCSI-2
Removable:            Yes

Device properties for s2p properties file:
device.5.type=SCCD
device.5.product_name=PLEXTOR:CD-ROM PX-40TS:1.11
device.5.mode_page.1=01:06:00:0a:00:00:00:00
device.5.mode_page.2=02:0e:02:00:00:00:00:00:00:00:00:00:00:00:00:00
device.5.mode_page.13=0d:06:00:0b:00:3c:00:4b
device.5.mode_page.14=0e:0e:04:00:00:00:00:00:01:ff:02:ff:00:00:00:00
device.5.mode_page.49=31:02:06:00