-
Notifications
You must be signed in to change notification settings - Fork 4
DEV-852 #287
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
Merged
DEV-852 #287
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
8286cf9
update
JongChern 74eb3a2
Update SensorMapsExample.java
JongChern 4bdd239
minor change to test the new bmp, will revert
JongChern 6756c0c
update
JongChern c01a71d
Update ShimmerObject.java
JongChern 3b3d5cc
Update SensorBMP581.java
JongChern 041ffb1
Merge branch 'master' into DEV-852
JongChern 8ea0d56
Merge branch 'master' into DEV-852
JongChern 770d3ac
Potential fix for pull request finding
JongChern 7f7ffaf
Potential fix for pull request finding
JongChern File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
49 changes: 49 additions & 0 deletions
49
ShimmerDriver/src/main/java/com/shimmerresearch/sensors/bmpX80/CalibDetailsBmp581.java
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| package com.shimmerresearch.sensors.bmpX80; | ||
|
|
||
| import com.shimmerresearch.driver.calibration.CalibDetails.CALIB_READ_SOURCE; | ||
|
|
||
| /** | ||
| * BMP581 streams already-compensated values, so there are no per-device trim | ||
| * coefficients to parse or store (unlike BMP180/BMP280/BMP390). This CalibDetails | ||
| * is therefore a pass-through scaler: | ||
| * <li> pressure = raw / 64 -> Pa | ||
| * <li> temperature = raw / 65536 -> deg C | ||
| * (see BST-BMP581-DS004). | ||
| * | ||
| * @author Shimmer | ||
| */ | ||
| public class CalibDetailsBmp581 extends CalibDetailsBmpX80 { | ||
|
|
||
| private static final long serialVersionUID = 8046182982777461001L; | ||
|
|
||
| public String mSensorMacID; | ||
|
|
||
| public CalibDetailsBmp581(String mMacIdFromUart) { | ||
| mSensorMacID = mMacIdFromUart; | ||
| } | ||
|
|
||
| @Override | ||
| public double[] calibratePressureSensorData(double UP, double UT) { | ||
| double[] caldata = new double[2]; | ||
| caldata[0] = UP / 64.0; // Pa (downstream /1000 -> kPa, same as BMP390 legacy path) | ||
| caldata[1] = UT / 65536.0; // deg C | ||
| return caldata; | ||
| } | ||
|
|
||
| @Override | ||
| public byte[] generateCalParamByteArray() { | ||
| // No coefficients on BMP581. | ||
| return null; | ||
| } | ||
|
|
||
| @Override | ||
| public void parseCalParamByteArray(byte[] bufferCalibrationParameters, CALIB_READ_SOURCE calibReadSource) { | ||
| // No-op: BMP581 self-compensates; no coefficient block exists. | ||
| } | ||
|
|
||
| @Override | ||
| public void resetToDefaultParameters() { | ||
| // No calibration state to reset. | ||
| } | ||
|
|
||
| } |
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.