Broken connection to MQTT

#1

I tried to connect the egg to the WiFi, but it displays the error “Unable to connect to MQTT server” and I don’t know what to do. Any solution?

±-----------------------------------+
| Welcome to Air Quality Egg 2.0 |
| Particulate Sensor Suite |
| Firmware Version 2.2.2 |
±-----------------------------------+
Compiled on: Oct 26 2017 15:32:57
Egg Serial Number: egg0080301997080120

Info: Tiny Watchdog Initialization…OK.
Info: Slot Select Pins Initialization…OK.
Info: SPI Flash Initialization…OK.
Info: SD Card Initialization…Fail.
Info: Current firmware signature: 330343 7610
Info: SHT25 Initialization…OK.
Info: BMP280 Initialization…Fail.
Info: RTC Initialization…Fail.
Info: ESP8266 Initialization…OK.
Enter ‘aqe’ for CONFIG mode.
OPERATIONAL mode automatically begins after 12 secs of no input.
11…10…9…8…7…6…5…4…3…2…1…0…

-~=* In OPERATIONAL Mode *=~-
Info: Beginning Network Scan…
Info: Network Scan found 23 networks
Info: Access Point “Censores”, Not Found.
Info: Attempting to connect anyway.
Info: Connecting to Access Point with SSID “Censores”…OK.
Info: Request DHCP…OK.
Info: IP Addr: 172.22.125.53
Info: Netmask: 255.255.252.0
Info: Gateway: 172.22.127.254
Info: Mirrored configuration already matches current configuration.
Info: Resolved “update.wickeddevice.com” to IP address 45.55.159.249
Info: -------------------------------------
Info: Integrity Checks:
Info: File Size: 330343
Info: CRC16 Checksum: 7610

Info: Download Complete
Info: Total Bytes: 495
Info: File Size: 11
Info: Checksum: 36125
Info: Duration: 5633
Info: Signature matches, skipping HEX download.
Info: Current ESP8266 Firmware Version is 1060200
Info: ESP8266 Firmware Version is up to date
Info: Resolved “mqtt.wickeddevice.com” to IP address 104.236.234.98
Info: Connecting to MQTT Broker with Client ID “egg0080301997080120” using Authentication…Failed.
Error: Unable to connect to MQTT server
Info: Attempting Watchdog Forced Restart.

#2

Hi Mosh,

Can you tell me a little about your egg? Where are you connecting from?

The most likely thing is that your local network is blocking MQTT traffic for some reason.

Cheers
Dirk

#3

I’m trying to connect from a college WLAN using the egg serial configurator app for windows. I have read in this forum that the egg needs to be registered somewhere using the serial (egg0080301997080120), but I’m not sure how in the mentioned site ( opensensors.io).

#4

@Mosh Please can you DM me with the output from typing the aqe command in the console (which should dump all the settings to the screen)?

#5

@Mosh we’ll probably be able to help you more efficiently if you contact support at ariqualityegg dot com with a reference to this thread. Please include in that email a copy of the output from typing aqe and arriving at the AQE>: prompt on the Egg.

#6

@vicatcu Thanks for helping, this is the output

+------------------------------------+
 |   Welcome to Air Quality Egg 2.0   |
 |      Particulate Sensor Suite      |
 |       Firmware Version 2.2.2       |
 +------------------------------------+
 Compiled on: Oct 26 2017 15:32:57
 Egg Serial Number: egg0080301997080120

Info: Tiny Watchdog Initialization...OK.
Info: Slot Select Pins Initialization...OK.
Info: SPI Flash Initialization...OK.
Info: SD Card Initialization...Fail.
Info: Current firmware signature: 330343 7610
Info: SHT25 Initialization...OK.
Info: BMP280 Initialization...Fail.
Info: RTC Initialization...Fail.
Info: ESP8266 Initialization...OK.
Enter 'aqe' for CONFIG mode.
OPERATIONAL mode automatically begins after 12 secs of no input.
11...10...9...8...7...6...5...4...3...2...1...0...

-~=* In OPERATIONAL Mode *=~-
Info: Beginning Network Scan...
Info: Network Scan found 29 networks
Info: Access Point "Censores", Not Found.
Info: Attempting to connect anyway.
Info: Connecting to Access Point with SSID "Censores"...OK.
Info: Request DHCP...OK.
Info: IP Addr: 172.22.124.98
Info: Netmask: 255.255.252.0
Info: Gateway: 172.22.127.254
Info: Mirrored configuration already matches current configuration.
Info: Resolved "update.wickeddevice.com" to IP address 45.55.159.249
Info: -------------------------------------
Info: Integrity Checks: 
Info:    File Size: 330343
Info:    CRC16 Checksum: 7610

Info: Download Complete
Info: Total Bytes: 495
Info: File Size: 11
Info: Checksum: 36125
Info: Duration: 5239
Info: Signature matches, skipping HEX download.
Info: Current ESP8266 Firmware Version is 1060200
Info: ESP8266 Firmware Version is up to date
Info: Resolved "mqtt.wickeddevice.com" to IP address 104.236.234.98
Info: Connecting to MQTT Broker with Client ID "egg0080301997080120" using Authentication...Failed.
Error: Unable to connect to MQTT server
Info: Attempting Watchdog Forced Restart.
#7

@vicatcu And this is with the “aqe” command

 -~=* In CONFIG Mode *=~-
OPERATIONAL mode begins automatically after 5 mins without input.
Enter 'help' for a list of available commands, 
get settings
 +-------------------------------------------------------------+
 | Preferences/Options:                                        |
 +-------------------------------------------------------------+
    Operational Mode: Normal
    Temperature Units: Celsius
    Backlight Settings: 60 seconds, ON at startup
    Sensor Sampling Interval: 5 seconds
    Sensor Averaging Interval: 60 seconds
    Sensor Reporting Interval: 60 seconds
    SoftAP Config: Enabled
 +-------------------------------------------------------------+
 | Location Settings:                                          |
 +-------------------------------------------------------------+
    User Location: Disabled
    GPS: Not installed
    User Latitude: Not set
    User Longitude: Not set
    User Altitude: Not set
 +-------------------------------------------------------------+
 | Network Settings:                                           |
 +-------------------------------------------------------------+
    MAC Address: 5C:CF:7F:19:81:CA
    Method: Direct Connect
    SSID: Censores
    Security Mode: Automatic - Not Yet Determined
    IP Mode: Configured for DHCP
    Update Server: update.wickeddevice.com
    Update Filename: aqev2_pm_esp
    NTP Server: Disabled
    NTP TZ Offset: 0.000000000
 +-------------------------------------------------------------+
 | MQTT Settings:                                              |
 +-------------------------------------------------------------+
    MQTT Server: mqtt.wickeddevice.com
    MQTT Port: 1883
    MQTT Client ID: egg0080301997080120
    MQTT Authentication: Enabled
    MQTT Username: egg0080301997080120
    MQTT Topic Prefix: /orgs/wd/aqe/
    MQTT Topic Suffix: Enabled
 +-------------------------------------------------------------+
 | Credentials:                                                |
 +-------------------------------------------------------------+
    MQTT Password backed up? [* means no]
    Private key backed up? [* means no]
 +-------------------------------------------------------------+
 | Sensor Calibrations:                                        |
 +-------------------------------------------------------------+
    PM Offset [V]: 0.149741792
    PM Baseline Voltage Characterization:
        idx	temp [degC]	slope [V/degC]	intercept [V]
        ---------------------------------------------------------
        No valid entries found.
    Temperature Reporting Offset [degC]: 3.25
    Humidity Reporting Offset [%]: -5.06
 +-------------------------------------------------------------+
 | note: '*' next to label means the setting is not backed up. |
 |     run 'backup all' when you are satisfied                 |
 +-------------------------------------------------------------+
AQE>: 
 @=============================================================@
 # GETTING STARTED                                             #
 #-------------------------------------------------------------#
 #   First type 'ssid your_ssid_here' and & press <enter>      #
 #   Then type 'pwd your_network_password' & press <enter>     #
 #   Then type 'get settings' & press <enter> to review config #
 #   Finally, type 'exit' to go into OPERATIONAL mode,         #
 #     and verify that the Egg connects to your network!       #
 @=============================================================@
AQE>:
#8

Thanks, I’ll send you an email to try and resolve this with you outside the forum, since it might require discussing the Egg MQTT password, which we should avoid doing in a public forum.