SCSI2Pi does not only support the SCSI target mode, which is used when emulating devices. Furthermore, there is extensive support for the SCSI initiator mode, where SCSI2Pi acts like a computer. SCSI2Pi offers several initiator mode tools.
With s2pdump you create backups of hard drives or tapes, and restore hard drives/tapes from image files. Furthermore, you can scan the SCSI bus for available devices. This helps with analyzing setup issues.
s2pdump can not only clone drives or tapes but also drive properties. For this purpose the mode pages of a device can be listed as s2p properties:
>s2pdump -I -i 5 ---------------------------------------- Board ID is 7 ---------------------------------------- Checking 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 property file: device.5.type=SCCD device.5.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
These properties can directly be copied into a property file like /etc/s2p.conf, so that the emulated device has the same product data (vendor, name, revision) and mode pages as the real hardware.
With s2pexec you can send single SCSI and SASI commands or a command sequence to a device. The results are displayed on the screen or saved to a file.
>s2pexec -i 4 -c 12:00:00:00:30:00 00000000 05:80:02:02:5b:00:00:88:54:4f:53:48:49:42:41:20 '....[...TOSHIBA ' 00000010 43:44:2d:52:4f:4d:20:58:4d:2d:34:31:30:31:54:41 'CD-ROM XM-4101TA' 00000020 32:34:38:33:30:39:2f:30:35:2f:39:33:00:00:00:00 '248309/05/93....'
The example above shows the INQUIRY data returned by a CD-ROM drive.
You can also use commands which have parameters or return data, like a MODE SELECT command with parameters from the file data.dat:
>s2pexec -i 5 -c 15:11:00:04:0c:00 -t data.dat
s2pexec supports an interactive mode and also accepts command parameters on the command line:
>s2pexec -i 5:1 -c 15:11:00:00:0c:00 -d 00:00:00:08:00:00:00:00:00:00:08:00
Command scripts created by s2p can directly be executed by s2pexec. With these scripts you can execute any sequence of SCSI commands received by s2p with real hardware.
With s2pformat you format media in USB drives, e.g. floppy disks. Besides the PiSCSI/RaSCSI board s2pformat supports drives which are managed by the Linux SG driver on a normal Linux PC. More information is offered in the description of the SCSI-to-USB bridge.
s2p can be managed with the connected computer by SCSI commands. With s2pproto you can use this interface also without a SCSI connection. s2pproto does not send the respective commands with SCSI but with network commands. Thus s2pproto is in particular interesting for developers of remote control tools for s2p. For the Atari there are already such tools.