Browse Source

Pre-AlphaV5

EpiTest
Raz492 2 years ago
parent
commit
e9c0ddb711

+ 13
- 0
app/src/main/java/de/edotzlaff/detection/EarthquakeLocation.java View File

}); });
} }


public void privideDBforDeviceMaping(DataSnapshot data, int i)
{
String localedatetime;
String breitengrad;
String laengengrad;
String timestamp;
localedatetime = data.child("IDG" + i).child("b_localdatetime").getValue().toString();
breitengrad = data.child("IDG" + i).child("d_breitengrad").getValue().toString();
laengengrad = data.child("IDG" + i).child("e_laengengrad").getValue().toString();
timestamp = data.child("IDG" + i).child("h_timestamp").getValue().toString();
}


//################################################################## ^^^^ DB Code ^^^^ ################################################################################### //################################################################## ^^^^ DB Code ^^^^ ###################################################################################
//########################################################################################################################################################################## //##########################################################################################################################################################################



+ 2
- 2
app/src/main/java/de/edotzlaff/detection/MainActivity.java View File



private void earthquakeDetected() private void earthquakeDetected()
{ {
Toast.makeText(getApplicationContext(), "!Earthquake detected!", Toast.LENGTH_SHORT).show();
Toast.makeText(getApplicationContext(), "Earthquake detected", Toast.LENGTH_SHORT).show();
Log.d(TAG,"!Earthquake detected!"); Log.d(TAG,"!Earthquake detected!");
//Hier wird bei Vibration in Db geschrieben
//Hier wird bei Vibration in DB geschrieben
getDataBaseValuesNoListenerForVibration(); getDataBaseValuesNoListenerForVibration();
Button buttonReadyToDetect = (Button) findViewById(R.id.buttonReadyToDetect); Button buttonReadyToDetect = (Button) findViewById(R.id.buttonReadyToDetect);
buttonReadyToDetect.setEnabled(true); buttonReadyToDetect.setEnabled(true);

Loading…
Cancel
Save