owly README

项目的 README,来自 github.com/t4t5/owly。合并为一个 markdown 文件:README.md。

Owly

https://github.com/user-attachments/assets/b195ce4c-e078-49be-bc13-44a72b6dc189

AirDrop between iPhones and Linux devices whose Wi-Fi isn't Apple's Broadcom chip.

See supported hardware.

Install

Arch/Omarchy

If using Omarchy, you can install Owly together with omdrop to get it in your bar:

# Install Omdrop:
omarchy plugin add https://github.com/netmojo-systems/omdrop-plugin.git

# Install Owly (omdrop-owl):
yay -S omdrop-owl

If you're just using Arch, or don't want the UI, you can just install the CLI:

yay -S owly
NixOS
inputs.owly.url = "github:t4t5/owly";
imports = [ inputs.owly.nixosModules.default ];
services.owly.enable = true;
services.owly.settings = { allow_untested = true; };
Debian/Ubuntu

Download the .deb from the releases page and run:

sudo apt install ./owly_*_amd64.deb     # Debian 12, Ubuntu 22.04 and newer
Fedora

Download the .rpm from the releases page and run:

sudo dnf install ./owly-*.x86_64.rpm    # Fedora 44 and newer
From source

Requires Rust 1.88 or newer:

cargo build --release --locked -p owlyd -p owly-cli
sudo packaging/install.sh owly
sudo systemctl daemon-reload && sudo nmcli general reload conf

Usage

Start the radio in your terminal:

owly radio up

Then, in another terminal:

# To receive files:
owly receive --dir ~/Downloads

# To send files:
owly browse    # (find nearby AirDrop receivers)
owly send --to "Jane's iPhone" photo.jpg

Make sure you set your phone's Airdrop setting to "Everyone for 10 minutes".

Supported hardware

Status: ✅ both directions work, ⚠️ unreliable (see known issues), ❌ fails, ❓ untested

Modes: Shared and Concurrent keep Wi-Fi connected; Exclusive and Active monitor turn it off while the radio is up (see why?)

Card Driver Status Tested on
MediaTek MT7925 mt7925e ✅ Shared Framework 13, 14c3:0717, Omarchy 4.0.4 (kernel 7.2.5)
MediaTek MT7612U (USB) mt76x2u ✅ Exclusive 0e8d:7612 (kernel 7.2.9)
Realtek RTL8822BE rtw88_8822be ✅ Exclusive; shared untested Crosshair VII Hero, 10ec:b822, NixOS 26.11 (kernel 7.2.9)
Realtek RTL8851BE rtw89_8851be ✅ Shared ASUSTeK COMPUTER INC. ASUS Vivobook 14 X1404VAPBF_X1404VA, 10ec:b851, openSUSE Tumbleweed (kernel 7.3.0)
Realtek RTL8852AE rtw89_8852ae ✅ Shared • ThinkPad P14s Gen 2a, 10ec:8852, Ubuntu 26.04.1 (kernel 7.0)
• LENOVO ThinkPad T14 Gen 2a, 10ec:8852, Omarchy (kernel 7.2.8)
Realtek RTL8852BE rtw89_8852be ✅ Shared ASUS PRIME B550M-A WIFI II, 10ec:b852, CachyOS (kernel 7.2.9)
Realtek RTL8852CE rtw89_8852ce ✅ Shared and exclusive • Legion Slim 5 16AHP9, 10ec:c852, Omarchy 4.0.4 (kernel 7.2.5)
• ThinkBook 16 G7 IML, 10ec:c852, Ubuntu 24.04.5 (kernel 7.0)
Realtek RTL8922AE rtw89_8922ae ✅ Exclusive ASUS System Version, 10ec:8922, CachyOS (kernel 7.3.0)
Realtek RTL8188FTV (USB) rtl8xxxu ✅ Exclusive (opt-in) • INTEL H81, 0bda:f179, Linux Mint 22.3 (kernel 6.14.0): partly
• LENOVO ThinkPad T495, 0bda:f179, Fedora Linux 44 (kernel 6.19.10)
Realtek RTL8852BU (USB) rtw89_8852bu ✅ Exclusive (opt-in), as a second card USB adapter, 35bc:0108, NixOS 26.05 (kernel 7.2.9)
Realtek RTL8812BU (USB) rtw88_8822bu ✅ Exclusive • ASUSTeK COMPUTER INC. ASUS Vivobook 14 X1404VAPBF_X1404VA, 2357:0138, openSUSE Tumbleweed (kernel 7.3.0), shared: partly
• ASUSTeK COMPUTER INC. ASUS Vivobook 14 X1404VAPBF_X1404VA, 2357:0138, openSUSE Tumbleweed (kernel 7.3.0), exclusive
Qualcomm Atheros AR9271 (USB) ath9k_htc ✅ Shared (opt-in) Micro-Star International Co., Ltd. MS-7C56, 0cf3:9271, Fedora Linux 45 (kernel 7.3.3)
Qualcomm Atheros AR9287 ath9k ✅ Shared Acer Aspire 4750, 168c:002e, Ubuntu 24.04.5 LTS (kernel 7.0.0)
Intel 9260 iwlwifi ✅ Exclusive 8086:2526, Debian 13 (kernel 7.2.12)
Intel 9560 iwlwifi ✅ Exclusive Lenovo 81SY, 8086:a370, Omarchy 4.0.0 (kernel 7.2.8)
Intel AX200 iwlwifi ✅ Exclusive • ThinkPad X1 Yoga, 8086:2723, NixOS 26.05 (kernel 6.19.8)
• Micro Computer (HK) Tech Limited MS-A2, 8086:2723, NixOS 26.05 (kernel 7.2.5)
Intel AX201 iwlwifi ✅ Exclusive • Ubuntu 24.04 (kernel 6.8)
• CachyOS (kernel 7.2.9)
• Intel Client Systems NUC10i7FNK, 8086:02f0, NixOS 26.05 (kernel 6.18.55)
Intel AX210 iwlwifi ✅ Exclusive Micro Computer (HK) Tech Limited MS-A2, 8086:2725, NixOS 26.05 (kernel 7.2.5)
Intel AX211 iwlwifi ✅ Exclusive; concurrent on 8086:51f0 • ThinkPad X1, 8086:51f1, Ubuntu 26.04 (kernel 7.0)
• XPS 9320, 8086:51f0, Arch (kernels 7.2.3 and 7.2.8)
• Legion Pro 7 16IRX8H, 8086:7a70, Omarchy 4.0.4 (kernel 7.2.3)
• TUXEDO InfinityBook Max 15 Gen10 (Arrow Lake), 8086:7740, Kubuntu 26.04.1 (kernel 7.0)
Intel BE (Panther Lake) iwlwifi ✅ Exclusive XPS 16, 8086:e440, Arch (kernel 7.2)
Intel BE200 iwlwifi ✅ Exclusive • GEEKOM IT13 Max, 8086:272b, Omarchy 4.0.4 (kernel 7.2.5)
• LENOVO Legion Pro 7 16IAX10H, 8086:272b, Arch Linux (kernel 7.3.4)
MediaTek MT7921 mt7921e ⚠️ Exclusive, opt-in; shared fails (#14) 14c3:7961, CachyOS (kernel 7.2.9)
MediaTek MT7922 (RZ616) mt7921e ⚠️ Exclusive, opt-in; shared fails (#14) Minisforum MS-A2, 14c3:0616, NixOS 26.05 (kernels 6.18 and 7.2.5)
MediaTek MT7927 mt7925e ❌ Shared: never heard; active monitor (opt-in) sends, but receiving times out (#44) TP-Link Archer TBE550E, 14c3:7927, CachyOS (kernel 7.2.9)
Realtek RTL8821CE rtw88_8821ce ❌ Shared: OWL syncs but no transfer, Wi-Fi often lost after (#60); exclusive receives nothing HP laptop, 10ec:c821, Omarchy (kernel 7.2.5)
Realtek RTL8821AU (USB) rtw88_8821au ❌ Exclusive: AWDL syncs but no data gets through (#93); shared untested TP-Link Archer T2U Plus, 2357:0120, Ubuntu 24.04.5 (kernel 7.0)
Qualcomm WCN6855 (QCNFA765) ath11k_pci ❌ Can't create the monitor interface both modes need (#45) ThinkPad, 17cb:1103, CachyOS (kernel 7.2.9)
Qualcomm WCN7850 (FastConnect 7800) ath12k_wifi7_pci ❌ Shared: receives nothing from the phone (#40); exclusive untested 17cb:1107, Fedora 44 (kernel 7.2.9)
Intel Dual Band Wireless-AC 7265 iwlwifi ❌ Exclusive: firmware asserts on every ad-hoc start (#16) Zenbook UX305CA, 8086:095a, Omarchy 4.0.4 (kernel 7.2.5)
Intel Dual Band Wireless-AC 3168 iwlwifi ❌ Exclusive: firmware asserts on every ad-hoc start, like the 7265 (#109) ASUS S2 Air Series PF4NU1F, 8086:24fb, EndeavourOS (kernel 6.18.55)
Intel Wireless-AC 8260 iwlwifi ❌ Exclusive: firmware resets on channel 44; no transfer on 6 NUC6i7KYK, 8086:24f3, Home Assistant OS (kernel 6.12)
Intel Dual Band Wireless-AC 8265 iwlwifi ❌ Exclusive: firmware resets about 10 s after the ad-hoc cell starts; through a hidden AP, nothing heard from the phone EliteBook x360 1030 G3, 8086:24fd, Manjaro (kernel 6.12)

One card name can cover chips that behave differently, so a report from a machine, PCI ID (lspci -nn) or kernel not listed here helps too.

Checking your card

owly doctor

This says which mode the card runs in, what's in the way (an AP on the wrong channel, a missing hostapd), and what's known to go wrong on it.

Adding your card

owly test-card

This walks you through a photo each way with an iPhone, watches Wi-Fi for a minute, and writes a JSON report. Open a pull request adding it to hardware/reports/, or attach it to an issue.

A card with no entry in drivers.toml gets the * entry, which runs only with allow_untested = true. Cards that can inject frames from a monitor interface while connected to Wi-Fi are the likely candidates for shared mode. Most mac80211 drivers can, but how they behave around it varies, which is what drivers.toml records. To try other settings, copy the * entry to /etc/owly/drivers.toml under your driver's name (basename $(readlink /sys/class/net/<wifi>/device/driver)) and change it there.

owlyd reads /etc/owly/radio.toml and /etc/owly/drivers.toml again for each owly doctor and each time the radio comes up, so changes to them need no restart.

Modes

Shared. Wi-Fi stays connected, and AWDL shares the AP's channel, which has to be 6, 44 or 149. Owly injects frames through a monitor interface with the station's MAC, and advertises only the phone's slots on that channel. The station ACKs the phone's frames.

Exclusive. For cards that can't inject while connected, such as every Intel card tested. Wi-Fi is down while the radio is up, and comes back when it's given back. An ad-hoc cell on AWDL's BSSID takes the station's place to ACK the phone's frames, or a hidden AP (hostapd) on cards with no ad-hoc mode. It tries channels 44, 149 and 6 in that order, of those the card may transmit on, since an iPhone gives AWDL more slots on 5 GHz. Intel cards go straight to 6, the only channel where a phone has used their cell.

Active monitor. For cards with neither, such as the MediaTek MT7612U and MT7921: an active monitor carrying the station's MAC ACKs in place of the cell.

Concurrent. For Intel cards whose firmware can run a second channel beside the station's, so far the AX211 8086:51f0. Wi-Fi stays connected on whatever channel the AP uses, and a P2P group owner (owlygo0) on channel 6 ACKs the phone's frames. With Wi-Fi disconnected it runs exclusive mode instead, and the radio stops if Wi-Fi disconnects or roams during a session. To always use exclusive mode, copy the iwlwifi entry to /etc/owly/drivers.toml as [devices."8086:51f0"].

A USB adapter can run exclusive mode as a second card while the built-in one stays connected: set station to the adapter in /etc/owly/radio.toml and disconnect it (nmcli device disconnect <adapter>).

Configuration

/etc/owly/radio.toml, all optional:

station = "wlan0"        # the Wi-Fi interface to use; else the first station
allow_untested = false   # run on a card the quirks table doesn't mark tested
reconnect_after = true   # overrides the driver's reconnect_after_monitor
country = "DE"           # exclusive modes: the regulatory domain to ask for, else the AP's
channels = [6]           # exclusive modes: overrides the driver's channel order
aggregation = true       # overrides the driver's rx_ampdu: accept the phone's Block Ack session
tx_rate = "mcs7"         # the data frame rate
hostapd = "/usr/sbin/hostapd" # for a hidden AP, on cards with no ad-hoc mode; else found on PATH
tx_amsdu = true          # send unicast as A-MSDUs where the peer takes them

What Owly does on each Wi-Fi driver comes from crates/owly-radio/drivers.toml. /etc/owly/drivers.toml, in the same format, is read over it, so you can try settings for a new card without rebuilding.

Known issues

owly doctor lists what's known to go wrong on your card. Beyond that:

How it works

AirDrop runs over AWDL, a Wi-Fi link Apple devices use to talk to each other directly. Owly comes in two halves:

The pieces are Rust crates you can use in other projects: owly-awdl (AWDL), owly-airdrop (AirDrop) and owly-radio (the Wi-Fi card on Linux). docs/SPEC.md describes the protocol they implement. To add a new kind of radio, such as an ESP32 over USB, implement owly-awdl's Air trait if it only sends and receives Wi-Fi frames, or owly-radio's Backend trait if it runs AWDL itself.

Development

To try it with a phone, run just radio in one terminal (it installs owlyd first when it's missing or out of date), then just receive or just send in another. With no arguments, just send sends a test photo, tests/photo.png.

The AirDrop tests run sender and receiver in a user network namespace (unshare -rn), so they need no root, but do need unprivileged user namespaces. just install installs a development build the way the packages lay it out, and just uninstall removes it. packaging/arch/*/PKGBUILD build packages from the checkout (makepkg -si there), and packaging/package.sh deb or rpm builds owly's .deb or .rpm.

owly (t4t5/owly)

正在搜索数据库…

3.5K ·GitHub
这是什么?omdrop-owl 是一个射频后端,通过 OWL 在监听接口上以用户态运行 AWDL,让“omdrop”(一个 Linux 上的 AirDrop 实现)能在缺少 Apple 博通 Wi-Fi 芯片的机器上工作。
这是独立的 AirDrop 应用,还是 omdrop 的插件?它是插件,不是独立应用:它只以辅助脚本的形式提供射频层,供 omdrop CLI 和面板调用,与姊妹包 omdrop-awdl(博通后端)并列存在。
还需要安装 omdrop 吗?它面向什么硬件?需要,你必须单独安装 radio-backend 版本的 omdrop 本体。目前只有 MediaTek MT7925 芯片(如 Framework 13 所用)经过测试并获得支持;其他网卡需要显式选择加入。
在我的硬件上使用它有什么限制?它与 brcmfmac-awdl-dkms 冲突(同一时间只能有一个射频后端);接入点必须位于信道 6、44 或 149,否则启动失败;在 MT7925 上,连接期间删除监听接口可能因已知的 mt76/固件缺陷而暂时卡死 Wi-Fi。
AirDrop 运行期间我的 Wi-Fi 还能保持连接吗?可以,在经过测试的 MT7925 上,工作站保持关联且双向连接不断,因为 AWDL 与接入点共享同一信道,而不是切换离开。
可以为我自己的 Wi-Fi 网卡添加支持吗?你可以通过 /etc/omdrop/allow-untested 选择加入,把你的驱动添加到 /etc/omdrop/owl-profiles,测试收发一张照片并观察 Wi-Fi 稳定性五分钟,然后提交一个包含测试结果的 pull request。
为什么发送比接收慢?注入的帧以固定节奏发出,大约每 2.5 毫秒一帧,与请求的 PHY 速率无关,这把发送速度限制在约 490 kB/s,而接收约为 1.3 MB/s。
可以把 iPhone 记住为已知对端吗?不能,iPhone 每次会话都会随机化其 AWDL 地址,因此后端无法记住特定的对端。
作者
t4t5
大小
1.2 MB
星标
3.5K
时长
1个月
提交 · 90 天