Fixed issue where web server would send data to the analysis routines even if data source is not set to Garmin, causing conflicts with the selected data source.
This commit is contained in:
13
RELEASE_NOTES.md
Normal file
13
RELEASE_NOTES.md
Normal file
@@ -0,0 +1,13 @@
|
||||
OpenSeizureDetector Android App - RELEASE NOTES
|
||||
==============================================
|
||||
|
||||
Version 4.0.0
|
||||
- Logs all seizure detector data to local database
|
||||
- Adds 'Data Sharing' functionality to upload data to remote database and edit events to say if they are false alarms or genuine seizures
|
||||
- Settings screens tidied up (removed some unnecessary options to simplify settings)
|
||||
- Added check of whether the App is being 'Optimised' for battery usage by the Android System
|
||||
- Fixed problem where the web server receiving data will send it to the analysis routines, even if the data source is not set to Garmin.
|
||||
- for example if you set the data source to phone, but ran OSD on a garmin watch, the data would oscillate between phone and watch
|
||||
data
|
||||
-
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
package="uk.org.openseizuredetector"
|
||||
android:versionCode="92"
|
||||
android:versionName="4.0.0i">
|
||||
android:versionName="4.0.0j">
|
||||
<!-- android:allowBackup="false" -->
|
||||
<uses-permission android:name="android.permission.BLUETOOTH" />
|
||||
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
|
||||
|
||||
@@ -104,13 +104,18 @@ public class SdWebServer extends NanoHTTPD {
|
||||
Log.v(TAG, " files=" + files.toString());
|
||||
String postData = files.get("postData");
|
||||
Log.v(TAG, " postData=" + postData);
|
||||
// Send the data to the SdDataSource so the app can pick it up.
|
||||
if (parameters.get("dataObj") != null) {
|
||||
Log.v(TAG,"passing parameters to data source");
|
||||
answer = mSdServer.mSdDataSource.updateFromJSON(parameters.get("dataObj").toString());
|
||||
if (mSdServer.mSdDataSourceName.equals("Garmin")) {
|
||||
// Send the data to the SdDataSource so the app can pick it up.
|
||||
if (parameters.get("dataObj") != null) {
|
||||
Log.v(TAG, "passing parameters to data source");
|
||||
answer = mSdServer.mSdDataSource.updateFromJSON(parameters.get("dataObj").toString());
|
||||
} else {
|
||||
Log.v(TAG, "Passing postData to data source");
|
||||
answer = mSdServer.mSdDataSource.updateFromJSON(files.get("postData"));
|
||||
}
|
||||
} else {
|
||||
Log.v(TAG,"Passing postData to data source");
|
||||
answer = mSdServer.mSdDataSource.updateFromJSON(files.get("postData"));
|
||||
Log.i(TAG,"Web server received data, but datasource is not set to 'Garmin' - Ignoring");
|
||||
mUtil.showToast("Web server received data, but datasource is not set to 'Garmin' - Ignoring");
|
||||
}
|
||||
break;
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user