|
|
@@ -341,7 +341,7 @@ public class SensorMapsActivity extends FragmentActivity implements OnMapReadyCa |
|
|
|
{
|
|
|
|
float distanceToEarthquake;
|
|
|
|
distanceToEarthquake = distance(currentLocation.getLatitude(), currentLocation.getLongitude(), Double.parseDouble(breitengradQuellVibration), Double.parseDouble(laengengradQuellVibration));
|
|
|
|
long wellenAusbreitungsGeschwindigkeit = 4500; //Meter die Sekunde
|
|
|
|
long wellenAusbreitungsGeschwindigkeit = 500; //Meter die Sekunde
|
|
|
|
long delayInSeconds = (long) distanceToEarthquake/wellenAusbreitungsGeschwindigkeit; //s
|
|
|
|
long delayInMilliSeconds = delayInSeconds*1000;
|
|
|
|
setVibrationTimer(delayInMilliSeconds,1500,255,f);
|
|
|
@@ -364,7 +364,7 @@ public class SensorMapsActivity extends FragmentActivity implements OnMapReadyCa |
|
|
|
{
|
|
|
|
float distanceToEarthquake;
|
|
|
|
distanceToEarthquake = distance(currentLocation.getLatitude(), currentLocation.getLongitude(), Double.parseDouble(breitengradQuellVibration), Double.parseDouble(laengengradQuellVibration));
|
|
|
|
long wellenAusbreitungsGeschwindigkeit = 4500; //Meter die Sekunde
|
|
|
|
long wellenAusbreitungsGeschwindigkeit = 500; //Meter die Sekunde
|
|
|
|
long delayInSeconds = (long) distanceToEarthquake/wellenAusbreitungsGeschwindigkeit; //s
|
|
|
|
long delayInMilliSeconds = delayInSeconds*1000;
|
|
|
|
setVibrationTimer(delayInMilliSeconds,1500,255,f);
|
|
|
@@ -498,13 +498,13 @@ public class SensorMapsActivity extends FragmentActivity implements OnMapReadyCa |
|
|
|
{
|
|
|
|
mDatenbank = FirebaseDatabase.getInstance().getReference();
|
|
|
|
mDatenbank.child("overviewnodes").child("IDG" + k).child("a_androidid").setValue(getandroidid());
|
|
|
|
/*
|
|
|
|
|
|
|
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
|
|
|
mDatenbank.child("overviewnodes").child("IDG" + k).child("b_localdatetime").setValue(LocalDateTime.now().toString());
|
|
|
|
//mDatenbank.child("overviewnodes").child("IDG" + k).child("b_localdatetime").setValue(LocalDateTime.now().toString());
|
|
|
|
mDatenbank.child("overviewnodes").child("IDG" + k).child("b_localdatetime").setValue(LocalDateTime.now(ZoneOffset.UTC).toString());
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
*/
|
|
|
|
mDatenbank.child("overviewnodes").child("IDG" + k).child("b_localdatetime").setValue(LocalDateTime.now(ZoneOffset.UTC).toString());
|
|
|
|
mDatenbank.child("overviewnodes").child("IDG" + k).child("c_ip").setValue(getDeviceIpAdress());
|
|
|
|
if (useOwnGPS)
|
|
|
|
{
|