24
DEC1618: Community Awareness System for Android Devices Team Advisors: Dr. Daji Qiao, Dr. George Amariucai Jason Wong: Team Leader Erik Fetter: Communication Leader Matt Gerst: Team Webmaster Shikhar Vats: Key Concept Holder Brad Anson: Key Concept Holder Adit Kushare: Key Concept Holder ([email protected])

Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

  • Upload
    others

  • View
    1

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

DEC1618: Community Awareness System for Android Devices Team Advisors: Dr. Daji Qiao, Dr. George Amariucai

Jason Wong: Team LeaderErik Fetter: Communication LeaderMatt Gerst: Team WebmasterShikhar Vats: Key Concept Holder Brad Anson: Key Concept Holder Adit Kushare: Key Concept Holder ([email protected])

Page 2: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Project Goals● Project Title: Community Awareness System for Android Devices

● Clients: NSA, Iowa State University

● Problem Statement: Design and implement a community awareness system

for Android devices through an ad-hoc mesh network.

2

Page 3: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Use Case Scenario● Each soldier in a squadron would have our

app installed

● Track the rest of the squadron during

missions:○ Missing

○ Injured

○ Falling Behind

● Environment:○ Little to no infrastructure

○ Sandstorms

3

Page 4: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Market Survey

● BearTooth○ Hardware solution which is only available for pre-order○ It supports off-the-grid talk and text but no file sharing

● ProjectSpan○ Software solution which enables Ad-hoc Wifi○ Requires rewriting a wireless kernel for every device

● Android: WifiP2P○ Does not support true mesh networking

● Serval Mesh - our project’s top pick○ Supports talk, text, and file sharing○ Can work with or without extra hardware○ Open Source: GNU General Public License, version 3

4

Page 5: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Project Milestones & Schedule

● Spring 2016○ Create a working prototype

● Summer 2016○ Demo of our working prototype to the NSA

● Fall 2016○ Improve application for final product delivery to NSA in September

5

Page 6: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Functional Requirements● View a list of the members of the mesh network● Visualize the basic topology of the network● Request sensor data from members of the mesh network● Expose a network API to other Android applications

to enable the use of the networking capability

6

Page 7: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Non-functional Requirements● The application should not drain a device’s battery● Reliable network connectivity● Low latency network updates● Remote data collection should be received in a reasonable amount of time● Collection of data should occur in the background, without UI interaction● Support a relatively small network of 10-20 devices

7

Page 8: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Platform (Hardware)● Android Devices

a. Nexus 7 (4 devices)b. Nexus 6 (2 devices)c. HTC One M8 (1 Device)

● Routers: TP-LINK TL-MR3020 (3 devices)

8

Page 9: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Platform (Software)

● Operating System: CyanogenMod○ Target API : Android 14

● Networking simplified by Serval Mesh○ Batphone and Serval-DNA

9

Page 11: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Current Project Status

● Prototype Implemented:○ Visualizing mesh○ User Interface○ RSSI ○ Camera, Audio

● In Progress:○ RSSI & Audio Integration○ Sensor Request Protocol○ Sensor Data Collection

11

Page 12: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Functional Decomposition● Application Layer

○ Mesh Visualization

● Networking Layer○ Serval Mesh○ RSSI○ Sensor Request Protocol

● Sensor Layer○ Retrieving Video○ Retrieving Audio○ Retrieving Misc. Sensors

12

Page 13: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Application Layer (Visualization)

● Mesh Visualization○ Visualizing the Routing Table○ UI to send Sensor Requests○ WebView: Sigma.js

13

Page 14: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Networking Layer (Setup)

● Serval Mesh○ Initial setup and debugging of text, call, and file sharing

● CyanogenMod○ Android does not support connecting to Ad-hoc networks○ CyanogenMod is a custom OS which enables Ad-Hoc Wifi

● Wifi RSSI Research○ So far not possible with Ad-Hoc Wifi

■ (iwconfig, iwlist, iwspy, tcpdump all failed)○ Alternative: Bluetooth RSSI

14

Page 15: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Networking Layer (RSSI)

● RSSI: Received Signal Strength Indicator

IDEA

● To have a function that tells the relative distance of other nodes in the network

CHALLENGE

● Wifi RSSI does not work with android in adhoc mode

SOLUTION

● Used Bluetooth RSSI 15

Page 16: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Networking Layer (Protocols)

● Serval Mesh Protocols○ MeshMS - Sends text messages over the mesh network○ Rhizome - Propagates files throughout the network○ MDP - Underlying protocol

● Issues○ MeshMS is actually built on top of Rhizome○ Devices may not get messages○ Response times

● Solution○ Custom Protocol

16

Page 17: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Sensor Layer (Audio)

● Audio Capture in test application using buttons● Audio Capture using constant background service

(30 second interval) (Battery drain con)● Audio Capture on Demand in background.● Use MeshMS to trigger audio collection and send file using

Rhizome.

Future optimization Ideas

- Stream audio buffer in background instead waiting to store entire file and play it on demand

17

Page 18: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Sensor Layer (Record Remote Video)

● Select a device across the mesh to begin capturing video● Remote device should initialize camera without requiring user● Remote device uploads the device into the file repository,

accessible by any phone on the mesh

18

Page 19: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Sensor Layer (General Sensors)

● Collect relevant general sensor data:○ Accelerometer○ Barometer○ Ambient light○ Proximity

● Store data in a way that can be sent across the network

● Respond to requests with a file of either newly collected data orData stored in the last 5-10 seconds

19

Page 20: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Resource/Cost Estimate

● Android is free for developers● Serval Mesh is free and open source● Hardware cost is ~$39 per router

○ TP-LINK TL-MR3020 3G/4G Wireless N150 Portable Router ($28)○ SanDisk Ultra Fit 32GB USB 3.0 Flash Drive ($11)

20

Page 21: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Technical Constraints and Considerations

● Ad-Hoc Wifi is not natively supported on Android devices○ Solution: CyanogenMod

● Mesh networking can drain a device’s battery○ Solution: Routers

● Wifi RSSI is not available while in ad-hoc mode○ Solution: Bluetooth RSSI

● Background collection of sensors without the user knowingis challenging.○ Solution: Various android workarounds.

21

Page 22: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Future Testing Plan

● Theoretical Proof○ Prove how our custom MDP protocol guarantees packet

delivery

● Field Testing○ Effective Communication Distances○ Multi-Hop scenarios○ Latency of sensor requests

22

Page 23: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Questions?

23

● Adit: Audio, Inter-application communication● Brad: Wifi Direct Research, Camera Implementation, Inter-application

communication● Erik: Serval Mesh Networking, Inter-application communication● Jason: Serval Mesh, CyanogenMod, Wifi RSSI, Mesh Visualization● Matt: Serval Mesh Networking● Shikhar: Bluetooth RSSI

Page 24: Shikhar Vats: Key Concept Holder DEC1618: Community ...dec1618.sd.ece.iastate.edu/pdf/DEC1618Presentation.pdf · Nexus 7 (4 devices) b. Nexus 6 (2 devices) c. HTC One M8 (1 Device)

Sources1. https://www.beartooth.com/

2. http://tucu.ca/wp-content/uploads/2014/02/traditional-WiFI-vs-mesh-WiFI-network.png

3. https://www.amazon.ca/TP-LINK-TL-MR3020-Wireless-Portable-Router/dp/B00634PLTW

4. http://laughingsquid.com/sandisk-cruzer-fit-a-tiny-32-gb-usb-flash-drive-the-size-of-a-dime/

24