Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[carp_audio_package] error in iOS when app in background #212

Open
sc00n opened this issue Sep 17, 2021 · 0 comments
Open

[carp_audio_package] error in iOS when app in background #212

sc00n opened this issue Sep 17, 2021 · 0 comments

Comments

@sc00n
Copy link
Contributor

sc00n commented Sep 17, 2021

I get an error when I use AudioSamplingPackage.NOISE from carp_audio_package 0.30.1 in my sampling scheme.

The app runs fine when in foreground. When the app is in background, I get the following error after a while:

flutter: [CAMS DEBUG] Writing data point to file - type: dk.cachet.carp.activity
[aurioc] AURemoteIO.cpp:1600:Start: AUIOClient_StartIO failed (561145187)
[avae]            AVAEInternal.h:109   [AVAudioEngineGraph.mm:1545:Start: (err = PerformCommand(*ioNode, kAUStartIO, NULL, 0)): error 561145187
audio_streamer/SwiftAudioStreamerPlugin.swift:82: Fatal error: 'try!' expression unexpectedly raised an error: Error Domain=com.apple.coreaudio.avfaudio Code=561145187 "(null)" UserInfo={failed call=err = PerformCommand(*ioNode, kAUStartIO, NULL, 0)}
audio_streamer/SwiftAudioStreamerPlugin.swift:82: Fatal error: 'try!' expression unexpectedly raised an error: Error Domain=com.apple.coreaudio.avfaudio Code=561145187 "(null)" UserInfo={failed call=err = PerformCommand(*ioNode, kAUStartIO, NULL, 0)}
* thread #1, queue = 'com.apple.main-thread', stop reason = Fatal error: 'try!' expression unexpectedly raised an error: Error Domain=com.apple.coreaudio.avfaudio Code=561145187 "(null)" UserInfo={failed call=err = PerformCommand(*ioNode, kAUStartIO, NULL, 0)}
    frame #0: 0x000000019ca0eeac libswiftCore.dylib`_swift_runtime_on_report
libswiftCore.dylib`_swift_runtime_on_report:
->  0x19ca0eeac <+0>: ret    
libswiftCore.dylib`_swift_reportToDebugger:
    0x19ca0eeb0 <+0>: b      0x19ca0eeac               ; _swift_runtime_on_report
libswiftCore.dylib`_swift_shouldReportFatalErrorsToDebugger:
    0x19ca0eeb4 <+0>: adrp   x8, 337468
    0x19ca0eeb8 <+4>: ldrb   w0, [x8, #0x299]

After this error, the app stops. When I only use other CARP packages (e.g. from context, device and sensor), the app keeps working, also in background.

I added everything to plist that should be there according to carp_audio_package.

Thank you for your help!

flutter doctor -v
[✓] Flutter (Channel stable, 2.2.1, on macOS 11.5.2 20G95 darwin-x64, locale en-BE)
    • Flutter version 2.2.1 at /Users/app/flutter
    • Framework revision 02c026b03c (4 months ago), 2021-05-27 12:24:44 -0700
    • Engine revision 0fdb562ac8
    • Dart version 2.13.1

[!] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
    • Android SDK at /Users/merijnmestdagh/Library/Android/sdk
    • Platform android-30, build-tools 29.0.3
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/macos#android-setup for more details.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.5.1, Build version 12E507
    • CocoaPods version 1.10.1

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)

[✓] Connected device (2 available)
    • Merijn’s iPhone (mobile) • 00008020-0009601E1199002E • ios            • iOS 14.8
    • Chrome (web)             • chrome                    • web-javascript • Google Chrome 93.0.4577.82

@sc00n sc00n changed the title [carp_audio_package] error in iOS when screen is off [carp_audio_package] error in iOS when app in background Sep 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant