1SG_GET_CONFIG(8)                   SG3_UTILS                  SG_GET_CONFIG(8)
2
3
4

NAME

6       sg_get_config - sends a SCSI GET CONFIGURATION command
7

SYNOPSIS

9       sg_get_config  [--brief]  [--current]  [--help]  [--hex]  [--inner-hex]
10       [--list] [--rt=RT] [--starting=FC] [--verbose] [--version] DEVICE
11

DESCRIPTION

13       Sends a SCSI GET  CONFIGURATION  command  to  DEVICE  and  decodes  the
14       response.  The  response  includes  the  features  and  profiles of the
15       device.  Typically these devices are CD and DVD players that  may  (but
16       not  necessarily)  have  media  in them. These devices may well be con‐
17       nected via ATAPI, USB or IEEE 1394 transports. In such cases  they  are
18       "SCSI"  devices  only  in the sense that they use the "Multi-Media com‐
19       mand" set (MMC).  MMC is a specialized SCSI command set  whose  defini‐
20       tion can be found at http://www.t10.org .
21
22       This  utility is based on the MMC-4 and MMC-5 draft standards. See sec‐
23       tion 5 on "Features and  Profile  for  Multi_Media  devices"  for  more
24       information  on  specific feature parameters and profiles. The manufac‐
25       turer's product manual may also be useful.
26
27       Since modern DVD  writers  support  many  features  and  profiles,  the
28       decoded  output  from this utility can be large. There are various ways
29       to cut down the output. If the --brief option is used only the  feature
30       names  are  shown  and the feature parameters are not decoded. Alterna‐
31       tively if only one feature is of  interest  then  this  combination  of
32       options  is appropriate: "--rt=2 --starting=FC". Another possibility is
33       to show only the features that are relevant to the media in  the  drive
34       (i.e. "current") with the "--rt=1" option.
35

OPTIONS

37       Arguments to long options are mandatory for short options as well.
38
39       -b, --brief
40              show  the feature names but don't decode the parameters of those
41              features.  When used with --list outputs known feature names but
42              not known profile names.
43
44       -c, --current
45              output  features marked as current. This option is equivalent to
46              '--rt=1'.
47
48       -h, --help
49              output the usage message then exit.
50
51       -H, --hex
52              output the response in hex (don't decode response).
53
54       -i, --inner-hex
55              decode to the feature name level then output each feature's data
56              in hex.
57
58       -l, --list
59              list all known feature and profile names. Ignore the device name
60              (if given).  Simply lists the feature names and  profiles  (fol‐
61              lowed  by  their  hex  values) that this utility knows about. If
62              --brief is also given then only feature names are listed.
63
64       -r, --rt=RT
65              where RT is the field of that name in the GET CONFIGURATION cdb.
66              Allowable  values  are 0, 1, 2, or 3 . The command's action also
67              depends on the value given  to  the  --starting=FC  option.  The
68              default  value is 0.  When RT is 0 then all features, regardless
69              of currency, are returned (whose feature code is greater than or
70              equal to FC given to --starting=). When RT is 1 then all current
71              features are returned (whose feature code  is  greater  than  or
72              equal  to  FC). When RT is 2 then the feature whose feature code
73              is equal to FC, if any, is returned.  When RT is 3 the  response
74              is reserved (probably yields an "illegal field in cdb" error).
75
76       -s, --starting=FC
77              where  FC  is  the feature code value. This option works closely
78              with the --rt=RT option. The FC value is in the range 0 to 65535
79              (0xffff)  inclusive.  Its  default  value is 0. A value prefixed
80              with "0x" (or a trailing 'h') is interpreted as hexadecimal.
81
82       -v, --verbose
83              increase the level of verbosity, (i.e. debug output).
84
85       -V, --version
86              print the version string and then exit.
87

NOTES

89       There are multiple versions of the MMC (draft) standards:  MMC  [1997],
90       MMC-2  [2000],   MMC-3 [2002], MMC-4 and MMC-5. The first three are now
91       ANSI INCITS standards with the year  they  became  standards  shown  in
92       brackets.  The  draft immediately prior to standardization can be found
93       at http://www.t10.org . In the initial MMC standard there  was  no  GET
94       CONFIGURATION  command  and  the relevant information was obtained from
95       the "CD capabilities and mechanical status mode page" (mode page 0x2a).
96       It  was  later  renamed the "MM capabilities and mechanical status mode
97       page" and has been made obsolete in MMC-4 and MMC-5. The GET CONFIGURA‐
98       TION  command  was introduced in MMC-2 and has become a replacement for
99       that mode page. New features such as support for "BD" (blue ray)  media
100       type  can  only  be found by using the GET CONFIGURATION command. Hence
101       older CD players may not support the GET CONFIGURATION command in which
102       case  the  "MM  capabilities ..."  mode page can be checked with sdpar,
103       sginfo or sg_modes.
104
105       In the 2.4 series of Linux kernels the DEVICE must be  a  SCSI  generic
106       (sg) device. In the 2.6 series block devices can also be specified. For
107       example "sg_get_config /dev/hdc" will work in the 2.6 series kernels as
108       long  as  /dev/hdc  is  an ATAPI device. In the 2.6 series external DVD
109       writers  attached  via  USB  could  be  queried   with   "sg_get_config
110       /dev/scd1" for example.
111

EXIT STATUS

113       The  exit status of sg_get_config is 0 when it is successful. Otherwise
114       see the sg3_utils(8) man page.
115

AUTHORS

117       Written by Douglas Gilbert.
118

REPORTING BUGS

120       Report bugs to <dgilbert at interlog dot com>.
121
123       Copyright © 2004-2007 Douglas Gilbert
124       This software is distributed under a FreeBSD license. There is NO  war‐
125       ranty;  not  even  for MERCHANTABILITY or FITNESS FOR A PARTICULAR PUR‐
126       POSE.
127

SEE ALSO

129       sginfo, sg_modes, sg_inq,  sg_prevent,  sg_start  (all  in  sg3_utils),
130       sdparm
131
132
133
134sg3_utils-1.23                   January 2007                 SG_GET_CONFIG(8)
Impressum