hiltsu
Posts: 3
Joined: Thu Jun 11, 2020 7:50 am
Location: Hanko, Finland
Contact: Website

RPI 3+ WiFi issues

Thu Jun 11, 2020 8:11 am

I have strange issues with Raspberry 3B WiFi.

What I see is that connections are lost frequently and they come back if I ping from Raspberry to address I want to connect.

As an example, if my ESP32 is connecting to Raspberry with mosquito mqtt-service once a minute, everything work just fine if I let Raspberry to ping the ESP32, but if I stop the pinging ESP32 at the same time when ESP32 tries to publish data to the mqtt (Raspberry), connection will be lost in a few minutes. There is no way to establish connection from ESP32 (or from any other device, not even VNC, SSH etc) if Raspberry loose connectivity. There is no entries in the syslog and I have added to the rc.local power management setting so that the WiFi adapter shall not save energy. Country for the WiFi is set to FI (Finland).

What I see from the WiFi AP router side is that Raspberry is not connected 802.11n all other devices connected to the AP. For example ESP32 connects with 80211n, but Raspberry never. It is really annoying to build applications connecting to Raspberry, because every class needs to start with connectivity checking.

Kernel is latest: 4.19.118-v7+

iwconfig: wlan0 IEEE 802.11 ESSID:"secret"
Mode:Managed Frequency:2.422 GHz Access Point: 00:00:00:00:00:00
Bit Rate=72.2 Mb/s Tx-Power=31 dBm
Retry short limit:7 RTS thr:off Fragment thr:off
Power Management:off
Link Quality=61/70 Signal level=-49 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:4 Invalid misc:0 Missed beacon:0

Raspberry is running influxdb, mqtt-broker and gateway, grafana, polling DHT22-sensor and sending 433MHz remote every now and then. Processor utilization is typically < 1%, memory 218/926 used.

Codes used at the ESP32 side https://github.com/divergentti/kanalana ... ster/esp32 (Finnish comments).

Raspberry was bought as a full starter pack (NOOBS), power supply in the box is 5V / 2.5A.

Are all Raspberries defective so that WiFi is not robust? If it is a WiFi chip issue, should I add WiFi dongle instead? How about warranty?

Thank you in advance for your advices.

epoch1970
Posts: 5132
Joined: Thu May 05, 2016 9:33 am
Location: Paris, France

Re: RPI 3+ WiFi issues

Thu Jun 11, 2020 12:10 pm

Reported speed 72Mbps. That is WiFi N.
"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème." Les Shadoks, J. Rouxel

hiltsu
Posts: 3
Joined: Thu Jun 11, 2020 7:50 am
Location: Hanko, Finland
Contact: Website

Re: RPI 3+ WiFi issues

Thu Jun 11, 2020 12:29 pm

epoch1970 wrote:
Thu Jun 11, 2020 12:10 pm
Reported speed 72Mbps. That is WiFi N.
Thank you for the information. The router shows:
MAC Address Lease IP Address Hostname Communication Method Wireless Authentication 802.11n
B8:27:EB:xx:xx:xx - - Wireless Authorized Disabled

For other devices, such as ESP32-Wroom-32, 802.11n is Enabled. Perhaps this is not related to 802.11n after all, but something else at the Raspberry side. Everything works fine if I let Raspberry ping the ESP32 (both connected to the same WiFi AP), but if I do not ping, connectivity to the Raspberry is totally lost within minutes and comes back after some time. As an example VNC to the Raspberry freezes quite often even if ping is keeping network up.

Syslog seems to be clean, kernel.log last entries are from yesterday:
Jun 10 22:10:18 raspi kernel: [ 12.575196] Bluetooth: RFCOMM socket layer initialized
Jun 10 22:10:18 raspi kernel: [ 12.575225] Bluetooth: RFCOMM ver 1.11
Jun 10 22:10:21 raspi kernel: [ 15.318977] fuse init (API version 7.27)

last errors in the kernel.log are:
root@raspi:/var/log# cat kern.log|grep -i error
Jun 7 18:19:27 raspi kernel: [281091.006617] brcmfmac: brcmf_run_escan: error (-52)
Jun 7 18:19:27 raspi kernel: [281091.006633] brcmfmac: brcmf_cfg80211_scan: scan error (-52)


only errors in the syslog are related to VNC connection establishement:
Jun 11 15:27:51 raspi vncserver-x11[445,root]: SPrintConnMgr: Failed to add printer: server-error-service-unavailable

hiltsu
Posts: 3
Joined: Thu Jun 11, 2020 7:50 am
Location: Hanko, Finland
Contact: Website

Re: RPI 3+ WiFi issues

Fri Jun 19, 2020 9:45 am

This was most likely related to Buffalo AP. With TP-Link Acher Raspberry seems to work just fine.

Meanwhile I designed for the Raspberry 3B and relay module: Image

Return to “Beginners”