README.md (40773b7882a840f41a4b585d6e6866cc81fa13a9) README.md (70cedb2220ce3dc467f97e16f1a60c1776ea94f6)
1<!--
2Author: Xianjun jiao, Michael Mehari, Wei Liu
3SPDX-FileCopyrightText: 2019 UGent
4SPDX-License-Identifier: AGPL-3.0-or-later
5-->
6
7# openwifi
8<img src="./openwifi-arch.jpg" width="900">

--- 105 unchanged lines hidden (view full) ---

114 (Use "./wgd.sh 1" to enable experimental AMPDU aggregation)
115 ```
116- Use openwifi as client to connect other AP (Change wpa-connect.conf on board firstly):
117 ```
118 route del default gw 192.168.10.1
119 wpa_supplicant -i sdr0 -c wpa-connect.conf &
120 dhclient sdr0
121 ```
1<!--
2Author: Xianjun jiao, Michael Mehari, Wei Liu
3SPDX-FileCopyrightText: 2019 UGent
4SPDX-License-Identifier: AGPL-3.0-or-later
5-->
6
7# openwifi
8<img src="./openwifi-arch.jpg" width="900">

--- 105 unchanged lines hidden (view full) ---

114 (Use "./wgd.sh 1" to enable experimental AMPDU aggregation)
115 ```
116- Use openwifi as client to connect other AP (Change wpa-connect.conf on board firstly):
117 ```
118 route del default gw 192.168.10.1
119 wpa_supplicant -i sdr0 -c wpa-connect.conf &
120 dhclient sdr0
121 ```
122- Use openwifi in ad-hoc mode: Please check **sdr-ad-hoc-up.sh** and **sdr-ad-hoc-join.sh**.
123- Use openwifi in monitor mode: Please check **monitor_ch.sh**.
122- Use openwifi in ad-hoc mode: Please check **sdr-ad-hoc-up.sh**, **sdr-ad-hoc-join.sh** and [this app note](./doc/app_notes/ad-hoc-two-sdr.md).
123- Use openwifi in monitor mode: Please check **monitor_ch.sh** and [this app note](./doc/app_notes/inject_80211.md).
124- The Linux native Wi-Fi tools/Apps (iwconfig/ifconfig/iwlist/iw/hostapd/wpa_supplicant/etc) can run over openwifi NIC in the same way as commercial Wi-Fi chip.
124- The Linux native Wi-Fi tools/Apps (iwconfig/ifconfig/iwlist/iw/hostapd/wpa_supplicant/etc) can run over openwifi NIC in the same way as commercial Wi-Fi chip.
125- **sdrctl** is a dedicated tool to access openwifi driver/FPGA, please check doc directory for more information.
125- **sdrctl** is a dedicated tool to access openwifi driver/FPGA, please check [project document](./doc/README.md) for more information.
126
127## Update FPGA
128
126
127## Update FPGA
128
129Since the pre-built SD card image might not have the latest bug-fixes/updates, it is recommended to update the fpga bitstream on board.
129(Check [Driver and FPGA dynamic reloading app note](./doc/app_notes/drv_fpga_dynamic_loading.md) for more convenient way of updating FPGA and driver files)
130
130
131Since the pre-built SD card image might not have the latest bug-fixes/updates, it is recommended to always copy the latest files in the [user_space](./user_space) directory on to the board. Then update the fpga bitstream and driver (see next section) on to the board.
132
131- Install Vivado/SDK 2018.3 (Vivado Design Suite - HLx Editions - 2018.3 Full Product Installation. If you don't need to generate new FPGA bitstream, WebPack version without license is enough)
132- Setup environment variables (use absolute path):
133 ```
134 export XILINX_DIR=your_Xilinx_install_directory
135 (Example: export XILINX_DIR=/opt/Xilinx. The Xilinx directory should include sth like: Downloads, SDK, Vivado, xic)
136 export OPENWIFI_HW_DIR=your_openwifi-hw_directory
137 (The directory where you store the open-sdr/openwifi-hw repo via git clone)
138 export BOARD_NAME=your_board_name

--- 19 unchanged lines hidden (view full) ---

158 umount /mnt
159 ```
160 **Power cycle** the board to load new FPGA bitstream.
161
162 To load FPGA dynamically without rebooting/power-cycle, check [Driver and FPGA dynamic reloading app note](./doc/app_notes/drv_fpga_dynamic_loading.md).
163
164## Update Driver
165
133- Install Vivado/SDK 2018.3 (Vivado Design Suite - HLx Editions - 2018.3 Full Product Installation. If you don't need to generate new FPGA bitstream, WebPack version without license is enough)
134- Setup environment variables (use absolute path):
135 ```
136 export XILINX_DIR=your_Xilinx_install_directory
137 (Example: export XILINX_DIR=/opt/Xilinx. The Xilinx directory should include sth like: Downloads, SDK, Vivado, xic)
138 export OPENWIFI_HW_DIR=your_openwifi-hw_directory
139 (The directory where you store the open-sdr/openwifi-hw repo via git clone)
140 export BOARD_NAME=your_board_name

--- 19 unchanged lines hidden (view full) ---

160 umount /mnt
161 ```
162 **Power cycle** the board to load new FPGA bitstream.
163
164 To load FPGA dynamically without rebooting/power-cycle, check [Driver and FPGA dynamic reloading app note](./doc/app_notes/drv_fpga_dynamic_loading.md).
165
166## Update Driver
167
166Since the pre-built SD card image might not have the latest bug-fixes/updates, it is recommended to update the driver on board.
168(Check [Driver and FPGA dynamic reloading app note](./doc/app_notes/drv_fpga_dynamic_loading.md) for more convenient way of updating FPGA and driver files)
169
170Since the pre-built SD card image might not have the latest bug-fixes/updates, it is recommended to always copy the latest files in the [user_space](./user_space) directory on to the board. Then update the fpga bitstream (see previous section) and driver on to the board.
171
167- Prepare Analog Devices Linux kernel source code (only need to run once):
168 ```
169 cd openwifi/user_space; ./prepare_kernel.sh $XILINX_DIR ARCH_BIT build
170 (For Zynq 7000, ARCH_BIT should be 32, for Zynq MPSoC, ARCH_BIT should be 64)
171 ```
172 **Note**: In Ubuntu, gcc-10 might have issue ('yylloc' error), so use gcc-9 if you encounter error.
173- Compile the latest openwifi driver
174 ```

--- 16 unchanged lines hidden (view full) ---

191 cd openwifi/user_space/sdrctl_src; scp `find ./ -name \*` [email protected]:openwifi/sdrctl_src/
192 ```
193- Compile the sdrctl **on board**:
194 ```
195 cd ~/openwifi/sdrctl_src/ && make && cp sdrctl ../ && cd ..
196 ```
197## Easy Access and etc
198
172- Prepare Analog Devices Linux kernel source code (only need to run once):
173 ```
174 cd openwifi/user_space; ./prepare_kernel.sh $XILINX_DIR ARCH_BIT build
175 (For Zynq 7000, ARCH_BIT should be 32, for Zynq MPSoC, ARCH_BIT should be 64)
176 ```
177 **Note**: In Ubuntu, gcc-10 might have issue ('yylloc' error), so use gcc-9 if you encounter error.
178- Compile the latest openwifi driver
179 ```

--- 16 unchanged lines hidden (view full) ---

196 cd openwifi/user_space/sdrctl_src; scp `find ./ -name \*` [email protected]:openwifi/sdrctl_src/
197 ```
198- Compile the sdrctl **on board**:
199 ```
200 cd ~/openwifi/sdrctl_src/ && make && cp sdrctl ../ && cd ..
201 ```
202## Easy Access and etc
203
204- Check [Driver and FPGA dynamic reloading app note](./doc/app_notes/drv_fpga_dynamic_loading.md) for more convenient way of updating FPGA and driver files.
199- FPGA and driver on board update scripts
200 - Setup [ftp server](https://ubuntu.com/server/docs/service-ftp) on PC, allow anonymous and change ftp root directory to the openwifi directory.
201 - On board:
202 ```
203 ./sdcard_boot_update.sh $BOARD_NAME
204 (Above command downloads uImage, BOOT.BIN and devicetree.dtb, then copy them into boot partition. Remember to power cycle)
205 ./wgd.sh remote
206 (Above command downloads driver files, and brings up sdr0)

--- 66 unchanged lines hidden ---
205- FPGA and driver on board update scripts
206 - Setup [ftp server](https://ubuntu.com/server/docs/service-ftp) on PC, allow anonymous and change ftp root directory to the openwifi directory.
207 - On board:
208 ```
209 ./sdcard_boot_update.sh $BOARD_NAME
210 (Above command downloads uImage, BOOT.BIN and devicetree.dtb, then copy them into boot partition. Remember to power cycle)
211 ./wgd.sh remote
212 (Above command downloads driver files, and brings up sdr0)

--- 66 unchanged lines hidden ---