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