Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pi4 frame injection #642

Open
yjxb1 opened this issue Feb 26, 2025 · 1 comment
Open

pi4 frame injection #642

yjxb1 opened this issue Feb 26, 2025 · 1 comment

Comments

@yjxb1
Copy link

yjxb1 commented Feb 26, 2025

I want to use pi4 to inject data frames, and keep sending data frames to another Raspberry Pi to collect CSI data. I've installed nexmon but I don't know how to use frame injection. Can someone answer my questions? Thank you so much.

@jlinktu
Copy link
Member

jlinktu commented Mar 3, 2025

There are many possibilities you could do this.
Here is an example using scapy in python to craft and inject a very basic Data frame with a payload of 0x12345678 roughly every 500ms.
Make sure you added a monitor interface that is up and disabled power save mode before running this (interface named mon0 here).

#!/usr/bin/python
from scapy.all import *
dot11 = Dot11FCS(addr1="00:11:22:33:44:55",
              addr2="00:11:22:33:44:56",
              addr3="00:11:22:33:44:57",
              type="Data",
              subtype="Data")
data = '\x12\x34\x56\x78'
packet = RadioTap()/dot11/data
sendp(packet,iface="mon0",loop=1,inter=0.5)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants