tag:blogger.com,1999:blog-36706321802012849.post8388757259516211682..comments2023-05-02T02:19:49.348-07:00Comments on kilomon: Creating Alexa Skills for IoT and Nodemcu - Part 2 AWS IoTDanhttp://www.blogger.com/profile/01422027852211426218noreply@blogger.comBlogger16125tag:blogger.com,1999:blog-36706321802012849.post-58452164968278870002019-02-19T16:22:09.781-08:002019-02-19T16:22:09.781-08:00Thanks for the article and am keen to see part 3 :...Thanks for the article and am keen to see part 3 :-) I've had no problem in connecting my esp8266 nodeMCU to AWS; albeit it took me too long to discover that there should not be a trailing '/' in the config:<br /> iotClient.setAWSPath("/things/mything/shadow/");<br />should be:<br /> iotClient.setAWSPath("/things/mything/shadow");<br /><br />Having said that, my implementation is also not stable using the libraries as suggested (version 2.3.0 and https://github.com/Schm1tz1/aws-sdk-arduino-esp8266). I've even used the AWS-SDK example code which failed after about 10 mins.Anonymoushttps://www.blogger.com/profile/11519877990804117259noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-51585835624004853422018-07-06T00:43:04.822-07:002018-07-06T00:43:04.822-07:00This comment has been removed by the author.tonitohttps://www.blogger.com/profile/15378528593649590563noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-31371027640351134322018-06-25T04:24:52.174-07:002018-06-25T04:24:52.174-07:00Hey Need to clarify some doubt like I have code fo...Hey Need to clarify some doubt like I have code for one of my wireless sensor but there is no library available in arduino then<br />How can I be able to integrate the code so that it will work with AWS platform ?<br /><br />for the reference this is my code <br />https://github.com/ControlEverythingCommunity/SHT25/blob/master/Arduino/SHT25.ino<br /><br />and want to use it with ESP8266 and AWS IOT client would it be possible to use ? Anonymoushttps://www.blogger.com/profile/09570681943494040332noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-10190840457364453192018-05-16T17:52:23.860-07:002018-05-16T17:52:23.860-07:00Outstanding article. The only snags I hit were:
1....Outstanding article. The only snags I hit were:<br />1. Not paying careful enough attention to the versions of various libraries and drivers.<br />2. Somehow I got through it without assigning permissions to my IOT user.<br />Now it's working fine!<br /><br />Thank you very much!!! Now on to part 3!Anonymoushttps://www.blogger.com/profile/11098433611875933167noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-10966747995155780402018-03-04T12:07:07.733-08:002018-03-04T12:07:07.733-08:00I will take a look at my setup to see if we can id...I will take a look at my setup to see if we can identify the discrepancy. Everything is still working for me. Danhttps://www.blogger.com/profile/01422027852211426218noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-2292157427689149892018-03-02T08:15:06.999-08:002018-03-02T08:15:06.999-08:00yes Ayrton. Same thing. I can see that it does con...yes Ayrton. Same thing. I can see that it does connect but nothing happens to the shadow. I have a feeling that AWS IoT has changed since this example and something else is needed that is not explained here. Unfortunately, AWS monitoring tools are terrible. Cloudwatch gives another way to monitor, but there is no telling if there was an error or what the request is actually doing. I also believe that the library used here has changed and depending where you et it will depend on our success. <br />For example, the Schm1tz1 version mentioned above had a buffer overflow problem in Client4.cpp. There are other changes but there is no way that I can see to instrument the process through the library. Turning on debug in Arduino does not show any errors. barthttps://www.blogger.com/profile/10848033125098365957noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-68866918019215049782018-02-28T03:31:34.524-08:002018-02-28T03:31:34.524-08:00I got the same problem, ESP8266 connect with AWS, ...I got the same problem, ESP8266 connect with AWS, but when navigate to Manage -> Things -> Your Thing -> Shadow didn't be updated. I Saw in AWS IoT Monitor that ESP8266 did the connection successfully, however it didn't publish anything.contato@hteccambioautomatico.com.brhttps://www.blogger.com/profile/07231019028743625802noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-33787681028694344832018-02-20T13:10:34.845-08:002018-02-20T13:10:34.845-08:00Dan,
I got rid of the stack dump y reloading https...Dan,<br />I got rid of the stack dump y reloading https://github.com/Schm1tz1/aws-sdk-arduino-esp8266 which is 10 commits ahead offuzzyhandle and had an update to AWSClient4 for buffer overflow.<br />So now it runs fine on the ESP8266 but I do not see updates to my thing shadow when I navigate to my "thing" shadow page. I get no errors on the connection even when I set debug to SSL+(everything there). ANy ideas how to troubleshoot are welcome. In the mean time I am going to create another "thing" and put it all in the sketch to see if it is in the thing or the sketch.barthttps://www.blogger.com/profile/10848033125098365957noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-81987721918046532092018-02-16T08:57:31.582-08:002018-02-16T08:57:31.582-08:00I tried going back to 2.3 but the stack trace rema...I tried going back to 2.3 but the stack trace remained. I believe my library is now the same as yours. It appears to run for one to to cycles but nothing shows up on the shadow. Still working it although it will be a couple of days before I can get back to it. <br />Thanks for the help.Barthttps://www.blogger.com/profile/14817303699262651779noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-5375503151867716172018-02-15T16:54:33.345-08:002018-02-15T16:54:33.345-08:00Could be library related. I am using https://githu...Could be library related. I am using https://github.com/Schm1tz1/aws-sdk-arduino-esp8266<br /><br />Also as noted in my steps use ESP8266 library 2.3.0. Version 2.4.0 was giving me issues with aws-sdk-arduino-esp8266 and some other libs.<br /><br />Danhttps://www.blogger.com/profile/01422027852211426218noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-74803999059200554812018-02-15T13:08:41.385-08:002018-02-15T13:08:41.385-08:00FYI - I got my libraries from:
https://github.com...FYI - I got my libraries from:<br /> https://github.com/fuzzyhandle/aws-sdk-arduino-esp8266barthttps://www.blogger.com/profile/10848033125098365957noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-5344582969883521182018-02-15T12:07:00.527-08:002018-02-15T12:07:00.527-08:00Thanks Dan. That got rid of the SSL error but I do...Thanks Dan. That got rid of the SSL error but I don't see the shadow updating and I still get a stack trace dump after the second connect. Screen looks like this:<br /><br />a3vdyjzlnwxobi.iot.us-east-1.amazonaws.com<br />443<br />POST /things/mything/shadow/ HTTP/1.1<br />Content-Type: application/json<br />Connection: close<br />Content-Length: 55<br />Host: xxxxxxxxxxxxxxxx.iot.us-east-1.amazonaws.com<br />x-amz-content-sha256: bdb51165355e3b0891aad7a217b3aa5749df14a0c02646a05bd47b0044c1b012<br />x-amz-date: 20180215T200125Z<br />Authorization: AWS4-HMAC-SHA256 Credential=ABCD...............EFGH/20180215/us-east-1/iotdata/aws4_request,SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date,Signature=c1ac10a3b64453e45678901254b26c424d6c73e17ce2f74346108559ab7e100f<br /><br />{"state":{"reported":{"temperature":66,"humidity":35}}}<br /><br />I hard coded the temp and hum variables just to try the sketch.<br /><br /><br /><br /><br />Exception (29):<br />epc1=0x4010443e epc2=0x00000000 epc3=0x00000000 excvaddr=0x00000000 depc=0x00000000<br /><br />ctx: cont <br />sp: 3fff0610 end: 3fff0b60 offset: 01a0<br /><br /><br />Could my libraries be different than yours?<br /><br />Bobbarthttps://www.blogger.com/profile/10848033125098365957noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-35683904192370739942018-02-15T11:39:42.702-08:002018-02-15T11:39:42.702-08:00"iotClient.setAWSDomain("arn:aws:iot:us-..."iotClient.setAWSDomain("arn:aws:iot:us-east1:123456789059:thing/mything");"<br /><br />Change the ARN to the API Endpoint for the Thing: <br />Go to your Thing in IoT > Manage > Things > your_thing > Interact<br />There should be a HTTPS Endpoint. Copy and replace your ARN above.Danhttps://www.blogger.com/profile/01422027852211426218noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-17019372485584988752018-02-15T11:28:12.638-08:002018-02-15T11:28:12.638-08:00Hi Dan.
I don't see anything wrong in the AWS ...Hi Dan.<br />I don't see anything wrong in the AWS section:<br /><br />IotClient.setAWSRegion("us-east-1");<br /> iotClient.setAWSEndpoint("amazonaws.com");<br /> iotClient.setAWSDomain("arn:aws:iot:us-east-1:123456789059:thing/mything");<br /> iotClient.setAWSPath("/things/mything/shadow/");<br /> iotClient.setAWSKeyID("ACDEFGHIJKLMNOPQRST");<br /> iotClient.setAWSSecretKey("1o2o3o4o5o6o7o8o9o1o2G+sK5OSme6P3tsSPI");<br /> iotClient.setHttpClient(&httpClient);<br /> iotClient.setDateTimeProvider(&dateTimeProvider);<br /><br />Could I have an old library? Where did you get your AWS and AmazonIOTClient files from?<br /><br />The security policy looks the same as you instructed (but hard to tell exactly).<br /><br />Thanks.barthttps://www.blogger.com/profile/10848033125098365957noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-81032404434933560902018-02-15T10:41:55.354-08:002018-02-15T10:41:55.354-08:00It sounds like your authentication to AWS IoT is f...It sounds like your authentication to AWS IoT is failing. Double check the values in the "iotClient" section of the sketch. Also verify your security policy in IAM.Danhttps://www.blogger.com/profile/01422027852211426218noreply@blogger.comtag:blogger.com,1999:blog-36706321802012849.post-60184670898842003782018-02-15T10:25:46.764-08:002018-02-15T10:25:46.764-08:00The sample code for the ESP runs briefly then says...The sample code for the ESP runs briefly then says: "can't setup SSL connection" then a stack trace...repeat...<br />Any thoughts?barthttps://www.blogger.com/profile/10848033125098365957noreply@blogger.com