1*1031c584SApple OSS Distributions<h2>device_get_status</h2> 2*1031c584SApple OSS Distributions<hr> 3*1031c584SApple OSS Distributions<p> 4*1031c584SApple OSS Distributions<strong>Function</strong> - Return the current device status. 5*1031c584SApple OSS Distributions<h3>SYNOPSIS</h3> 6*1031c584SApple OSS Distributions<pre> 7*1031c584SApple OSS Distributions<strong>#include< device/device.h></strong> 8*1031c584SApple OSS Distributions 9*1031c584SApple OSS Distributions<strong>kern_return_t device_get_status</strong> 10*1031c584SApple OSS Distributions <strong>(mach_port_t</strong> <var>device</var>, 11*1031c584SApple OSS Distributions <strong>dev_flavor_t</strong> <var>flavor</var>, 12*1031c584SApple OSS Distributions <strong>dev_status_t</strong> <var>status</var>, 13*1031c584SApple OSS Distributions <strong>mach_msg_type_number_t</strong> <var>*status_count</var><strong>);</strong> 14*1031c584SApple OSS Distributions</pre> 15*1031c584SApple OSS Distributions<h3>PARAMETERS</h3> 16*1031c584SApple OSS Distributions<dl> 17*1031c584SApple OSS Distributions<p> 18*1031c584SApple OSS Distributions<dt> <var>device</var> 19*1031c584SApple OSS Distributions<dd> 20*1031c584SApple OSS Distributions[in device send right] 21*1031c584SApple OSS DistributionsA device port to the device to be interrogated. 22*1031c584SApple OSS Distributions<p> 23*1031c584SApple OSS Distributions<dt> <var>flavor</var> 24*1031c584SApple OSS Distributions<dd> 25*1031c584SApple OSS Distributions[in scalar] 26*1031c584SApple OSS DistributionsThe type of status information requested. 27*1031c584SApple OSS Distributions<p> 28*1031c584SApple OSS Distributions<dt> <var>status</var> 29*1031c584SApple OSS Distributions<dd> 30*1031c584SApple OSS Distributions[out array of natural-sized units] 31*1031c584SApple OSS DistributionsThe returned device status. 32*1031c584SApple OSS Distributions<p> 33*1031c584SApple OSS Distributions<dt> <var>status_count</var> 34*1031c584SApple OSS Distributions<dd> 35*1031c584SApple OSS Distributions[pointer to in/out scalar] 36*1031c584SApple OSS DistributionsOn input, the reserved size of <var>status</var>; on 37*1031c584SApple OSS Distributionsoutput, the size of the returned device status (in natural-sized units). 38*1031c584SApple OSS Distributions</dl> 39*1031c584SApple OSS Distributions<h3>DESCRIPTION</h3> 40*1031c584SApple OSS Distributions<p> 41*1031c584SApple OSS DistributionsThe <strong>device_get_status</strong> function returns status information 42*1031c584SApple OSS Distributionspertaining to an open device. The possible values for <var>flavor</var> as well 43*1031c584SApple OSS Distributionsas the meaning of the returned status information is device dependent. 44*1031c584SApple OSS Distributions<h3>RETURN VALUES</h3> 45*1031c584SApple OSS Distributions<dl> 46*1031c584SApple OSS Distributions<p> 47*1031c584SApple OSS Distributions<dt> <strong>D_DEVICE_DOWN</strong> 48*1031c584SApple OSS Distributions<dd> 49*1031c584SApple OSS DistributionsDevice has been shut down 50*1031c584SApple OSS Distributions<p> 51*1031c584SApple OSS Distributions<dt> <strong>D_NO_SUCH_DEVICE</strong> 52*1031c584SApple OSS Distributions<dd> 53*1031c584SApple OSS DistributionsNo device with that name, or the device is not operational. 54*1031c584SApple OSS Distributions<p> 55*1031c584SApple OSS Distributions<dt> <strong>D_OUT_OF_BAND</strong> 56*1031c584SApple OSS Distributions<dd> 57*1031c584SApple OSS DistributionsOut-of-band condition occurred on device (such as typing \*L<Ctrl>-C\*O) 58*1031c584SApple OSS Distributions</dl> 59*1031c584SApple OSS Distributions<h3>RELATED INFORMATION</h3> 60*1031c584SApple OSS Distributions<p> 61*1031c584SApple OSS DistributionsFunctions: 62*1031c584SApple OSS Distributions<a href="device_set_status.html"><strong>device_set_status</strong></a>. 63