open-sdr / openwifi

open-source IEEE 802.11 WiFi baseband FPGA (chip) design: driver, software
GNU Affero General Public License v3.0
3.82k stars 647 forks source link

Instability in CSI Data Obtained by OpenWiFi When Monitoring Mobile Phone WiFi Signals in a Stable Environment #407

Open LvHaoyuisme opened 4 months ago

LvHaoyuisme commented 4 months ago

Hello, Dr. Jiao! We are attempting to receive actual WIFI signals on the OpenWiFi platform, using a single channel plus RIS reconfigurability to simulate multi-channel for direction finding of WIFI devices.But we found that under the same conditions, the CSI data varies greatly, especially the phase of the CSI. I saw https://github.com/open-sdr/openwifi/issues/396, so I followed the instructions in that issue and obtained stable CSI with the openwifi device operating in a self-transmitting and self-receiving mode. 屏幕截图 2024-05-18 174829 The result is perfect. I tried to monitor the WiFi signal from a specific device in monitor mode and obtain the corresponding CSI, but the results were very poor. My operations are as follows:

In one ssh:

cd openwifi ./wgd.sh insmod side_ch.ko ./monitor_ch.sh sdr0 1

The target device is operating on channel 1

./side_ch_ctl wh1h4001 ./side_ch_ctl wh7h00cf3e83 ./side_ch_ctl wh8d3 ./sdrctl dev sdr0 set reg xpu 1 1 ./sdrctl dev sdr0 set reg xpu 13 1 ./side_ch_ctl g0

You mentioned setting the receive gain to a fixed value to avoid the impact of AGC ,so I opened another SSH.

In anther ssh:

./set_rx_gain_manual.sh 10

I have tried setting different gains and found that when the receive gain is too low, I cannot obtain CSI data. I have tried 10, 20, 30, 40, and 50, but although I can get CSI data, it is very unstable.

Figure_1 I used the test_side_info_file_display.m script to plot the side_info.txt collected from a single acquisition ( I made a small modification to unwrap the phase)

屏幕截图 2024-05-18 183054

The results are very poor.The phase and amplitude of the CSI are both unstable.

Previously, I referred to https://github.com/open-sdr/openwifi/blob/master/doc/app_notes/csi.md, and the obtained CSI data amplitude was relatively stable, but the phase remained unstable. My operations:

cd openwifi ./wgd.sh insmod side_ch.ko ./monitor_ch.sh sdr0 1 ./side_ch_ctl wh1h4001 ./side_ch_ctl wh7hd88d2a2f ./set_rx_gain_manual.sh 10 ./side_ch_ctl g0 屏幕截图 2024-05-18 184201 屏幕截图 2024-05-18 184303 The device I am using is SDRpi What should I do to obtain stable CSI data from actual WiFi devices?

chenmo234 commented 4 months ago

Hello, sorry to bother you. May I ask you some questions regarding IQ capture in OpenWiFi? Here is my contact information: c2385405729.

chenmo234 commented 4 months ago

After running ./fosdem.sh, I can detect OpenWiFi with my phone, but after running ./monitor_ch.sh sdr0 11, my phone can no longer find the OpenWiFi AP.

LvHaoyuisme commented 4 months ago

I've encountered a similar issue where the device seems unable to operate both as an access point and to monitor a specific channel at the same time. After running ./fosdem.sh, you can proceed with IQ sampling or obtain CSI data without needing to run ./monitor_ch.sh sdr0 11 to monitor a specific channel.

chenmo234 commented 4 months ago

Thank you very much for your response! I'll try it right away. I've been stuck on this for two days

chenmo234 commented 4 months ago

It would be an honor to stay in touch with you. May I add your contact information?

JiaoXianjun commented 4 months ago

Hello, Dr. Jiao! We are attempting to receive actual WIFI signals on the OpenWiFi platform, using a single channel plus RIS reconfigurability to simulate multi-channel for direction finding of WIFI devices.But we found that under the same conditions, the CSI data varies greatly, especially the phase of the CSI. I saw #396, so I followed the instructions in that issue and obtained stable CSI with the openwifi device operating in a self-transmitting and self-receiving mode. 屏幕截图 2024-05-18 174829 The result is perfect. I tried to monitor the WiFi signal from a specific device in monitor mode and obtain the corresponding CSI, but the results were very poor. My operations are as follows:

In one ssh:

cd openwifi ./wgd.sh insmod side_ch.ko ./monitor_ch.sh sdr0 1

The target device is operating on channel 1

./side_ch_ctl wh1h4001 ./side_ch_ctl wh7h00cf3e83 ./side_ch_ctl wh8d3 ./sdrctl dev sdr0 set reg xpu 1 1 ./sdrctl dev sdr0 set reg xpu 13 1 ./side_ch_ctl g0

You mentioned setting the receive gain to a fixed value to avoid the impact of AGC ,so I opened another SSH.

In anther ssh:

./set_rx_gain_manual.sh 10

I have tried setting different gains and found that when the receive gain is too low, I cannot obtain CSI data. I have tried 10, 20, 30, 40, and 50, but although I can get CSI data, it is very unstable.

Figure_1 I used the test_side_info_file_display.m script to plot the side_info.txt collected from a single acquisition ( I made a small modification to unwrap the phase)

屏幕截图 2024-05-18 183054

The results are very poor.The phase and amplitude of the CSI are both unstable.

Previously, I referred to https://github.com/open-sdr/openwifi/blob/master/doc/app_notes/csi.md, and the obtained CSI data amplitude was relatively stable, but the phase remained unstable. My operations:

cd openwifi ./wgd.sh insmod side_ch.ko ./monitor_ch.sh sdr0 1 ./side_ch_ctl wh1h4001 ./side_ch_ctl wh7hd88d2a2f ./set_rx_gain_manual.sh 10 ./side_ch_ctl g0 屏幕截图 2024-05-18 184201 屏幕截图 2024-05-18 184303 The device I am using is SDRpi What should I do to obtain stable CSI data from actual WiFi devices?

Please re-format the issue according to our issue template.