xref: /openwifi/doc/app_notes/ap-client-two-sdr.md (revision 5deb8d18f6d13bc809afd5109593e0982888373c)
1- Power on two SDR boards. Call one board "AP board" and the other "client board". On each board, the TX and RX antenna should vertical/orthogonal to each other as much as possible to gain a good TX/RX isolation.
2- Connect a computer to the AP board via Ethernet cable. The computer should have static IP 192.168.10.1. Open a terminal on the computer, and then in the terminal:
3  ```
4  ssh [email protected]
5  (password: openwifi)
6  cd openwifi
7  ./fosdem.sh
8  (It will create a WiFi AP by hostapd program with config file: hostapd-openwifi.conf)
9  (Wait for the script completed)
10  cat /proc/interrupts
11  (Execute the "cat ..." command for several times)
12  (You should see the number of "sdr,tx_itrpt1" grows, because it sends the "openwifi" beacon periodically)
13  ```
14- Connect another computer to the client board via Ethernet cable. The computer should have static IP 192.168.10.1. Open a terminal on the computer, and then in the terminal:
15  ```
16  ssh [email protected]
17  (password: openwifi)
18  service network-manager stop
19  cd openwifi
20  ./wgd.sh
21  (Wait for the script completed)
22  ifconfig sdr0 up
23  iwlist sdr0 scan
24  (The "openwifi" AP should be listed in the scanning results)
25  iwconfig sdr0 essid openwifi
26  ```
27- Now the client is trying to associate with the AP. The AP board terminal should print like:
28  ```
29  ...
30  sdr0: AP-STA-CONNECTED 66:55:44:33:22:58
31  sdr0: STA 66:55:44:33:22:58 RADIUS: starting accounting session 1FF1C1B4-00000001
32  ```
33  If not, please adjust antenna/distance and re-run the commands on the client side.
34
35- After association is done, in the terminal of client:
36  ```
37  dhclient sdr0
38  (Wait for it completed)
39  ifconfig sdr0
40  (Now you should see the IP address like 192.168.13.x allocated by AP)
41  ./set_csma_normal.sh
42  ping 192.168.13.1
43  (Ping the AP)
44  ```
45  Now the communication link should be already setup between the AP and the client.
46