These are chat archives for SmingHub/Sming

26th
Nov 2018
frankdownunder
@frankdownunder
Nov 26 2018 10:32
@slaff @mike Looks like the mqtt sample has problems.
connected with ssid, channel 1
dhcp client start...
3908183 connect to ssid ssid, channel 1

ip:192.168.100.103,mask:255.255.255.0,gw:192.168.100.1
5834156 ip:192.168.100.103,mask:255.255.255.0,gw:192.168.100.1
5834449

Connectting to  mqtt://m12.cloudmqtt.com:15983/
MQTT Broker Unreachable!!
8768786 Will must be set before connect
Connectting to  mqtt://m12.cloudmqtt.com:15983/
3ffefd10 already freed
3ffeff28 already freed
frankdownunder
@frankdownunder
Nov 26 2018 10:49
@frankdownunder I might add - the sample unchanged works OK,
but not with my own mqtt account , ("m12.cloudmqtt.com" mqttPort = "15983"),
which of course requires a username and password, which I supply by using this function to construct the URL
URL    getMqttUrl()
{
    URL url;
    {
        url.Protocol = _F("mqtt");
        url.Host = mqttHost;
        url.Port = atoi(mqttPort);
        url.User = mqttUsername;
        url.Password = mqttPwd;
    }
    return url;
}
slaff
@slaff
Nov 26 2018 11:36

8768786 Will must be set before connect

@frankdownunder The location of the setWill command should be before connect. I would recommend you to open a new ticket with your sample code (that we can reuse to test) with instructions how to create an account in cloudmqtt.com or provide us with a test one (the latter preferably sent via email or some other way)

riban-bw
@riban-bw
Nov 26 2018 12:58
I am struggling to send strings to arbitrary telnet session. writeString always returns -1.
slaff
@slaff
Nov 26 2018 21:02
@frankdownunder Problem confirmed -> Fix is on its way.
slaff
@slaff
Nov 26 2018 22:11
@frankdownunder Try this PR SmingHub/Sming#1539
It should solve your problem. Give it a try and let me know.