fix: Upgrade react-native-ble-plx to v3.5.1 to fix disconnect crash#23
Merged
Conversation
- Standalone sketch for testing EMG Click on Serial Monitor/Plotter - 4 display modes: raw ADC, calibrated mV, centered, filtered - Auto-calibrates baseline at startup - Live stats every 2s (min, max, mean, RMS, peak-to-peak) - Interactive commands via Serial: switch modes, recalibrate, pause - Uses same ADC config and IIR filter as main firmware
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
react-native-ble-plxfrom3.5.0to3.5.1to fix a fatal crash on BLE disconnectonErrorcallbacks in the native Android module passingnullas the error code toPromiseImpl.reject(), which requires a non-nullcodeparameterRoot Cause
java.lang.NullPointerException: Parameter specified as non-null is null: method com.facebook.react.bridge.PromiseImpl.reject, parameter codeEvery
safePromise.reject(null, errorConverter.toJs(error))inBlePlxModule.java(17 occurrences) triggered a fatal NPE when the BLE device disconnected, the transaction was cancelled, or any BLE error occurred.Fix
v3.5.1 includes PR dotintent#1329 which replaces
nullwithgetErrorCode(error)— a proper error code string.Related Issues
Note
This is a native module change — requires
npx expo prebuild --cleanand dev client rebuild after merging.