a lot!!! of changes
added main menu added debug display many debug widgets for plotting live data worked on android live sensors added offline-data sensor feeding some dummy data sensors worked on the map display added ui debug for grid-points, particles and weights added a cool dude to display the estimation added real filtering based on the Indoor components c++11 fixes for android compilation online and offline filtering support new resampling technique for testing map loading via dialog
This commit is contained in:
@@ -40,7 +40,7 @@ public:
|
||||
void handle(const std::string& data) {
|
||||
|
||||
// to-be-constructed sensor data
|
||||
WiFiSensorData sensorData;
|
||||
WiFiMeasurements sensorData;
|
||||
|
||||
// parse each mac->rssi entry
|
||||
for (int i = 0; i < (int)data.length(); i += 17+1+2) {
|
||||
@@ -49,7 +49,7 @@ public:
|
||||
const int8_t pad1 = data[i+18];
|
||||
const int8_t pad2 = data[i+19];
|
||||
if (pad1 != 0 || pad2 != 0) {Debug::error("padding error within WiFi scan result");}
|
||||
sensorData.entries.push_back(WiFiSensorDataEntry(bssid, rssi));
|
||||
sensorData.entries.push_back(WiFiMeasurement(AccessPoint(bssid), rssi));
|
||||
}
|
||||
|
||||
// call listeners
|
||||
@@ -60,20 +60,7 @@ public:
|
||||
};
|
||||
|
||||
|
||||
extern "C" {
|
||||
|
||||
/** called after each successful WiFi scan */
|
||||
JNIEXPORT void JNICALL Java_indoor_java_WiFi_onScanComplete(JNIEnv* env, jobject jobj, jbyteArray arrayID) {
|
||||
(void) env; (void) jobj;
|
||||
jsize length = env->GetArrayLength(arrayID);
|
||||
jboolean isCopy;
|
||||
jbyte* data = env->GetByteArrayElements(arrayID, &isCopy);
|
||||
std::string str((char*)data, length);
|
||||
env->ReleaseByteArrayElements(arrayID, data, JNI_ABORT);
|
||||
WiFiSensorAndroid::get().handle(str);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user