Supported ICs

Wi-Fi NAN Overview

Wi-Fi Aware, also known as NAN (Neighbor Awareness Networking), is a technical standard certified by the Wi-Fi Alliance. It enables supported devices to quickly discover, connect, and exchange data with other Wi-Fi devices without relying on traditional network infrastructure, Internet connection, or GPS signals. Compared with traditional Wi-Fi Direct, NAN is more energy efficient and effective at the device discovery phase, making it suitable for applications that require continuous awareness of the surrounding environment. This enables a new range of innovative peer-to-peer applications, such as:

  • Social applications: find nearby friends with similar interests, or join a local game.

  • Information sharing: quickly share files with all participants in a meeting room.

  • Local services: receive coupons from nearby stores in a shopping mall, or get detailed information about exhibits in a museum.

The efficiency and low power consumption of Wi-Fi NAN benefit from its unique mechanisms, mainly including the NAN cluster, the service publication/subscription model, and data path establishment.

NAN Cluster

Multiple neighboring NAN devices can automatically form a NAN Cluster, enabling communication between devices in the cluster. Devices inside the cluster share a common time beacon for synchronization.

Devices are not always awake, but instead follow a strict synchronized schedule and only wake up during a very short period called the Discovery Window (DW). During the DW, devices can broadcast their services or listen for services from others. For most of the remaining time, devices stay in low-power sleep mode. This synchronized sleep/wake mechanism is the key to NAN’s low power consumption, avoiding the significant battery drain caused by continuous scanning in traditional Wi-Fi device discovery.

../../_images/nan_cluster.png

Wi-Fi NAN Cluster

Service Publish/Subscribe Model

Wi-Fi NAN adopts an efficient publish/subscribe model for service discovery:

  • Publish Service: Devices can act as publishers to broadcast the services they can provide.

  • Subscribe Service: Other devices (subscribers) listen for particular services of interest.

  • Service Discovery: When a subscriber receives a published message matching its subscription during a discovery window, the service is successfully discovered.

Establishing NAN Data Path (NDP)

Once successfully subscribed, two devices can choose to establish a NAN Data Path - a direct, peer-to-peer Wi-Fi link, featuring:

  • High bandwidth: High data rates using Wi-Fi for transmission.

  • Low latency: Direct connection without AP relay.

  • Security: WPA2 encryption can be used for data path security.

After NDP establishment, devices can conduct file transfer, video streaming, real-time gaming, and other high-bandwidth, low-latency activities.

References

Wi-Fi NAN Supported Features

Realtek devices provide comprehensive support for the Wi-Fi NAN protocol and are capable of operating in any role within a NAN network. The specific supported features are as follows:

  • Core Functional Support

    • Creating a NAN Cluster: When no available NAN network is nearby, the device can actively initiate a new NAN cluster, assume the master role, broadcast synchronization beacons, and provide the foundation for other devices to join.

    • Joining a NAN Cluster: The device can automatically scan for and discover existing NAN clusters nearby, synchronize its clock with them, seamlessly integrate into the existing Neighbor Awareness Network, and perform service discovery with other devices.

    • Publish Service: The device can broadcast (publish) one or more services to allow nearby devices to discover them.

    • Subscribe Service: The device can subscribe to (search for) specific services and discover devices providing those services.

    • Establishing Data Paths: Devices can establish either open or encrypted NAN data paths and negotiate time windows for point-to-point data exchange.

  • NAN Security Support

    • Supports establishing encrypted data paths between devices. Unicast data frames are protected with WPA2 AES encryption.

    • Supports NAN Pairing for device authentication, key agreement, distribution, and management.

    • Supports protection of management frames and multicast data frames using GTK & IGTK.

    • Supports beacon protection using BIGTK.

  • Key Features

    • High bandwidth and low latency data transfer: Ensures excellent data exchange performance based on Wi-Fi technology.

    • Secure connections: Authenticates and encrypts connections between paired devices at the Wi-Fi layer.

    • Multiple connections: Supports simultaneous connections with multiple Wi-Fi NAN devices.

    • Network concurrency: Supports concurrent use of Wi-Fi NAN functionality and traditional Wi-Fi networks (STA mode or SoftAP mode) without interference.

    • Robust topology: Employs a fully peer-to-peer topology, so the joining or departure of a single node does not interrupt existing connections between other nodes.

Wi-Fi NAN Porting Guide

Realtek Wi-Fi NAN supports Linux Host, Wi-Fi Card mode S2H (WHC Operating Modes), or RTL8730E Linux.

For device driver porting, refer to Wi-Fi Card mode Device Driver Porting. For host driver porting, refer to the Linux tab in Wi-Fi Card mode Host Driver Porting.

Wi-Fi NAN Usage Guide

Realtek NAN utility is a user-space tool that integrates the open-source iw library and other proprietary libraries, designed to provide an intuitive interface for Wi-Fi NAN operations.

This tool offers three methods to control NAN devices:

  • Test Script: nan_test.sh is a script used for issuing iw/vendor commands and receiving corresponding events for NAN testing.

  • Realtek Demo Application: rtw_aware is an application that controls NAN devices through the shared library; more details are provided in this document.

  • Shared Library: Users can develop their own Wi-Fi NAN applications using the APIs and event notifications exported by the shared library.

../../_images/nan_utility_components.png

Wi-Fi NAN Utility Architecture