Connecting to mqtt broker... (ArduinoOS | LininoIO chaos_calmer 2.0)

Hi, I am trying the Arduino Cloud and uploaded the sample sketch for a simple thing with a simple CloudLedStatus.

At very first, I was using 1.5.3 images.

Following https://www.arduino.cc/en/Tutorial/YunSysupgrade bricked the Yún

Yún recovered using https://www.arduino.cc/en/Tutorial/YunUBootReflash.

U-Boot 1.1.5-linino-gc0f42dd0 (Jul 9 2016 - 12:23:30)

Booting image at 9fea0000 ...

Image Name: MIPS OpenWrt Linux-3.18.11
Created: 2016-07-09 14:30:02 UTC
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 1280860 Bytes = 1.2 MB
Load Address: 80060000
Entry Point: 80060000
Verifying Checksum at 0x9fea0040 ...OK
Uncompressing Kernel Image ... OK
No initrd
...

...

Then, load again sample sketch (attached on this post, without credentials) with a lot of "Serial.println()" for debugging, and still unable to connect mqtt broker...

Starting Bridge
Done
Starting Ejemplo
Done
Enabling debug
Done
Defining properties
Done
Polling Ejemplo
Connecting to mqtt broker...

I really appreciate your advice.

Best regards.

P.S.

Some Linino info:

uname -a

Linux ArduinoOS 3.18.11 #1 Sat Jul 9 16:29:39 CEST 2016 mips GNU/Linux

cat /etc/openwrt_version

2.0

cat /etc/openwrt_release

DISTRIB_ID='LininoIO'
DISTRIB_RELEASE='2.0'
DISTRIB_REVISION='r47374'
DISTRIB_CODENAME='chaos_calmer'
DISTRIB_TARGET='ar71xx/generic'
DISTRIB_DESCRIPTION='LininoIO chaos_calmer 2.0'
DISTRIB_TAINTS='no-all busybox'

pstree -pl

procd(1)-+-ash(630)---python(3486)
|-avahi-daemon(2418)
|-dbus-daemon(1972)
|-dnsmasq(1691)
|-dropbear(1828)---dropbear(2949)---ash(2967)---pstree(3497)
|-logd(1458)
|-netifd(1505)---udhcpc(1840)
|-ntpd(2510)
|-odhcpd(1527)
|-rpcd(1467)
|-shellinaboxd(1677)---shellinaboxd(1679)
|-uSDaemon(1546)---sleep(3496)
|-ubusd(566)
|-udevd(1517)-+-udevd(2298)
| -udevd(2312) |-uhttpd(1959) -wpa_supplicant(1714)

md5sum /usr/lib/python2.7/bridge/bridge.py

7ec6276a85fbff233985a0865eb98c6b /usr/lib/python2.7/bridge/bridge.py

top -bn1

Mem: 56628K used, 4080K free, 1056K shrd, 8024K buff, 14176K cached
CPU: 100% usr 0% sys 0% nic 0% idle 0% io 0% irq 0% sirq
Load average: 1.95 2.04 1.34 2/53 4789
PID PPID USER STAT VSZ %VSZ %CPU COMMAND
4788 630 root R 4088 7% 92% python -u bridge.py
...

Cloud.ino (1.18 KB)

I had the same experience, but haven't resolved it yet.

The library seems to call mqtt.arduino.cc on poll

/// Configurations
#define SERVER_DOMAIN "mqtt.arduino.cc"
#define SERVER_PORT 8883
#define PROPERTIES_MAX 10


void ArduinoCloudThing::poll() {
while (!client->isConnected()){
if (cloud_debug) {
CLOUD_DEBUG_STREAM.println("Connecting to mqtt broker...");
}
while (!connect()){
delay(1000);
}
if (cloud_debug) {
CLOUD_DEBUG_STREAM.println("Connected");
}
mqttSubscribe();
}
if(!network.connected() && client->isConnected()) {
client->disconnect();
}
client->yield();
}