Skip to content

Commit

Permalink
Update manpages
Browse files Browse the repository at this point in the history
  • Loading branch information
uweseimet committed Dec 12, 2023
1 parent 39bfaaf commit fe8b239
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 46 deletions.
31 changes: 14 additions & 17 deletions doc/s2p.1
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ s2p \- Emulates SCSI and SASI devices with the Raspberry Pi
[\fB\-HDn[:u]\fR \fIFILE\fR]...
.SH DESCRIPTION
.B s2p
emulates SCSI devices using the Raspberry Pi GPIO pins.
emulates SCSI devices with the Raspberry Pi.
.PP
In the arguments to SCSI2Pi, one or more SCSI (-IDn[:u]) devices can be specified.
In the arguments to s2p one or more SCSI (-IDn[:u]) devices can be specified.
The number (n) after the ID or HD identifier specifies the ID number for that device. The optional number (u) specifies the LUN (logical unit) for that device. The default LUN is 0.
For SCSI: The ID is limited from 0-7. However, typically SCSI ID 7 is reserved for the "initiator" (the host computer). The LUN is limited from 0-31.
.PP
SCSI2Pi will determine the type of device based upon the file extension of the FILE argument.
s2p will determine the type of device based upon the file extension of the FILE argument.
hd1: SCSI Hard Disk image (generic, non-removable, SCSI-1)
hds: SCSI Hard Disk image (generic, non-removable)
hdr: SCSI Hard Disk image (generic, removable)
Expand All @@ -39,13 +39,10 @@ SCSI2Pi will determine the type of device based upon the file extension of the F
For example, if you want to specify an Apple-compatible HD image on ID 0, you can use the following command:
sudo s2p -ID0 /path/to/drive/hdimage.hda

Note: SCSI2Pi is a fork of RaSCSI. The two cannot be run in parallel on the same system.
When s2p starts it opens a socket (default port is 6868) to allow external management commands.
If another process is using this port, s2p will terminate. Once s2p has initialized, the s2pctl utility can be used to send commands.

Once SCSI2Pi starts, it will open a socket (default port is 6868) to allow external management commands.
If another process is using this port, SCSI2Pi will terminate, since it is likely another instance of SCSI2Pi or RaSCSI.
Once SCSI2Pi has initialized, the scsictl utility can be used to send commands.

To quit SCSI2Pi, press Control + C. If it is running in the background, you can kill it using an INT signal.
To quit s2p press Control-C. If it is running in the background, you can kill it using an INT signal.

.SH OPTIONS
.TP
Expand Down Expand Up @@ -93,22 +90,22 @@ FILE is the name of the image file to use for the SCSI device.
.IP

.SH EXAMPLES
Launch SCSI2Pi with no emulated drives attached:
Launch s2p with no emulated drives attached:
s2p

Launch SCSI2Pi with an Apple hard drive image as ID 0 and a CD-ROM as ID 2
s2p -ID0 /path/to/harddrive.hda -ID2 /path/to/cdimage.iso
Launch s2p with an Apple hard drive image as ID 0 and a CD-ROM as ID 2
s2p -ID0 /path/to/harddrive.hda -id2 /path/to/cdimage.iso

Launch SCSI2Pi with a removable SCSI drive image as ID 0 and the raw device file /dev/hdb (e.g. a USB stick) and a DaynaPort network adapter as ID 6:
s2p -ID0 -t scrm /dev/hdb -ID6 -t scdp daynaport
Launch s2p with a removable SCSI drive image as ID 0 and the raw device file /dev/hdb (e.g. a USB stick) and a DaynaPort network adapter as ID 6:
s2p -id0 -t scrm /dev/hdb -id6 -t scdp daynaport

To create an empty, 100MiB HD image, use the following command:
To create an empty 100MiB HD image, use the following command:
dd if=/dev/zero of=/path/to/newimage.hda bs=512 count=204800

In case the fallocate command is available a much faster alternative to the dd command is:
fallocate -l 104857600 /path/to/newimage.hda

.SH SEE ALSO
scsictl(1), scsiexec(1), scsidump(1)
s2pctl(1), s2pexec(1), s2pdump(1)

Full documentation is available at: <https://www.s2p.com>
Full documentation is available at: <https://www.scsi2pi.net>
16 changes: 8 additions & 8 deletions doc/s2pctl.1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.TH s2p 1
.SH NAME
scsictl \- Sends management commands to the s2p process
s2pctl \- Sends management commands to the s2p process
.SH SYNOPSIS
.B scsictl
\fB\-e\fR |
Expand Down Expand Up @@ -38,12 +38,12 @@ scsictl \- Sends management commands to the s2p process
[\fB\-x\fR \fICURRENT_NAME:NEW_NAME\fR] |
[\fB\-z\fR \fILOCALE\fR]
.SH DESCRIPTION
.B scsictl
.B s2pctl
sends commands to the s2p process to make configuration adjustments at runtime or to check the status of the devices.

Either the -i or -l option should be specified at one time. Not both.

You do NOT need root privileges to use scsictl. scsictl also runs on non-Pi Linux platforms.
You do NOT need root privileges to use s2pctl. s2pctl also runs on non-Pi Linux platforms.

Note: The command and type arguments are case insensitive. Only the first letter of the command/type is evaluated by the tool.

Expand Down Expand Up @@ -113,7 +113,7 @@ Display all device types and their properties.
Display the s2p server version.
.TP
.BR \-V\fI " " \fI
Display the scsictl version.
Display the s2pctl version.
.TP
.BR \-X\fI " " \fI
Shut down the s2p process.
Expand Down Expand Up @@ -176,7 +176,7 @@ Unit number (0-31). This will default to 0. This option is only used when there

.SH EXAMPLES
Show a listing of all of the SCSI devices and their current status.
scsictl -l
s2pctl -l


Example output:
Expand All @@ -187,9 +187,9 @@ Example output:
+----+-----+------+-------------------------------------

Request the SCSI2Pi process to attach a disk (assumed) to SCSI ID 0 with the contents of the file system image "HDIIMAGE0.HDS".
scsictl -i 0 -f HDIIMAGE0.HDS
s2pctl -i 0 -f HDIIMAGE0.HDS

.SH SEE ALSO
s2p(1), scsiexec(1), scsidump(1)
s2p(1), s2pexec(1), s2pdump(1)

Full documentation is available at: <https://www.s2p.com>
Full documentation is available at: <https://www.scsi2pi.net>
28 changes: 14 additions & 14 deletions doc/s2pdump.1
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
.TH scsidump 1
.TH s2odump 1
.SH NAME
scsidump \- SCSI disk dumping tool for SCSI2Pi
s2pdump \- SCSI disk dumping tool for SCSI2Pi
.SH SYNOPSIS
.B scsidump
.B s2pdump
\fB\-t\fR \fIID[:LUN]\fR
[\fB\-i\fR \fIBID\fR]
\fB\-f\fR \fIFILE\fR
Expand All @@ -13,17 +13,17 @@ scsidump \- SCSI disk dumping tool for SCSI2Pi
[\fB\-I\fR] ID[:LUN]
[\fB\-S\fR]
.SH DESCRIPTION
.B scsidump
.B s2pdump
has two modes of operation: dump and restore. These can be used with physical storage media, including hard drives and magneto optical drives. Dump mode can be used with read-only media such as CD/DVD drives.

When operating in dump mode, scsidump will copy all data from a remote SCSI drive to an image on the local filesystem. If enabled, it will also generate a .properties file that can be used to more closely emulate the source drive.
When operating in dump mode, s2pdump will copy all data from a remote SCSI drive to an image on the local filesystem. If enabled, it will also generate a .properties file that can be used to more closely emulate the source drive.

If you are operating in restore mode, scsidump will copy the data from a local binary image to a remote physical SCSI drive. The remote SCSI drive MUST be writable.
If you are operating in restore mode, s2pdump will copy the data from a local binary image to a remote physical SCSI drive. The remote SCSI drive MUST be writable.

.SH NOTES

.B scsidump
requires either a direct connection (one without transceivers) or a FULLSPEC SCSI2Pi/RaSCSI board.
.B s2pdump
requires either a direct connection (one without transceivers) or a FULLSPEC PiSCSI/RaSCSI board.

If the generated drive image is intended to be used with SCSI2Pi, the drive image should be moved by the user to ~/images (or the location specified to the s2p service).

Expand Down Expand Up @@ -58,14 +58,14 @@ Scan SCSI bus for devices.

.SH EXAMPLES
Dump Mode: [SCSI Drive] ---> [SCSI2Pi host]
Launch scsidump to dump an all data from SCSI ID 3 with block size 64 KiB, store it to the local filesystem as a drive image named outimage.hda, and generate the outimage.hda.properties file with the drive's INQUIRY information:
scsidump -t 3 -f ./outimage.hda -s 65536 -p
Launch s2pdump to dump an all data from SCSI ID 3 with block size 64 KiB, store it to the local filesystem as a drive image named outimage.hda, and generate the outimage.hda.properties file with the drive's INQUIRY information:
s2pdump -t 3 -f ./outimage.hda -s 65536 -p

Restore Mode: [SCSI2Pi host] ---> [SCSI Drive]
Launch scsidump to restore/upload a drive image from the local file system to SCSI ID 0 with block size 1MiB:
scsidump -r -t 0 -f ./outimage.hda -s 1048576
Launch s2pdump to restore/upload a drive image from the local file system to SCSI ID 0 with block size 1MiB:
s2pdump -r -t 0 -f ./outimage.hda -s 1048576

.SH SEE ALSO
scsictl(1), s2p(1), scsiexec(1)
s2pctl(1), s2p(1), s2pexec(1)

Full documentation is available at: <https://www.s2p.com>
Full documentation is available at: <https://www.scsi2pi.net>
14 changes: 7 additions & 7 deletions doc/s2pexec.1
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.TH scsiexec 1
.SH NAME
scsiexec \- SCSI command execution tool for SCSI2Pi
s2pexec \- SCSI command execution tool for SCSI2Pi
.SH SYNOPSIS
.B scsiexec
\fB\-t\fR \fIID[:LUN]\fR
Expand All @@ -14,18 +14,18 @@ scsiexec \- SCSI command execution tool for SCSI2Pi
[\fB\-L\fR \fILOG_LEVEL\fR]
[\fB\-X\fR]
.SH DESCRIPTION
.B scsiexec
.B s2pexec
wraps protobuf input data into a custom SCSI2Pi SCSI command, has s2p execute it and display the results. The input data must be a legal command for the SCSI2Pi protobuf interface. See the file s2p_interface.proto for details.

.SH NOTES

.B scsiexec
helps with advanced testing. It requires two connected SCSI2Pi boards. The board scsiexec is running on must be a FULLSPEC board because scsiexec requires SCSI initiator mode support.
.B s2pexec
helps with advanced testing. It requires two connected SCSI2Pi boards. The board s2pexec is running on must be a FULLSPEC board because s2pexec requires SCSI initiator mode support.

.SH OPTIONS
.TP
.BR \-t\fI " "\fIID[:LUN]
SCSI ID and optional LUN of the second SCSI2Pi board. The remote SCSI device will be functioning as the "Target" device.
SCSI ID and optional LUN of the second RaSCSI/PiSCSI board. The remote SCSI device will be functioning as the target device.
.TP
.BR \-i\fI " "\fIBID
SCSI ID of the SCSI2Pi device. If not specified, the SCSI2Pi device will use ID 7. The SCSI2Pi host will be functioning as the "Initiator" device.
Expand All @@ -52,6 +52,6 @@ Set the log level (trace, debug, info, warning, error, off). The default log lev
Shut down s2p with a SCSI command.

.SH SEE ALSO
scsictl(1), s2p(1), scsidump(1), scsiexec(1)
s2pctl(1), s2p(1), s2pdump(1)

Full documentation is available at: <https://www.s2p.com>
Full documentation is available at: <https://www.scsi2pi.net>

0 comments on commit fe8b239

Please sign in to comment.