View Single Post
Old 10-24-2025, 10:46 PM   #1
vrb
Junior Member
vrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toysvrb shares his or her toys
 
vrb's Avatar
 
Posts: 3
Karma: 5664
Join Date: Oct 2025
Location: SF
Device: PW6
[PW6] WiFi Direct/P2P exploration notes

Hi all, new here and not sure if this is the right place for this kind of info, but I wanted to share everything I learned trying to get wifi direct/p2p working on my PW6 as a koreader plugin.

I was trying to do something similar to the excellent `Filebrowser` or `Syncthing` plugins but with a direct peer connection.

tldr: The MediaTek MT7668 WiFi chip in the 12th Gen Paperwhite *advertises* P2P support in its driver capabilities, but the actual implementation seems incomplete. You can compile custom wpa_supplicant binaries with P2P enabled, but the kernel driver itself returns "Operation not supported" when you try to create P2P interfaces.

Notes:
- Amazon's stock wpa_supplicant doesn't have P2P compiled in/p2p commands dont run natively
- Can cross-compile a new wpa_supplicant with CONFIG_P2P=y for ARMv7 (I did it on m1 OS X via arm-linux-gnueabihf-gcc)
- Had to match Kindle's exact libnl version (3.2.17)
- I ended up having to swap both wpa_supplicant AND wpa_cli
- P2P discovery commands start to work (`p2p_find` returns OK)
- But `p2p_group_add` always returns fail
- Direct interface creation via `iw` also fails

I'm by no means an expert but wanted to throw this out there for anyone else who was thinking about doing like, direct p2p sync applications.

Looks okay,
Code:
iw phy phy0 info | grep -A 5 "Supported interface modes"
Supported interface modes:
    * IBSS
    * managed
    * AP
    * P2P-client
    * P2P-GO
but;
Code:
iw dev wlan0 interface add p2p-wlan0-0 type __p2pdev
command failed: Operation not supported (-95)
vrb is offline   Reply With Quote