Good Day,
I try to create wlan0 AP (access point) without internet which allows to open tcpip socket connection to my process running on the rpi3 (just for some packages exchange with client application connecting to the AP with predefined 192.168.XXX.XXX IP adress and port), at the same time I need eth0 internet connection with DHCP.
Apparently, I get pretty close result configuring /etc/hostapd/hostapd.conf
[code]
interface=wlan0
driver=nl80211
ssid=MY_AP_SSID
hw_mode=g
channel=6
macaddr_acl=0
auth_algs=1
ignore_broadcast_ssid=MY_AP_SSID
wpa=0
wpa_passphrase=passphrase
wpa_key_mgmt=WPA-PSK
wpa_pairwise=TKIP
rsn_pairwise=CCMP
[/code]
and after that running
[code]
/etc/init.d/hostapd stop
ifdown wlan0
ifup wlan0
/etc/init.d/hostapd restart
[/code]
and I can connect socket and communicate with the rpi3 from my PC but I get "dynamic" IP 169.254.XX.XX. The IP is the same every time but it doesn't look like the constant one.
The question is: [b]how to configure static 192.168.XXX.XXX IP for the AP?[/b]
As soon as I try to do it with /etc/dhcpcd.conf addition like
[code]
nodhcp
static interface wlan0
static ip_address=192.168.111.111
[/code]
I can see the correct wlan0 IP in the 'ifconfig' and 'ip -4 addr show' output and I can 'ping 192.168.111.111' successfully on the rpi3 but I get 'destination unreachable' if I ping the IP from my PC connected to the AP.
I use RPI3 (model B) with 'raspbian jessie lite', 'uname -a' output is
[code]
Linux raspberrypi 4.9.59-v7+ #1047 SMP Sun Oct 29 12:19:23 GMT 2017 armv71 GNU/Linux
[/code]