Avatar for user70979

user70979

Member since Dec 2016 • Last active Apr 2019
  • 1 conversations
  • 3 comments

Most recent activity

  • in JavaScript
    Avatar for user70979

    Thank you, Gordon. That worked.

    • 5 comments
    • 2,455 views
  • in JavaScript
    Avatar for user70979

    I am entering it on the right side.
    Actually, I can see the text of the error inside MQTT.min.js, line 9 col 201:
    "...t,a);a.connect();return a}});"

    Obviously it finds the module, tries to load it and because of syntax errors it fails to load it. Then in my code it reports that the module cannot be found:
    var mqtt = require("MQTT").create("192.168.1.10");

    Please try it if you can.

  • in JavaScript
    Avatar for user70979

    Trying to load MQTT on ESP8266/Espruino reports an error. Here is what I put in the IDE:

    var mqtt = require("MQTT").create("192.168.1.10");

    when I try to upload this script I get:

    Uncaught Error: Both arguments to addCached must be strings
    at line 9 col 201
    ...t,a);a.connect();return a}});

                              ^
    

    WARNING: Module "MQTT" not found
    Uncaught Error: Field or method "create" does not already exist, and can't create it on undefined
    at line 1 col 27
    var mqtt = require("MQTT").create("192.168.1.10");

                          ^
    

    =undefined


    I opened to see where the error is, and it definitely reports on something inside MQTT.min.js . Please help.

    Thanks,
    Jordan

Actions