Wlan connection problem

rleibner
Posts: 2
Joined: Sat Jan 22, 2022 2:03 pm

Wlan connection problem

Postby rleibner » Sat Jan 22, 2022 2:56 pm

HI
I'm debugging a project that uses WLAN in the usual way:

Code: Select all

def do_connect():
    import network
    wlan = network.WLAN(network.STA_IF)
    wlan.active(True)
    if not wlan.isconnected():
        print('connecting to network...')
        wlan.config(reconnects=0)
        wlan.connect('myEissd', 'MyPwd')
        while not wlan.isconnected():
            print(5)
    print('network config:', wlan.ifconfig())
    
print(37)
do_connect()
print(38)

Note: The " print(n) " lines were included into the code only for tracking
Until 2 days ago, it was working fine. But now I get only this output:
>>> %Run -c $EDITOR_CONTENT
37
connecting to network...
ets Jun 8 2016 00:22:57

rst:0x8 (TG1WDT_SYS_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:4540
ho 0 tail 12 room 4
load:0x40078000,len:12344
ho 0 tail 12 room 4
load:0x40080400,len:4124
entry 0x40080680
W (61) boot.esp32: PRO CPU has been reset by WDT.
W (61) boot.esp32: WDT reset info: PRO CPU PC=0x400938fd
W (63) boot.esp32: WDT reset info: APP CPU PC=0x40093cb2

ets Jun 8 2016 00:22:57

Is it a hardware malfunction ?

ESP_Sprite
Posts: 9746
Joined: Thu Nov 26, 2015 4:08 am

Re: Wlan connection problem

Postby ESP_Sprite » Sun Jan 23, 2022 1:50 am

Could be a power supply issue... if you're powering your board from USB, do you happen to use a different USB cable or USB port?

rleibner
Posts: 2
Joined: Sat Jan 22, 2022 2:03 pm

Re: Wlan connection problem

Postby rleibner » Sun Jan 23, 2022 9:19 pm

Thanks @ESP_Sprite. You were right, the issue is solved with another USB cord :)
I spent hours searching for code errors !

Who is online

Users browsing this forum: Baidu [Spider] and 129 guests