Browse Source

Update README.md

Anirban Chakraborty 3 years ago
parent
commit
ecd51d8056
1 changed files with 27 additions and 24 deletions
  1. 27 24
      README.md

+ 27 - 24
README.md

@@ -1,6 +1,6 @@
-# HeliosSmartEnvironments: Organic Social Graph (T4.7)
+# HeliosSmartEnvironments: Organic Social Graph (T 4.7)
 
-An important use case of the Helios project is making meaningful social connections among people. Considering mobile devices as the representatives of the users, it may be possible to learn the pattern of a user's daily activities based on the data generated by a number of sensors (such as Accelerometer, Gyroscope, Barometer, Ambient light sensor, Rotation etc.) present on the user's mobile device.
+An important use case of the [Helios](https://helios-h2020.eu/) project is making meaningful social connections among people. Considering mobile devices as the representatives of the users, it may be possible to learn the pattern of a user's daily activities based on the data generated by a number of sensors (such as Accelerometer, Gyroscope, Barometer, Ambient light sensor, Rotation etc.) present on the user's mobile device.
 
 This Android project implements the concept of an organic social graph based on mobile phone sensors. In particular we make use of Bluetooth to find all the Bluetooth devices in close proximity.
 
@@ -8,7 +8,9 @@ This Android project implements the concept of an organic social graph based on
 
 The app installed in a mobile device keeps track of all nearby Bluetooth devices. The app automatically sends a connection request to another mobile device if they frequently appear in each other's close proximity. Once the connection request is accepted, two users become friends and they make a social graph of two nodes. We call this an organic social graph, which keeps expanding over time.
 
-The users who frequently appear in each other’s close proximity (e.g. in a cafe, in office, or in a movie hall) may have a similar activity pattern, and may be interested to connect to each other. This module provides the initial structure of a social graph which can be used for further research in creating more meaningful, and personalized connections by learning users' interests, and other contextual information such as time, location, purpose etc.
+The users who frequently appear in each other’s close proximity (e.g. in a cafe, in office, or in a movie hall) may have a similar activity pattern, and may be interested to connect to each other.
+This implementation provides the initial structure of a social graph which may be used for further research in creating more meaningful, and personalized connections by learning users' interests, and other contextual information such as time, location, purpose etc.
+This project can be used either as a stand-alone application (APK) or as a library (AAR). More information on how to create a library module (AAR), and how to use that module as a dependency, can be found [here](https://developer.android.com/studio/projects/android-library).
 
 # Implementing an Organic Social Network based on Bluetooth
 
@@ -38,7 +40,7 @@ private final BroadcastReceiver bluetoothStateBroadcastReceiver = new BroadcastR
 };
 ```
 
-On getting `BluetoothAdapter.STATE_ON`, `startRepeatingTask()`; is called, which eventually calls a thread to start the scanning for every 15 minutes by calling discoverUnpairedDevices broadcast receiver and prints the result of the scanning in the listview.
+On getting `BluetoothAdapter.STATE_ON`, `startRepeatingTask()` is called, which eventually calls a thread to start the scanning for every 15 minutes by calling discoverUnpairedDevices broadcast receiver and prints the result of the scanning in the listview.
 
 ```
 public final BroadcastReceiver discoverUnpairedDevices = new BroadcastReceiver() {
@@ -72,26 +74,27 @@ For copying the data, the method `WriteBtn(bluetoothDevice.getAddress(), rssi, c
 @RequiresApi(api = Build.VERSION_CODES.KITKAT)
 public void WriteBtn(String address, int rssi, String currentDateTime, int frequncy,String addressValue) {
    try {
-       File file = new File(this.getExternalFilesDir(null), "BluetoothScannedDevice.txt");
-       FileOutputStream fileOutput = new FileOutputStream(file, true);
-       OutputStreamWriter outputStreamWriter = new OutputStreamWriter(fileOutput);
-       outputStreamWriter.write("Address : " + address);
-       outputStreamWriter.append(" , ");
-       outputStreamWriter.write("DB :" + rssi);
-       outputStreamWriter.append(" , ");
-       outputStreamWriter.write("TimeStamp:" + currentDateTime);
-       outputStreamWriter.append(" , ");
-       outputStreamWriter.write("Frequency:" + frequncy);
-       outputStreamWriter.write("\n\n");
-       outputStreamWriter.write("Location:" + addressValue);
-       outputStreamWriter.write("\n\n");
-       outputStreamWriter.flush();
-       fileOutput.getFD().sync();
-       outputStreamWriter.close();
-       MediaScannerConnection.scanFile(this, new String[]{file.getAbsolutePath()}, null, null);
-        } catch (Exception e) {
+           File file = new File(this.getExternalFilesDir(null), "BluetoothScannedDevice.txt");
+           FileOutputStream fileOutput = new FileOutputStream(file, true);
+           OutputStreamWriter outputStreamWriter = new OutputStreamWriter(fileOutput);
+           outputStreamWriter.write("Address : " + address);
+           outputStreamWriter.append(" , ");
+           outputStreamWriter.write("DB :" + rssi);
+           outputStreamWriter.append(" , ");
+           outputStreamWriter.write("TimeStamp:" + currentDateTime);
+           outputStreamWriter.append(" , ");
+           outputStreamWriter.write("Frequency:" + frequncy);
+           outputStreamWriter.write("\n\n");
+           outputStreamWriter.write("Location:" + addressValue);
+           outputStreamWriter.write("\n\n");
+           outputStreamWriter.flush();
+           fileOutput.getFD().sync();
+           outputStreamWriter.close();
+           MediaScannerConnection.scanFile(this, new String[]{file.getAbsolutePath()}, null, null);
+       }
+       catch (Exception e) {
             e.printStackTrace();
-        }
+       }
 }
 ```
 
@@ -123,7 +126,7 @@ private final BroadcastReceiver bluetoothDiscoverableBroadcastReceiver = new Bro
 
 # Pairing with Bluetooth devices
 
-A smart pairing option is installed to keep track the number of times a device is in close proximity. For this a collection class is used which increments the variable `frequncy` if it was previously scanned and available in the list.
+A smart pairing option is installed to keep track of the number of times a device is in close proximity. For this a collection class is used which increments the variable `frequncy` if it was previously scanned and available in the list.
 
 ```
 if(mBTDevices.contains(bluetoothDevice) && maddressValue.contains(addressValue)) {