pdrhlik opened a new issue #63:
URL: https://github.com/apache/cordova-plugin-device-orientation/issues/63


   # Bug Report
   
   ## Problem
   When subscribing to a `watchHeading` function, I get a `CompassError {code: 
3}` response. It works on older Android phones. I haven't tested iOS. If I 
browsed the code correctly. The error code is neither one of 
`CompassError.COMPASS_INTERNAL_ERR CompassError.COMPASS_NOT_SUPPORTED`.
   
   ### What is expected to happen?
   It should work.
   
   
   ### What does actually happen?
   I get an undocumented `CompassError`.
   
   
   ## Information
   <!-- Include all relevant information that might help understand and 
reproduce the problem -->
   It doesn't work on Android 10.
   
   
   ### Command or Code
   <!-- What command or code is needed to reproduce the problem? -->
   ```
   import { DeviceOrientation } from '@ionic-native/device-orientation/ngx';
   
   constructor(
       private deviceOrientation: DeviceOrientation
     ) { }
   
   this.compass = this.deviceOrientation.watchHeading({frequency: 
500}).subscribe(data => {
          // logic
   });
   ```
   
   ### Environment, Platform, Device
   <!-- In what environment, on what platform or on which device are you 
experiencing the issue? -->
    I used Angular 11, Ionic framework 5 and Capacitor.
   
   
   ### Version information
   <!-- 
   What are relevant versions you are using?
   For example:
   Cordova: Cordova CLI, Cordova Platforms, Cordova Plugins 
   Other Frameworks: Ionic Framework and CLI version
   Operating System, Android Studio, Xcode etc.
   -->
   `ionic info` output:
   
   ```
   Ionic:
   
      Ionic CLI                     : 6.13.1 
(/usr/local/lib/node_modules/@ionic/cli)
      Ionic Framework               : @ionic/angular 5.6.4
      @angular-devkit/build-angular : 0.1102.8
      @angular-devkit/schematics    : 9.1.0
      @angular/cli                  : 11.2.8
      @ionic/angular-toolkit        : 2.3.3
   
   Capacitor:
   
      Capacitor CLI   : 2.4.7
      @capacitor/core : 2.4.7
   
   Cordova:
   
      Cordova CLI       : 9.0.0 (cordova-lib@9.0.1)
      Cordova Platforms : not available
      Cordova Plugins   : not available
   
   Utility:
   
      cordova-res (update available: 0.15.3) : 0.15.2
      native-run (update available: 1.3.0)   : 1.2.2
   
   System:
   
      Android SDK Tools : 26.1.1 (/Users/datigo/Library/Android/sdk)
      ios-deploy        : 1.10.0
      ios-sim           : ios-sim/9.0.0 darwin-x64 node-v12.18.3
      NodeJS            : v12.18.3 (/usr/local/Cellar/node@12/12.18.3/bin/node)
      npm               : 6.14.6
      OS                : macOS Catalina
      Xcode             : Xcode 12.4 Build version 12D4e
   ```
   
   
   ## Checklist
   <!-- Please check the boxes by putting an x in the [ ] like so: [x] -->
   
   - [x] I searched for existing GitHub issues
   - [x] I updated all Cordova tooling to most recent version
   - [x] I included all the necessary information above
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cordova.apache.org
For additional commands, e-mail: commits-h...@cordova.apache.org

Reply via email to