5 Replies Latest reply on Dec 28, 2015 9:07 AM by jwyatt RSS
    jliu Newbie

    How to link Arduino Uno and ThingWorx by using REST API?

    Hi all. I'm doing the Weather App with Arduino Uno tutorial now but stuck with a weird problem. I followed all the instructions in the step1 of How to create the mashup for the Arduino Uno,  but didn't got the expected result. The gauge and the LED display should get data from the Arduino Uno and change after clicking the "Viewmashup", but they did't. I've checked the Arduino Uno that worked properly, it could send data successfully. And I also checked my setTempAndHumid service and AppKey, it could also work with no error. Is there anyone can help me out? Thanks a lot!

      • Re: How to link Arduino Uno and ThingWorx by using REST API?
        jwyatt Explorer

        I haven't personally been through that tutorial / guided-experience, but (just off the top of my head) have you confirmed that something is actually triggering your "setTempAndHumid" service?

         

        When you access this Service in the Mashup Editor via the green "+" symbol on the top-right, it can be quite easy to miss checking the "Mashup Loaded" box. If you don't later tie the Mashup's "Loaded" Event to the Service, then it never gets called, and it seems like nothing is working (because no logic is running).

         

        You can quickly check this by highlighting the "setTempAndHumid" Service in the Mashup Editor. When you do so, the connections to and from that Service will show up in your Connections window in the bottom-center. You'll almost certainly see the connections from this Service to your various Widgets (since you describe connecting them in your original post), but also confirm that something is leading *to* that Service from the left side.

         

        Once again, I haven't been through that guided-experience, so it may not be getting triggered via the Mashup -> Loaded Event. There may be some other mechanism. But there should be *something* triggering it.

         

        Thank you.

        Jason