Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.6.6 Sonoff Basic doesn't connect to wifi #86

Closed
xoseperez opened this issue Feb 25, 2017 · 66 comments
Closed

1.6.6 Sonoff Basic doesn't connect to wifi #86

xoseperez opened this issue Feb 25, 2017 · 66 comments

Comments

@xoseperez
Copy link
Owner

Originally reported by: Tim K (Bitbucket: clueo8, GitHub: clueo8)


I flashed sonoff basic with tty to 1.6.6; after flashing both firmware and filesys, I left it powered over the usb. It appeared to be in AP mode for maybe 3-5 minutes before connecting to wifi. I tried disconnecting the usb and powering off the mains and it would never connect. Installed 1.6.5 and all appears well with connecting to wifi after just a few seconds of being plugged in. I know there is an issue for tracking OTA updates and wifi issues, but this wasn't an OTA update.

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


Hi Tim, what is working well for me under 1.6.6 is just doing straight dhcp ... this is what my WIFI config looks like

wifi.JPG

do you have anything configure other than AP and password ? Maybe you are running static?

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


No static here; Only difference with mine was I had the gateway IP (router IP) and I tried setting the mask recently but doesn't appear to help. Did you have a similar issue with the sonoff basic and 1.6.6?

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


This is the basic on 1.6.6

But this said - when I configure only static IP and Gateway and leave Netmask and DNS blank - it still uses dhcp.

Let me try and get to your error where you are "stuck" in AP mode.

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


The only time I ever saw AP mode was powered over USB after flashing with serial. I couldn't connect with the default AP password. When running power from the main, my laptop never saw the AP, but the LED was blinking constantly.

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


Are you using embedded web on this sonoff? I haven't tried that yet.

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


As a side note static only works if you define all the fields, no more auto semi-updating. ( This is relevant if you configure your ssdi and password via usb)

static.JPG

Can you define yours as static, with all the fields and see if that makes for "fix"

going to erase flash mine now. This should remove all previous configs. I use the terminal to set my initial wifi config have not use the AP mode in a while.

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


Yeah as of 1.6.6 I run embedded ...

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


This worked for me - just did it again to double check.

  1. esptool.py -p /dev/ttyUSB0 -b 115200 erase_flash
  2. define EMBEDDED_WEB 1
    • build and flash -> Uploading 393600 bytes from .pioenvs/sonoff-debug/firmware.bin to flash at 0x00000000
  3. power cycle
  4. rest - device comes up in AP mode
  5. set ssid0 ABC
  6. set pass0 edfefdeeefe1A
  7. reset

All good - device comes up on dhcp in seconds.

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


Saw something interesting,

Just did step 1 - 4 ... did not power cycle and the AP comes up with

#!arduino

WIFI] Creating access point
[WIFI] MODE AP --------------------------------------
[WIFI] SSID SONOFF_95ED6A
[WIFI] PASS fibonacci
[WIFI] IP   0.0.0.0
[WIFI] MAC  5E:CF:7F:95:ED:6A
[WIFI] ----------------------------------------------
[MDNS] OK

No IP

Power cycle and rest to see what is going on and I now have an AP IP.

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


Access the AP via the standard fibonacci password - get the password change, define my new password, test it. Disconnect and forget the AP WIFI - reconnect to the same WIFI name but this time authenticate with your new password. Go back into 192.168.4.1 configure WIFI.

AP WIFI access -.JPG

Netmask and DNS was pre-populated

rest device - device connects in STA mode all good.

#!arduino
Mode: STA
PHY mode: N
Channel: 12
AP id: 0
Status: 5
Auto connect: 1 

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


A few questions. Is the EMBEDDED_WEB a build flag? I've never tried Terminal access, but I feel it could really help me debug; can I use my same FTDI USB that I use to flash the firmware? Do you power off the main for that or do you connect to the 3.3 pin still?

@xoseperez
Copy link
Owner Author

Yes, the EMBEDDED_WEB is a build flag and it's disabled by default atm. Still testing, will probably roll out in 1.7.0.

You can use the same FTDI USB2UART you use to debug. Don't do it while plugged to mains!!! But if you do PLEASE USE CAUTION!! It can be deadly dangerous. If the board is powered in some other way just plug TX, RX and GND. Do not do it for the POW. NEVER. In the POW the ground is shared between the controller and mains.

@xoseperez
Copy link
Owner Author

The static IP only works if you have all 4 fields populated (IP, GW, NETMASK and DNS). Otherwise it will always go DHCP.

I have also seen the 0.0.0.0 IP for AP mode a couple of times. It looks like a race condition.

Erasing the flash normally helps if your device does not respond. With the just released 1.6.7 you also have the option to hard-reset it holding the button for more than 10 seconds. Hard-resetting clears the (emulated) EEPROM, so all settings are lost. After doing it should start in AP mode with the default "fibonacci" password.

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


The reason I ask about how to power it during debugging is that I've noticed it behaves differently powered via 3v3 vs the main.

@xoseperez
Copy link
Owner Author

I have noticed that too. Maybe due to noisy power supply?

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


Not very scientific or accurate, but this helps me out when I am playing with the esp's.

Charger Doctor.jpg

Voltage swings on the front side of the FTDI are ok as long as you get around 3.3 on the sonoff itself. Mine is 3.36 on the multi-meter even if (and this is different with various charger doctors because they are so cheap and nasty) inline drops to 4.8volts.

For this FTDI and this charge doctor I track the following. 0.10A - serial + mqtt is being monitored in platformio. 0.04A device is being flashed. 0.09A reboot, wifi negotiation and working with normal mqtt this sits at around 0.07A. yes accuracy is problematic but the numbers give me some idea what is going on, like dead short or more current draw go look etc.

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by Sachin Filinto (Bitbucket: sfilinto, GitHub: sfilinto):


just flashed with the latest version & facing similar issue. i get the AP when connected via the usb to serial interface but wont work on 220V mains for 90% of the times i have flashed it.
i doubt its noisy power cause i tried it off at home as well as in office.

@xoseperez
Copy link
Owner Author

Original comment by Sachin Filinto (Bitbucket: sfilinto, GitHub: sfilinto):


Update: I bought 3 new sonoffs & i see the same behaviour on all 3 of them.

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


So this is still happening on 1.6.8? I'm waiting on 3 basics to come in the mail, was hoping it wasn't an issues anymore. Try 1.6.5, that's the latest which worked for me. Are you using any build flags or features apart from the OOTB configuration?

@xoseperez
Copy link
Owner Author

Original comment by Sachin Filinto (Bitbucket: sfilinto, GitHub: sfilinto):


I tried 1.6.8 as well as 1.1.0 ( which i am using on my other devices ) same behaviour. works on usb but no-go on mains.
when on mains, I measured the voltage on the vcc & gnd. it seems ok at 3.28V.

I am not using any build flags or any other configuration. its the stock firmware.

@xoseperez
Copy link
Owner Author

Original comment by Jordi (Bitbucket: jorditpuig, GitHub: jorditpuig):


I can confirm that I am also having issues with 1.6.8 at the original Sonoff. I have two of them and for both connecting when still powered by the USB seamed to work pretty well, when I connect them to the mains I have a hard time connecting them to any of my 2 wifis. Actually the hardest issue is that the hard reset (10sec press) requires repeating the process a couple of times till it works and even then connecting to the soft AP is really hard. In fact, I have managed to connect to one of them and configure it only after insisting more than 50ish times and even then only after setting my laptops IP statically to 192.168.4.2. During the process of connecting to the soft AP I was either getting authentication errors or timeouts while getting the DHCP response or simply the soft AP disappearing after I connected. Yesterday after disconnecting the connected Sonoff from the mains it returned to its old state of not being able to connect to my wifis. Resetting does work but I cannot connect to the soft AP no matter what kind of tricks I pull out or device I am using.

Btw I have also bought two S20s. I flushed them with the same 1.6.8 and I have never had any issues with them. Both connected and responsive to REST requests.

I am deploying using platformio and I am not setting any extra compile-time flags.

I will try with older releases (e.g. 1.6.5) to see if this is a recently introduced "bug".

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


I got 1.6.8 running last night on my sonoffs by setting a static IP in the wifi settings. Also I'm using embedded web. Try the static IP first and see if that helps...

@xoseperez
Copy link
Owner Author

Original comment by Sachin Filinto (Bitbucket: sfilinto, GitHub: sfilinto):


From the 3 sonoff basic that i ordered, i got one working on mains after flashing it some 15+ times ( V 1.1.0). no changes in the firmware.
I am very inclined to believe this is a hardware issue as all the previous ones i have flashed worked on the first attempt.
The one i have working is up & running for about 48 hours without any problem. i need to repeat the procedure on the other 2 sonoffs now.
I use firmware version 1.1.0 simply because i use the same on my other devices.

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


I'm noticing inconsistent amungst my 4 basic sonoffs as well. Two of them took an OTA upgrade from 1.6.8 to 1.6.9 without issue but my other two were stuck in AP mode after a successful upgrade and I was forced to go back to 1.6.8 on just two of them. One of the bad ones wouldn't let me connect to the AP and I had to flash with the serial cable. The other I was able to connect to AP and downgrade OTA.

@xoseperez
Copy link
Owner Author

I'm also inclined to think it's a hardware related issue, at least partially. One of my sonoffs struggles to connect to the WIFI but it behaves much better when there is no AC current flowing and closer to the AP. On the other hand my Sonoff TH, POW or S20 work great with the same firmware...

@xoseperez
Copy link
Owner Author

@clueo8 An those two you had to downgrade, do they work fine with 1.6.8?

@xoseperez
Copy link
Owner Author

Original comment by Tim K (Bitbucket: clueo8, GitHub: clueo8):


It took a few attempts at flashing and setting up, but eventually got them working only after assigning a static IP, otherwise, they would always get stuck in AP mode on a fresh boot.

@xoseperez
Copy link
Owner Author

Original comment by dscoolx6 (Bitbucket: dscoolx6, GitHub: dscoolx6):


Hi guys, ive been breaking my head over this issue with 1.6.9! I have 3 SONOFF basics and 3 DUALs, the stuck-in-AP issue is seen only on mains power, stupid green LED keeps blinking forever. I do not see any issue with DC power. I also didnt see this issue on 1.50 (which is what i was using since it was released. The reason i wanted to update the firmware was to use OTA. After much struggle, i can flash the firmware over OTA but not the spiffs! Uhhh.

@xoseperez
Copy link
Owner Author

Original comment by dscoolx6 (Bitbucket: dscoolx6, GitHub: dscoolx6):


Update: The SONOFF basics benefit from leaving them disconnected for a few minutes. I see them connecting to my router (in DHCP mode) for a while, but the darn green LED starts fast-blinking soon after.

@xoseperez
Copy link
Owner Author

Original comment by dscoolx6 (Bitbucket: dscoolx6, GitHub: dscoolx6):


Update #2, tried with static IP settings - does not work

@xoseperez
Copy link
Owner Author

Original comment by Garoyuki (Bitbucket: doughnut_eater, GitHub: Unknown):


Although I use espuruna for I AI-Thinker Wifi Light, the problem witch is same with Aaron's one happens. AI-Thinker bulb connects router, and gets ip address. However, it disconnects soon. Sometimes it returns html, but in almost cases it does not show anything because it's has been disconnected.

@xoseperez
Copy link
Owner Author

Original comment by gulfmeister (Bitbucket: gulfmeister, GitHub: Unknown):


There is no difference in the code between SLAMPHER and SONOFF flags.
So, the problem is somewhere else.

@xoseperez
Copy link
Owner Author

Original comment by f-fish (Bitbucket: f-fish, GitHub: Unknown):


Hmm flashed some new basic's with 1.8.1 had no issue, what I did notice if your dhcp server is slow in getting an IP to the device a hard reboot is needed and then the second time I got dhcp no issues.

My IoT network is a separate AP device but the DHCP server is still on my primary network / gateway ..

Later Ferdie

@xoseperez
Copy link
Owner Author

Original comment by Garoyuki (Bitbucket: doughnut_eater, GitHub: Unknown):


I found that my AI-Thinker Wifi Light also connected to wifi router and obtained IP address by changing wifi router's setting. Encryption mode: WPA-PSK and WPA and WPA protocol: TKIP allows my light bulb to connect wifi router. WPA2-PSK/WPA-PSK/AES combination does not work. I confirmed this with 1.8.1.

@xoseperez
Copy link
Owner Author

Original comment by Simon Coggins (Bitbucket: cernnunos, GitHub: cernnunos):


I have the same issue with my Sonoff Basics.

Have seven of them in total. First worked fine. Second got really hot after reboot and burnt out, completely dead now. 3 through 7 all stuck in AP mode. Just keeps saying it failed to connect to Wi-Fi and falls back to AP. All have been working find with Ewelink.

Flash all 6 working ones with latest Tasmota and all 6 working happily on Wi-Fi.

Would say that since Tasmota works fine that it's a firmware issue. I just don't get why the first one worked perfectly.

@xoseperez
Copy link
Owner Author

Original comment by Sachin Filinto (Bitbucket: sfilinto, GitHub: sfilinto):


@cernnunos I faced the same problem. I erased and flashed it several time until each one connected to the Wi-Fi. Some devices took almost 6 tries to get connected to the wifi. All my devices are working now.

@xoseperez
Copy link
Owner Author

Original comment by dadja.sam (Bitbucket: dadja_sam, GitHub: Unknown):


My sonoff basic uses PN25F08B flash chip. Had to flash it in DOUT mode. Device stuck in AP mode. Tried to factory reset it few times but no use. AC power not helping.

@xoseperez
Copy link
Owner Author

Original comment by Alexander Micklewright (Bitbucket: alexmick, GitHub: alexmick):


Same problem here, two brand new Sonoff Basic, flashed with the latest as of today (1.8.3). On the first one I managed to get to the web interface to configure my wifi but it was very tedious, constantly disconnecting and even once it was configured it wouldn't connect to my wifi (I checked, I'm close enough). The second one I never managed to get onto the Wi-Fi, and having configured my Wi-Fi through console it also wouldn't connect.

The only thing that seemed bizarre or at least undocumented is that if I reboot the device through long press I periodically get chg_A3:-180 and chg_A3:0 log messages in the serial console just about everytime my computer fails to join the AP network.

Then I flashed Tasmota and it seems to work immediately so I don't think my devices are faulty.

Hope this report helps a bit...

@xoseperez
Copy link
Owner Author

Right now connection timeout is the main suspect here. I have had good results with a problematic Sonoff Basic allowing it more time to connect. Can anyone give it a try? Just add this code below to the top of the wifiConfigure method in wifi.ino:

jw.setConnectTimeout(30000);

@xoseperez
Copy link
Owner Author

Original comment by dadja.sam (Bitbucket: dadja_sam, GitHub: Unknown):


I set this config setting to wifi.ino

#!arduino

void wifiConfigure() {
    jw.setConnectTimeout(30000);
    jw.setHostname(getSetting("hostname", HOSTNAME).c_str());
    ....
    ....

Made a factory reset and set my wifi credintenals. Unfornutanely device is stiil in connection loop.

@xoseperez
Copy link
Owner Author

Original comment by Andrew Chappell (Bitbucket: andrewchappell, GitHub: Unknown):


So, I grabbed the latest dev branch with your change to this parameter, and have flashed two of my basics which previously wouldn't flash above 1.6 with no issues. If I'm feeling brave tomorrow I'll flash the one in the ceiling too!

Edit: And can confirm the ceiling one flashed perfectly as well - you might well have cracked it! :)

Cheers

Andy

@xoseperez
Copy link
Owner Author

Original comment by Axel Roest (Bitbucket: axello, GitHub: axello):


Same problem here.
I flashed an S20 and POW with Espurna, but could not get a standard Sonoff to connect to my wifi. In the end I flashed it with with ESPEasy and without any hiccups it connected to my wifi. Which happens to be on channel 9.

Today flashed 4 Sonoffs with ESPEasy (after trying again with Espurna) and no go. I flashed a POW with Espurna 1.7.1 and I can connect without any problem to the built-in AP, but it refuses to connect to my (Unifi) access point.

I set the setConnectTimeout to 30000, which did not make much difference.

The output of the serial log is simple, but it simply does not seem to accept the DHCP values. I can check with wireshark if anything special is happening, but all my other devices, and ESPEasy don't seem to have this problem.

Should I test with the dev branch instead of master?

#!text

[SETTINGS] EEPROM size: 4096 bytes
[SETTINGS] Settings size: 571 bytes
[WEBSERVER] Webserver running on port 80
[RELAY] Number of relays: 1
[BUTTON] Number of buttons: 1
[LED] Number of leds: 1
[LED] Led auto indicator is ON
[MAIN] Time: Time not set
[MAIN] Uptime: 0 seconds
[MAIN] Free heap: 27088 bytes
[ANALOG] Value: 88
[WIFI] Connecting to RoeRoe
[WIFI] Could not connect to RoeRoe
[WIFI] Creating access point
[WIFI] MODE AP --------------------------------------
[WIFI] SSID SONOFF_POW_2
[WIFI] PASS Wouldn't you like to know that
[WIFI] IP   192.168.4.1
[WIFI] MAC  2E:3A:E8:07:60:33
[WIFI] ----------------------------------------------
[MDNS] OK
[WEBSERVER] Request: GET /index.html
[WEBSERVER] Request: GET /auth
[WEBSERVER] Request: GET /auth
[WEBSOCKET] #1 connected, ip: 192.168.4.2, url: /ws
[ANALOG] Value: 62
[WEBSOCKET] Broadcasting '{"analogVisible": 1, "analogValue": 62}'
[WEBSOCKET] Parsing configuration data
[SETTINGS] Saving
[WEBSOCKET] Requested action: reconnect
[POW] Disabled
[WIFI] Disconnected
[POW] Disabled
[WIFI] Connecting to RoeRoe
[ANALOG] Value: 60
[WEBSOCKET] Broadcasting '{"analogVisible": 1, "analogValue": 60}'
[WEBSOCKET] #1 disconnected
[WIFI] Could not connect to RoeRoe
[WIFI] Creating access point
[WIFI] MODE STA -------------------------------------
[WIFI] SSID RoeRoe
[WIFI] IP   0.0.0.0
[WIFI] MAC  2C:3A:E8:07:60:33
[WIFI] GW   0.0.0.0
[WIFI] DNS  192.168.42.5
[WIFI] MASK 0.0.0.0
[WIFI] HOST ESP_076033
[WIFI] ----------------------------------------------
[MDNS] OK
[ANALOG] Value: 45
[ANALOG] Value: 60
[WIFI] Connecting to RoeRoe
[WIFI] Could not connect to RoeRoe
[WIFI] Creating access point
[WIFI] MODE STA -------------------------------------
[WIFI] SSID RoeRoe
[WIFI] IP   0.0.0.0
[WIFI] MAC  2C:3A:E8:07:60:33
[WIFI] GW   0.0.0.0
[WIFI] DNS  192.168.42.5
[WIFI] MASK 0.0.0.0
[WIFI] HOST ESP_076033
[WIFI] ----------------------------------------------
[MDNS] OK

@xoseperez
Copy link
Owner Author

Original comment by Axel Roest (Bitbucket: axello, GitHub: axello):


Update: Sonoff S20 works flawlessly first time:

[WIFI] Connecting to RoeRoe
[WIFI] MODE STA -------------------------------------
[WIFI] SSID RoeRoe
[WIFI] IP   192.168.42.200
[WIFI] MAC  5C:CF:7F:F9:4A:5D
[WIFI] GW   192.168.42.1
[WIFI] DNS  192.168.42.5
[WIFI] MASK 255.255.255.0
[WIFI] HOST S20_F94A5D

@xoseperez
Copy link
Owner Author

Original comment by Andrew Chappell (Bitbucket: andrewchappell, GitHub: Unknown):


Yeah, thinking about it I have changed my router since they previously wouldn't connect, so perhaps this is a WIFI AP specific thing?

Cheers

Andy

@xoseperez
Copy link
Owner Author

The Sonoff Basic looks like a tricky fellow.
Some people (https://tech.scargill.net/itead-slampher-and-sonoff/#comment-13742) have found out their WIFI connection problems disappear if they flash it using a 512K memory layout, even if the chip reports 1Mbit. My testing Sonoff is working like a champ since my last changes but maybe some of you having issues could give this a try?

From Arduino IDE you can select the "Flash Size" to 512Kb (0K SPIFFS)" or using PlatformIO you can change environment for the sonoff-debug in the platformio.ini file to use these build flags:

build_flags = ${common.build_flags_512k} -DSONOFF

@xoseperez
Copy link
Owner Author

Original comment by dadja.sam (Bitbucket: dadja_sam, GitHub: Unknown):


Tried to set 512Kb (0K SPIFFS), reflash and factory reset. My attempt was unsuccessful.

@xoseperez
Copy link
Owner Author

Original comment by Axel Roest (Bitbucket: axello, GitHub: axello):


I tried your suggestions above. One extra mention:

the flash on this Sonoff is a different manufacturer:

  • Manufacturer: 5e
  • Device: 4014

But the same problem occurs on Sonoffs with different flash ids.

One other interesting thing I noticed. Sometimes, the AP network does not default to
192.168.4.x, but 192.168.244.x ...

What I did
Branch master a042efb
I set jw.setConnectTimeout(30000); in wifi.ino

  • flashed with 1024K, 128 spiffs
    → Could flash, start up own api, could change device name, added network, but did not connect to my network.

  • flashed with 512K, no spiffs
    → Could flash 512K, checksum verified okay,
    → start up own api, could change device name, added network, but did not connect to network.

switched to latest dev commit 1346477

  • flashed with 512K, no spiffs
    → Could flash 512K, checksum verified okay,
    start up own api, could change device name, but did not connect to network.

  • flashed with 1024K, 128 spiffs
    → Could flash, start up own api, could change device name, but did not connect to network.

ESPurna 1.7.1
xose.perez@gmail.com
http://tinkerman.cat

ChipID: B4A8DB
CPU frequency: 80 MHz
Last reset reason: Power on
Memory size (SDK): 524288 bytes
Memory size (CHIP): 1048576 bytes
Free heap: 34032 bytes
Firmware size: 438944 bytes
Free firmware space: 61440 bytes


[SETTINGS] EEPROM size: 4096 bytes
[SETTINGS] Settings size: 477 bytes
[WEBSERVER] Webserver running on port 80
[RELAY] Number of relays: 1
[BUTTON] Number of buttons: 1
[LED] Number of leds: 1
[LED] Led auto indicator is ON
[MAIN] Time: Time not set
[MAIN] Uptime: 0 seconds
[MAIN] Free heap: 29048 bytes
[MAIN] Power: 3104 mV
[WIFI] Connecting to RoeRoe
[WIFI] Could not connect to RoeRoe
[WIFI] Creating access point
[WIFI] MODE AP --------------------------------------
[WIFI] SSID SONOFF_EXTRA_4
[WIFI] PASS ...
[WIFI] IP   192.168.4.1
[WIFI] MAC  5E:CF:7F:B4:A8:DB
[WIFI] ----------------------------------------------
[MDNS] OK

@xoseperez
Copy link
Owner Author

Version 1.9.0 adds some improvements and tweaks to the wifi connection manager.

@xoseperez
Copy link
Owner Author

Original comment by Patrizio Bekerle (Bitbucket: patbek, GitHub: patbek):


@xoseperez, thank you for this wonderful firmware!

I was hit by the same problem with my Sonoff Basic devices (using https://github.com/SensorsIot/Espurna-Framework, which is at version 1.6.9).
Using the latest Espurna 1.9.1 from git solved the wifi problem for me! Thanks a lot!

@xoseperez
Copy link
Owner Author

Original comment by Patrizio Bekerle (Bitbucket: patbek, GitHub: patbek):


Just a notice: Yesterday I tested with the master branch (where wifi did work after updating the external libraries), today I tested with the dev branch (I didn't update the external libraries) to get the new MQTT documentation and wifi didn't work there. master is still working. Maybe I did something wrong...

@xoseperez
Copy link
Owner Author

Original comment by gimi87 (Bitbucket: gimi87, GitHub: gimi87):


Hello :)

I have a weird issue with mine Sonoff-Basic device. Until 1.9.5 everything was ok. Currently (after upgrade from compiled latest dev) i am experiencing that one of two of mine devices is not connecting to the WiFi and turns into AP mode. While the second is working great. The router is between two devices away for about half meter.

What i noticed on the working (connected to WiFi) device:

  1. Hardware from Sonoff is without green soldered high voltage routes
  2. Woking very well, but constantly changing 11g/11b modes

What i noticed on the not working (as AP) device:

  1. Hardware from Sonoff is with green soldered high voltage routes and some additional ceramic SMD capacitor
  2. Working very well only in AP mode and sometimes it hangs and i have to enter to the AP mode by double clicking the button

Currently i changed the (AP mode) device to 1.9.5 version and is working very well.

Any clues?

@xoseperez
Copy link
Owner Author

Original comment by Patrizio Bekerle (Bitbucket: patbek, GitHub: patbek):


Try using the Wifi library (or header files? I can't remember) from the version that worked. That did it for me...

@xoseperez
Copy link
Owner Author

Really, some sonoff basic have ghost-like problems with the wifi that are hard to reproduce...

@xoseperez
Copy link
Owner Author

Original comment by gimi87 (Bitbucket: gimi87, GitHub: gimi87):


I admit that updating SDK to 2.1.0 resolves all mine Sonoff-Basic connection issues. I am currently up do date and everything is fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant