aws-iot

Nuxt + IOT (aws-iot-device-sdk)

柔情痞子 提交于 2021-02-10 19:57:25
问题 I create a plugin like this: var awsIot = require('aws-iot-device-sdk') var device = awsIot.device({ keyPath: 'xxxxxx, certPath: 'xxxxxx, caPath: 'xxxxxx', clientId: 'xxxxx', region: 'xxxxxx', host: 'xxxxxxxxxx.amazonaws.com' }) It works, but displays an error message: C:\Sistemas\AM\nodemodules\aws-iot-device-sdk\common\lib\tls-reader.js:89 Uncaught TypeError: filesys.existsSync is not a function at webpackJsonp../nodemodules/aws-iot-device-sdk/common/lib/tls-reader.js.module.exports How can

Uncaught TypeError: filesys.existsSync is not a function

无人久伴 提交于 2021-02-10 18:57:02
问题 When trying to initialize IOT device using AWS IoT SDK for JavaScript, its giving error TypeError: filesys.existsSync is not a function var device = AWSIoTData.device({ keyPath: "././assets/certificate/xx", certPath: "././assets/certificate/xx", caPath: "././assets/certificate/xx", clientId: "xx", host: "xx", region: "xx", port: 8883, debug: true }); How come tls-reader.js has this undefined function? 回答1: If your trying to work with aws-iot-sdk with browser this will not work as expected. In

Uncaught TypeError: filesys.existsSync is not a function

风格不统一 提交于 2021-02-10 18:50:21
问题 When trying to initialize IOT device using AWS IoT SDK for JavaScript, its giving error TypeError: filesys.existsSync is not a function var device = AWSIoTData.device({ keyPath: "././assets/certificate/xx", certPath: "././assets/certificate/xx", caPath: "././assets/certificate/xx", clientId: "xx", host: "xx", region: "xx", port: 8883, debug: true }); How come tls-reader.js has this undefined function? 回答1: If your trying to work with aws-iot-sdk with browser this will not work as expected. In

MQTT topic names for request/response

南笙酒味 提交于 2021-01-29 00:09:43
问题 I'm designing a system with many devices using MQTT to connect to a central broker. There are some masters that can send requests to certain devices that are slaves. The request from one master is usually directed to one slave. The topic for requests could be: mysystem/slaveId/req , so the slaves can subscribe to this topic and master publishes to the same topic. Only the addressed slave will receive the request, as it should be. My question is how to decide the topic for responses. I'm in

MQTT topic names for request/response

人走茶凉 提交于 2021-01-29 00:09:23
问题 I'm designing a system with many devices using MQTT to connect to a central broker. There are some masters that can send requests to certain devices that are slaves. The request from one master is usually directed to one slave. The topic for requests could be: mysystem/slaveId/req , so the slaves can subscribe to this topic and master publishes to the same topic. Only the addressed slave will receive the request, as it should be. My question is how to decide the topic for responses. I'm in

MQTT topic names for request/response

不问归期 提交于 2021-01-28 23:55:38
问题 I'm designing a system with many devices using MQTT to connect to a central broker. There are some masters that can send requests to certain devices that are slaves. The request from one master is usually directed to one slave. The topic for requests could be: mysystem/slaveId/req , so the slaves can subscribe to this topic and master publishes to the same topic. Only the addressed slave will receive the request, as it should be. My question is how to decide the topic for responses. I'm in

How Can I Publish File to AWS- IoT using Mosquitto in Python

一个人想着一个人 提交于 2021-01-28 22:56:43
问题 I am trying to publish a file to AWS IoT using Mosquitto and python. The file i need to publish is a jpg file that is in my local directory. I have secret key and access key that are required to publish data to IoT. I am very new to programming and don't know how to write this program. can someone help me please? I apologize if this is something very basic. Thank you I have already tried this How can I publish a file using Mosquitto in python? and did not work for me. This is how i tired to

How Can I Publish File to AWS- IoT using Mosquitto in Python

心已入冬 提交于 2021-01-28 21:40:22
问题 I am trying to publish a file to AWS IoT using Mosquitto and python. The file i need to publish is a jpg file that is in my local directory. I have secret key and access key that are required to publish data to IoT. I am very new to programming and don't know how to write this program. can someone help me please? I apologize if this is something very basic. Thank you I have already tried this How can I publish a file using Mosquitto in python? and did not work for me. This is how i tired to

AWS - Is there a way to 'hook' into when a federated identity is created for the first time?

一曲冷凌霜 提交于 2021-01-27 20:01:56
问题 I have a Cognito Identity Pool that is used to authenticate my front end users, as well as give them certain permissions in my application. However, I have encountered an issue with giving these users permission to access IoT, which involves invoking a Lambda calling iot.addPrincipalPolicy() , and once that is done then everything works flawlessly. However, the issue I am facing is that right now I am running this function is being called every time my user requests authentication, when it

What is the simplest way to process WebSockets messages on AWS?

北战南征 提交于 2021-01-27 10:40:21
问题 What is a good way to deploy a WebSockets client on AWS? I'm building an app on AWS which needs to subscribe to several WebSockets and several REST sources and process incoming messages (WebSockets) or make periodic requests (REST). I'm trying to go server-less and maximize use of AWS platform services, to eliminate the need to manage VMs, OS patches, etc. (and hopefully reduce cost). My idea so far is to trigger a Lambda function every time a message arrives. The function can then transform