Difference between revisions of "Access Point"

From Klaus' wiki
Jump to: navigation, search
Line 2: Line 2:
  
 
I have done this with a TP-Link TL-WN722N adapter. [[File:TP-Link TL-WN722N.png|100px|right]]
 
I have done this with a TP-Link TL-WN722N adapter. [[File:TP-Link TL-WN722N.png|100px|right]]
 +
 +
==Configure the Hostappd==
  
 
First edit the /etc/hostapd/hostapd.conf file (as root)
 
First edit the /etc/hostapd/hostapd.conf file (as root)
Line 38: Line 40:
 
  ctrl_interface=/var/run/hostapd
 
  ctrl_interface=/var/run/hostapd
 
  ctrl_interface_group=0
 
  ctrl_interface_group=0
 +
 +
==Configure IP addresses==
  
 
In the file /etc/network/interfaces add these lines (choose an address suitable for you):
 
In the file /etc/network/interfaces add these lines (choose an address suitable for you):
Line 44: Line 48:
 
     netmask 255.255.255.0
 
     netmask 255.255.255.0
 
which will set up a static address for the access point.
 
which will set up a static address for the access point.
 +
 +
==Manually test==
  
 
Next test i manually, in order to see if the access point software will run without errors.
 
Next test i manually, in order to see if the access point software will run without errors.
Line 54: Line 60:
 
If you can get this connection up running with your password but no IP address everything at this point is fine.
 
If you can get this connection up running with your password but no IP address everything at this point is fine.
  
 +
You can stop the wpa_supplicant service permanently by issuing
 +
<source lang=bash>
 +
root@beaglebone ]$ systemctl disable wpa_supplicant.service
 +
</source>
 +
 +
==Enable DCHP server==
 
Next thing is to enable a dhcp server.
 
Next thing is to enable a dhcp server.
 +
  
 
---more to come, when I get the spare time---
 
---more to come, when I get the spare time---

Revision as of 15:35, 11 November 2020

In order to setup the BeagleBone Black as an access point you need to go through a few steps.

I have done this with a TP-Link TL-WN722N adapter.
TP-Link TL-WN722N.png

Configure the Hostappd

First edit the /etc/hostapd/hostapd.conf file (as root)

### Wireless network name ###
#
### Set your bridge name ###
#bridge=br0
#driver
driver=nl80211
country_code=DK
ssid=<The SSID the AP should Present it self with>
channel=<select af free channel e.g. 1, 6 or 11>
hw_mode=g
interface=wlan0
# # Static WPA2 key configuration
# #1=wpa1, 2=wpa2, 3=both
wpa=2
wpa_passphrase=<YourDesiredVerySecretPassword>
## Key management algorithms ##
wpa_key_mgmt=WPA-PSK
#
## Set cipher suites (encryption algorithms) ##
## TKIP = Temporal Key Integrity Protocol
## CCMP = AES in Counter mode with CBC-MAC
wpa_pairwise=TKIP CCMP
rsn_pairwise=CCMP
#
## Shared Key Authentication ##
auth_algs=1
## Accept all MAC address ###
macaddr_acl=0
#enables/disables broadcasting the ssid
ignore_broadcast_ssid=0
# Needed for Windows clients
eapol_key_index_workaround=0
ctrl_interface=/var/run/hostapd
ctrl_interface_group=0

Configure IP addresses

In the file /etc/network/interfaces add these lines (choose an address suitable for you):

iface wlan0 inet static
    address 192.168.22.1
    netmask 255.255.255.0

which will set up a static address for the access point.

Manually test

Next test i manually, in order to see if the access point software will run without errors.

root@beaglebone ]$ systemctl stop wpa_supplicant.service
root@beaglebone ]$ hostapd  /etc/hostapd/hostapd.conf

If you can get this connection up running with your password but no IP address everything at this point is fine.

You can stop the wpa_supplicant service permanently by issuing

root@beaglebone ]$ systemctl disable wpa_supplicant.service

Enable DCHP server

Next thing is to enable a dhcp server.


---more to come, when I get the spare time---