Context: Stock Android exposes Wi-Fi Direct peer-to-peer APIs, but it does not provide application-transparent communication across multiple Wi-Fi Direct groups. For developers working on non-rooted devices, the main obstacle is architectural: interface-specific transport contexts, relay roles, and forwarding state must be coordinated entirely at application level. Objectives: This paper investigates whether multi-group Wi-Fi Direct communication can be realized as a stock-Android software architecture while preserving forwarding-state consistency and remaining compatible with Android 11 devices without rooting or operating-system modification. Methods: We design SWARNET, a layered artifact composed of a Flutter application layer, a Kotlin native networking layer, interface-bound P2P and legacy-Wi-Fi sockets, relay-state management, and subscription-based forwarding tables. We evaluate the implemented artifact on five stock Samsung Galaxy A10s smartphones across four single-group and multi-group scenarios using archived throughput and packet-loss measurements. Results: The artifact remained operational in all four scenarios. Peak receiver throughput observed from the archived curves was approximately 19.7~Mbit/s in 2d1g, 17.9~Mbit/s in 3d1g, 16.1~Mbit/s in 4d2g, and 16.0~Mbit/s in 5d3g. Packet loss increased with forwarding complexity, reaching about 19--20\% only in the highest-load region of the three-group case. Conclusion: The contribution is an implementable software architecture and a feasibility study showing that stock-Android multi-group Wi-Fi Direct communication can be engineered at application level on non-rooted devices. The results support architectural feasibility in a small static testbed; they do not establish broad resilience, scalability, or deployment readiness.
翻译:背景:原生Android提供了Wi-Fi Direct点对点API,但未实现跨多个Wi-Fi Direct组的应用透明通信。对于在非root设备上开发的开发者而言,主要障碍在于架构层面:接口特定的传输上下文、中继角色和转发状态必须完全在应用层进行协调。目标:本文研究能否在保持转发状态一致性的前提下,实现一种兼容Android 11设备(无需root或操作系统修改)的多组Wi-Fi Direct通信原生Android软件架构。方法:我们设计了SWARNET分层构件,包含Flutter应用层、Kotlin原生网络层、接口绑定的P2P与传统Wi-Fi套接字、中继状态管理及基于订阅的转发表。在五部原生三星Galaxy A10s智能手机上,通过存档吞吐量和丢包率测量,评估了该构件在四种单组和多组场景中的表现。结果:该构件在所有四种场景中均保持运行。从存档曲线观察到的峰值接收吞吐量分别为:2d1g场景约19.7 Mbit/s、3d1g场景约17.9 Mbit/s、4d2g场景约16.1 Mbit/s、5d3g场景约16.0 Mbit/s。丢包率随转发复杂度增加而上升,仅在3组场景的最高负载区域达到约19%~20%。结论:本文贡献在于提出了一种可实现的软件架构,并通过可行性研究证明,在非root设备上可通过应用层工程实现原生Android多组Wi-Fi Direct通信。研究结果在小型静态测试平台上验证了架构可行性,但并不代表广泛的鲁棒性、可扩展性或部署就绪状态。