| Top |
net.hadess.SensorProxy.Compassnet.hadess.SensorProxy.Compass — D-Bus proxy to access Compass sensors |
Methods
ClaimCompass (); ReleaseCompass ();
Description
After checking the availability of the sensor type you want to monitor, call the net.hadess.SensorProxy.ClaimCompass() method to start updating the properties from the hardware readings.
The object path will be "/net/hadess/SensorProxy/Compass".
Method Details
The ClaimCompass() method
ClaimCompass ();
To start receiving compass heading updates from the proxy, the application must call the net.hadess.SensorProxy.ClaimCompass() method. It can do so whether a compass is available or not, updates would then be sent when such a sensor appears.
Applications should call net.hadess.SensorProxy.ReleaseCompass() when readings are not required anymore. This prevents the sensor proxy from polling the device, thus increasing wake-ups and reducing battery life.
Note that Compass information is only available to Geoclue by default, which will proxy the magnetic heading information, and transform it to True North heading.
