• Ok I think I know what the issue is basically the write method has an issue with passing it functions. Feel free to look at the screenshot or logs below.

    When I pass LoopbackA.write("Hello"); , Hello is transmitted across ws.

    When I pass LoopbackB.write(digitalWrite(D5,1)); The LED is turned on, but the error below is given.

    When I pass LoopbackB.write(digitalWrite(D5,0)); The LED is turned off, but the error below is given.

    When I pass console.log("test"); test prints out to the ESPRUINO IDE but is not transmitted and the same error is given.

    I also tried directly passing console.log("test"); into LoopbackB but got the same error.

    Check out the attached screenshot, it's much easier to see.
    Console from ESPRUINO WEB IDE

    >LoopbackA.write("Hello");
    =undefined
    >LoopbackA.write(digitalWrite(D5,1));
    Uncaught TypeError: Expecting a number or something iterable, got undefined
     at line 1 col 35
    LoopbackA.write(digitalWrite(D5,1));
                                      ^
    > 
    

    CONSOLE FROM MY WEB APP

    >>Server:Ready!
    >>Hello
    

    1 Attachment

    • Screenshot from 2017-07-18 17:09:13.png
About

Avatar for Esper @Esper started