MANES is a system for emulating ad hoc networking on Android smartphones, which do not natively support it. With MANES, any Android smartphone with 3G or WiFi Internet access can participate in an emulated ad hoc network. MANES allows real users in their natural environments to easily install and use new ad hoc networking routing protocols and applications, empowering researchers and developers to better test and analyze their ad hoc systems.

MANES comprises three parts:

Client library
To broadcast a packet to its one-hop neighbors, a client application uses this library to send the packet to the server. The library is also used to listen for incoming packets. See Usage for details.
Central server
The server is responsible for delivering the incoming packets to the clients that are within ad hoc range (e.g., 25-100 meters) of the sending client. See Architecture for details.
Topology estimation service
This service must estimate which clients are within ad hoc range of each other. The topology estimation service uses data reported by the clients (e.g., GPS information and signal strength of visible access points) to compute these estimates. See Topology Estimation for details.

Traditionally, ad hoc networking researchers and developers have relied most-heavily on simulation and, when feasible, on small-scale synthetic deployments to test and characterize their protocols and applications. Deployments with real users and real hardware are preferable, but the difficulty and cost of deploying useful, portable wireless devices with real people was prohibitive. The widespread deployment of modern smartphones should resolve this problem, but unfortunately the phones do not support ad hoc networking. MANES was developed to allow researchers and developers to recruit normal Android smartphone users to participate in ad hoc network deployments for testing and characterization.

MANES addresses two primary problems for researchers and developers of ad hoc networking protocols and applications.

Enabling Power Efficient Ad Hoc Networking on Android Smartphones

Although WiFi hardware supports an ad hoc mode, Android currently disables this mode (rooted phones can use ad hoc, but most users aren't willing or able to root their phones). Furthermore, power management is more difficult than in infrastructure mode, since there is no base station to buffer incoming packets during periodic sleep intervals. Instead, all clients must coordinate their sleeping schedules, but this appears to not be widely supported, with many devices always staying awake in ad hoc mode.

MANES emulates the ad hoc network functionality (each sent message is broadcast to all one-hop neighbors) over the Internet and thus can be used by any Android device with a 3G or WiFi connection, transparently taking advantage of their advanced power saving mode support.

Collecting Network Traces and Usage Statistics for Offline Analysis

Normally, the decentralized nature of ad hoc networks is a desirable feature, but during prototyping and analysis, it significantly complicates network trace and usage statistics collection. MANES routes all traffic through a central server while still enforcing an ad hoc network topology, enabling easy data collection for system analysis and performance characterization.

MANES may also help encourage the inclusion of ad hoc networking as a standard feature on consumer devices. Generating enough user support to justify the additional manufacturing and development costs is blocked by a classic chicken-and-egg problem: applications won't be developed until ad hoc networking is supported, but ad hoc networking won't be supported until good applications for it exist. The wireless industry is tackling the lack of support, as the recent adoption of WiFi Direct in Android 4.0 shows. But WiFi Direct is optimized for single-hop device-to-device communication, not traditional multi-hop, broadcast-based ad hoc networking, and thus is not a complete solution. MANES can encourage application development by giving users a way to run ad hoc applications on hardware that does not natively support them, hopefully leading to additional investment in full ad hoc networking support on future devices.

MANES is not
A general-purpose messaging infrastructure or P2P replacement.
MANES is intended for low bandwidth, low message-rate applications at prototype scales. The MANES backend is designed for easy administration (i.e., it runs on a single server) and offline data analysis (i.e., all network topology state and traffic is logged). It is not intended to support to large-scale deployments or for full production use.
A replacement for real ad hoc networks.
By emulating an ad hoc network over the infrastructure network, MANES loses all the advantages of a real ad hoc network. It was built to allow prototype testing on phones that don't currently support true ad hoc networks and to enable easy collection of network traces for analysis. Real-world, scalable, non-prototype applications should use real ad hoc networking.
Good for testing timing-sensitive ad hoc protocols.
Single-hop packet delivery latencies can be several orders of magnitude higher with MANES than true ad hoc transmissions because (1) all traffic is routed through a central server on the Internet and (2) clients are notified of incoming packets by the C2DM service.

MANES uses a client-server architecture, as illustrated in the figure below. The Android Cloud to Device Messaging Framework (C2DM) is used to notify clients when new packets have arrived, because many clients sit behind networking technologies (NAT and various corporate and ISP firewalls) that prevent the server from initiating a connection.

The following figure illustrates the process of broadcasting one packet.

System Architecture

MANES determines the network topology by estimating which clients would be able to communicate directly via WiFi. Without actual WiFi transmission measurements, this estimation is a non-trivial task. MANES takes the following approach.

Under construction.