Cannot get WIFI to work on a new Duet3D WIFI



  • I have a new Duet3D 2 WIFI board and cannot get the WIFI to work.
    I keep getting:

    WiFi reported error: no known networks found
    WiFi module is idle
    

    On the physical WIFI module the blue led flashes once when the board gets power, and that is it. No more flashes at any other time.

    I updated the firmware with the files from the Release 2.03 (Duet 2 series), 1.24 (Duet 06/085) release.
    I used the M997 S0 and M997 S1 with the following files in the sys folder:
    Duet2CombinedFirmware.bin
    DuetWiFiServer.bin
    iap4e.bin

    M587 has two WIFI options (I have both available):

    COMEYSAFEHOUSE IP=10.240.0.240 GW=10.240.0.1 NM=255.255.255.0
    JEFFPIXEL IP=0.0.0.0 GW=0.0.0.0 NM=0.0.0.0
    

    Running M122 I get the following:

    === Diagnostics ===
    RepRapFirmware for Duet 2 WiFi/Ethernet version 2.03 running on Duet WiFi 1.02 or later
    Board ID: 08DGM-956GU-DGMSN-6J1F4-3S86T-1BR3G
    Used output buffers: 1 of 24 (10 max)
    === RTOS ===
    Static ram: 25680
    Dynamic ram: 93644 of which 0 recycled
    Exception stack ram used: 320
    Never used ram: 11428
    Tasks: NETWORK(ready,548) HEAT(blocked,1236) MAIN(running,3652) IDLE(ready,160)
    Owned mutexes:
    === Platform ===
    Last reset 00:05:01 ago, cause: software
    Last software reset time unknown, reason: User, spinning module GCodes, available RAM 11428 bytes (slot 1)
    Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0441f000 BFAR 0xe000ed38 SP 0xffffffff Task 0x4e49414d
    Error status: 0
    [ERROR] Error status: 0
    
    Free file entries: 10
    SD card 0 detected, interface speed: 20.0MBytes/sec
    SD card longest block write time: 0.0ms, max retries 0
    MCU temperature: min 32.2, current 33.3, max 33.5
    Supply voltage: min 24.3, current 24.4, max 24.5, under voltage events: 0, over voltage events: 0, power good: yes
    Driver 0: standstill, SG min/max not available
    Driver 1: standstill, SG min/max not available
    Driver 2: standstill, SG min/max not available
    Driver 3: standstill, SG min/max not available
    Driver 4: standstill, SG min/max not available
    Date/time: 1970-01-01 00:00:00
    Cache data hit count 742554272
    Slowest loop: 34.60ms; fastest: 0.08ms
    I2C nak errors 0, send timeouts 0, receive timeouts 0, finishTimeouts 0, resets 0
    === Move ===
    Hiccups: 0, FreeDm: 169, MinFreeDm: 169, MaxWait: 0ms
    Bed compensation in use: none, comp offset 0.000
    === DDARing ===
    Scheduled moves: 0, completed moves: 0, StepErrors: 0, LaErrors: 0, Underruns: 0, 0
    === Heat ===
    Bed heaters = 0 -1 -1 -1, chamberHeaters = -1 -1
    === GCodes ===
    Segments left: 0
    Stack records: 1 allocated, 0 in use
    Movement lock held by null
    http is idle in state(s) 0
    telnet is idle in state(s) 0
    file is idle in state(s) 0
    serial is ready with "M122" in state(s) 0
    aux is idle in state(s) 0
    daemon is idle in state(s) 0
    queue is idle in state(s) 0
    autopause is idle in state(s) 0
    Code queue is empty.
    === Network ===
    Slowest loop: 0.24ms; fastest: 0.00ms
    Responder states: HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) Telnet(0) Telnet(0)
    HTTP sessions: 0 of 8
    - WiFi -
    Network state is changing mode
    WiFi module is idle
    Failed messages: pending 0, notready 0, noresp 1
    Failed to get WiFi status
    Socket states: 0 0 0 0 0 0 0 0
    Error retrieving WiFi status message: bad reply format version
    [ERROR] Error retrieving WiFi status message: bad reply format version
    

    From what I have read the "[ERROR] Error retrieving WiFi status message: bad reply format version" error means a mismatch between the "DuetWiFiServer and the the Duet main firmware".

    With the M997 S0 and M997 S1 commands, I thought I would get the correct versions uploaded. Some additional information would be appreciated.

    Thank you!

    Jeff



  • Do you know which version of the wifi server firmware you have installed? Looks like v 1.23 and 1.24 should be compatible with main firmware 2.03

    Additionally make sure the network you are connecting to is 2.4GHz and not 5GHz. The esp chip only supports 2.4GHz networks.



  • I took the DuetWiFiServer.bin file from the same zip file of the 2.03 release. I got the Duet2CombinedFirmware.bin file from the same link.

    I am not sure how to check the version of the DuetWiFiServer.bin file.

    I hope that sheds some light on the issue.



  • Breifly looked at the 2.03 bundle and the wifi server version was 1.23, but not sure if there are better ways to tell which version the binary is, but on linux strings and grep usually works, not always as simple as grep version though.

    bearer@rama:/tmp  $ strings DuetWiFiServer.bin  | grep version
    version=1.23
    

  • administrators

    Are the SSIDs of your networks exactly as M587 reports them? SSIDs are case sensitive. Are they definitely broadcasting on 2.4GHz, and not hidden?



  • Maybe Wifi issues should be accompanied by a screenshot from an android/iphone app that shows wifi networks, channels, encryption types and signal strengths in the same location as the Duet. Its been a while since I've looked at those - but others may have up to date reccomendations.

    Back to topic;

    Error retrieving WiFi status message: bad reply format version
    [ERROR] Error retrieving WiFi status message: bad reply format version
    

    as jeff points out it suggests wrong versions, @dc42 would the firmware issue those messages if the versions were right but no networks were found, i.e. empty replies?


  • administrators

    @bearer said in Cannot get WIFI to work on a new Duet3D WIFI:

    Back to topic;

    Error retrieving WiFi status message: bad reply format version
    [ERROR] Error retrieving WiFi status message: bad reply format version
    

    as jeff points out it suggests wrong versions, @dc42 would the firmware issue those messages if the versions were right but no networks were found, i.e. empty replies?

    No. The only known reason for that message is mismatched firmware versions, however there have been a few reports of it, so I am starting to suspect a bug. Recommended workaround when you get it: send M552 S-1, then M552 S0, then try the original command again.



  • @dc42

    It looks like I got it to work. Here is what I ended up doing:

    The M552 S-1 followed by M552 S0 seems to reset the WIFI unit and now it reports the following with the M122 command:

    >>> M552 S-1
    SENDING:M552 S-1
    WiFi module stopped
    ok T0:2000.0 /0.0 B:2000.0 /0.0
    >>> M552 S0
    SENDING:M552 S0
    WiFi module started
    >>> M122
    SENDING:M122
    === Diagnostics ===
    RepRapFirmware for Duet 2 WiFi/Ethernet version 2.03 running on Duet WiFi 1.02 or later
    Board ID: 08DGM-956GU-DGMSN-6J1F4-3S86T-1BR3G
    Used output buffers: 1 of 24 (1 max)
    === RTOS ===
    Static ram: 25680
    Dynamic ram: 93644 of which 0 recycled
    Exception stack ram used: 308
    Never used ram: 11440
    Tasks: NETWORK(ready,1280) HEAT(blocked,1236) MAIN(running,3820) IDLE(ready,160)
    Owned mutexes:
    === Platform ===
    Last reset 00:01:52 ago, cause: power up
    Last software reset time unknown, reason: User, spinning module GCodes, available RAM 11428 bytes (slot 1)
    Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0441f000 BFAR 0xe000ed38 SP 0xffffffff Task 0x4e49414d
    Error status: 0
    [ERROR] Error status: 0
    
    Free file entries: 10
    SD card 0 detected, interface speed: 20.0MBytes/sec
    SD card longest block write time: 0.0ms, max retries 0
    MCU temperature: min 24.4, current 30.3, max 30.3
    Supply voltage: min 24.3, current 24.4, max 24.5, under voltage events: 0, over voltage events: 0, power good: yes
    Driver 0: standstill, SG min/max not available
    Driver 1: standstill, SG min/max not available
    Driver 2: standstill, SG min/max not available
    Driver 3: standstill, SG min/max not available
    Driver 4: standstill, SG min/max not available
    Date/time: 1970-01-01 00:00:00
    Cache data hit count 255064556
    Slowest loop: 99.46ms; fastest: 0.07ms
    I2C nak errors 0, send timeouts 0, receive timeouts 0, finishTimeouts 0, resets 0
    === Move ===
    Hiccups: 0, FreeDm: 169, MinFreeDm: 169, MaxWait: 0ms
    Bed compensation in use: none, comp offset 0.000
    === DDARing ===
    Scheduled moves: 0, completed moves: 0, StepErrors: 0, LaErrors: 0, Underruns: 0, 0
    === Heat ===
    Bed heaters = 0 -1 -1 -1, chamberHeaters = -1 -1
    === GCodes ===
    Segments left: 0
    Stack records: 1 allocated, 0 in use
    Movement lock held by null
    http is idle in state(s) 0
    telnet is idle in state(s) 0
    file is idle in state(s) 0
    serial is ready with "M122" in state(s) 0
    aux is idle in state(s) 0
    daemon is idle in state(s) 0
    queue is idle in state(s) 0
    autopause is idle in state(s) 0
    Code queue is empty.
    === Network ===
    Slowest loop: 1.25ms; fastest: 0.00ms
    Responder states: HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) Telnet(0) Telnet(0)
    HTTP sessions: 0 of 8
    - WiFi -
    Network state is running
    WiFi module is idle
    Failed messages: pending 0, notready 0, noresp 0
    WiFi firmware version 1.23
    WiFi MAC address dc:4f:22:6e:6f:a8
    WiFi Vcc 3.42, reset reason Turned on by main processor
    WiFi flash size 4194304, free heap 30176
    Socket states: 0 0 0 0 0 0 0 0
    

    I can now see the WIFI firmware version as 1.23.

    On WIFI Frequency. I have separate SSIDs for difference Frequency sets. So yes these are 2.4GHz networks.

    On the issue of Wifi SSIDs: They are not the same. There are lowercase letters in the SSIDs and I enter them as such with the M587 command. But when I check the list with the M587, all the characters are upper case. The same is happening to the Passwords. I discovered this when I added an SSID with all uppercase letters into my WIFI access point but with lowercase letters in the password. I was getting "WiFi reported error: Wrong password while trying to connect to JEFFPIXEL". I then created an uppercase password and now the system connects. The sequence of commands that I used are as follows:

    M552 S-1                          ---Stops the WIFI Module
    M552 S0                           ---Starts the WIFI Module
    M122                              ---Checks the status of the board (WIFI status at the bottom)
    M588                              ---Cleared all old SSIDs
    M587 S"" P""                      ---Entered the new SSID with uppercase SSID and password.
    ---I made sure to have a WIFI SSID and Password that matched all uppercase letters.
    M552 S1                           ---Connect to WIFI
    ---(After a few seconds)
    M122                              ---Check status of WIFI at the bottom
    

    The last command yielded the following for the WIFI section:

    - WiFi -
    Network state is running
    WiFi module is connected to access point
    Failed messages: pending 0, notready 0, noresp 0
    WiFi firmware version 1.23
    WiFi MAC address dc:4f:22:6e:6f:a8
    WiFi Vcc 3.42, reset reason Turned on by main processor
    WiFi flash size 4194304, free heap 25296
    WiFi IP address 10.240.0.240
    WiFi signal strength -51dBm, reconnections 0, sleep mode modem
    Socket states: 0 0 0 0 0 0 0 0
    

    I can now ping the board on the network.

    Thank you

    Jeff



  • @jeffvan302 said in Cannot get WIFI to work on a new Duet3D WIFI:

    On WIFI Frequency. I have separate SSIDs for difference Frequency sets. So yes these are 2.4GHz networks.

    Hi,

    Just out of curiosity why do you have separate SSIDs for different channels - I guess that is what you mean by "frequency sets".

    Frederick


  • administrators

    @jeffvan302 said in Cannot get WIFI to work on a new Duet3D WIFI:

    On the issue of Wifi SSIDs: They are not the same. There are lowercase letters in the SSIDs and I enter them as such with the M587 command. But when I check the list with the M587, all the characters are upper case. The same is happening to the Passwords. I discovered this when I added an SSID with all uppercase letters into my WIFI access point but with lowercase letters in the password. I was getting "WiFi reported error: Wrong password while trying to connect to JEFFPIXEL". I then created an uppercase password and now the system connects.

    That's because you are using the wrong program on your PC to connect via USB. The reason we tell you to use YAT (if using a Windows PC) is that common GCode senders such as Pronterface convert everything you enter to uppercase.

    Please check that you don't have any M587 or other network-related commands in config.g, other than M552 S1 to connect to the access point.



  • @fcwilt said in Cannot get WIFI to work on a new Duet3D WIFI:

    @jeffvan302 said in Cannot get WIFI to work on a new Duet3D WIFI:

    On WIFI Frequency. I have separate SSIDs for difference Frequency sets. So yes these are 2.4GHz networks.

    Hi,

    Just out of curiosity why do you have separate SSIDs for different channels - I guess that is what you mean by "frequency sets".

    Frederick

    It just makes it a lot easier to know if you are connected to 5Ghz or 2.4Ghz. On my cell phone I can forget the 2.4GHz name and just connect to the 5GHz name. That way I know I am always on 5GHz. It really is just an easy diagnostic tool. It also allows you to know if any device can only connect to 2.4GHz, if all that is available is the 2.4GHz SSIDs.



  • @dc42 said in Cannot get WIFI to work on a new Duet3D WIFI:

    @jeffvan302 said in Cannot get WIFI to work on a new Duet3D WIFI:

    On the issue of Wifi SSIDs: They are not the same. There are lowercase letters in the SSIDs and I enter them as such with the M587 command. But when I check the list with the M587, all the characters are upper case. The same is happening to the Passwords. I discovered this when I added an SSID with all uppercase letters into my WIFI access point but with lowercase letters in the password. I was getting "WiFi reported error: Wrong password while trying to connect to JEFFPIXEL". I then created an uppercase password and now the system connects.

    That's because you are using the wrong program on your PC to connect via USB. The reason we tell you to use YAT (if using a Windows PC) is that common GCode senders such as Pronterface convert everything you enter to uppercase.

    Please check that you don't have any M587 or other network-related commands in config.g, other than M552 S1 to connect to the access point.

    Thank you for the info on YAT.

    I only had the M552 S1 in the config.g file at first (No M587), while the issues were occurring.

    I have since the last test added the following:

    M552 S-1					   ; Stop WIFI Module
    G4 P2000				           ; Wait 2 seconds
    M552 S0						   ; Start WIFI Module
    G4 P2000				           ; Wait 2 seconds
    M552 S1
    

    And now it boots and connects to the network without any issues.

    Let me know if I should make any changes.

    Thank you!!!

    Jeff


  • administrators

    I am surprised that adding those commands makes any difference, because the M552 commands get deferred until config.g has completed. Or at least, that's what is supposed to happen. Are you sure it still doesn't work with just M552 S1 in config.g?



  • @dc42 said in Cannot get WIFI to work on a new Duet3D WIFI:

    I am surprised that adding those commands makes any difference, because the M552 commands get deferred until config.g has completed. Or at least, that's what is supposed to happen. Are you sure it still doesn't work with just M552 S1 in config.g?

    I removed the commands and just have M552 S1 now and it does still connect. I guess the M552 S-1 followed by M552 S0 was only needed after the firmware upgrade.

    Thank you.

    Jeff



  • This post is deleted!

Log in to reply