locked
DeviceIOControl and sensors

    Question

  • Is there a way to access the Sensors via DeviceIOControl? I know there is a WinRT API for this, but the API is limitted. I want a way to set the sensitivity value which I can't for Metro app but can for Desktop.

    Tuesday, November 6, 2012 11:26 PM

Answers

  • If you mean DeviceIoControl from a Windows Store Device App, the answer is no. Change sensitivity is only settable from the Sensors Desktop API.

    While there is no direct way to set the change sensitivity from WinRT, when you set the report interval, the WinRT API adjusts the change sensitivity on your behalf. Shorter intervals result in smaller change sensitivities.

    Regards,

    lisa 

    Thursday, November 8, 2012 5:27 PM

All replies

  • If you mean DeviceIoControl from a Windows Store Device App, the answer is no. Change sensitivity is only settable from the Sensors Desktop API.

    While there is no direct way to set the change sensitivity from WinRT, when you set the report interval, the WinRT API adjusts the change sensitivity on your behalf. Shorter intervals result in smaller change sensitivities.

    Regards,

    lisa 

    Thursday, November 8, 2012 5:27 PM
  • Is this to say that there is no extended sensory API available for Windows Store Apps?

    I would also like to do some more complex stuff with sensors (i.e. enumerate over sensors, or choose a specific one).  Is there no way to access a 2nd accelerometer, for example, if there are 2 present?

    And how does GetDefault() enumerate over sensors if there are multiple sensors plugged in?

    Is there any way to access sensors with the ConnectionType set to External, or Attached?

    Friday, November 9, 2012 9:56 PM
  • That's correct, GetDefault() is designed to find the first internally connected sensor for each type of sensor. 

    That said, we are interested in knowing the user scenarios that you are trying to enable from your Windows Store app for enumerating multiple sensors of the same type (e.g. multiple gyrometers, multiple accelerometers, etc). 

    Regards,

    lisa


    Saturday, November 10, 2012 9:13 PM