You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To view the commands for a given sample, run the compiled program and pass `--help`.
28
+
29
+
```
30
+
./basic-pub-sub --help
31
+
```
32
+
27
33
#### Note
28
34
29
35
*`-DCMAKE_PREFIX_PATH` needs to be set to the path aws-iot-device-sdk-cpp-v2 installed. Since [Installation](../README.md#Installation) takes sdk-cpp-workspace as an example, here takes that as an example too.
@@ -172,6 +178,16 @@ This is a starting point for using custom
172
178
173
179
source: `samples/mqtt/raw_pub_sub/main.cpp`
174
180
181
+
To run the Raw MQTT Pub-Sub sample use the following command:
182
+
183
+
``` sh
184
+
./raw-pub-sub --endpoint <endpoint> --ca_file <path to root CA1>
185
+
--cert <path to the certificate> --key <path to the private key>
186
+
--topic <topic name> --user_name <user name to send on connect> --password <password to send on connect>
187
+
```
188
+
189
+
This will allow you to run the program. To disconnect and exit the program, enter `exit`.
190
+
175
191
## Shadow
176
192
177
193
This sample uses the AWS IoT
@@ -253,6 +269,16 @@ and receive.
253
269
</pre>
254
270
</details>
255
271
272
+
To run the Shadow sample use the following command:
273
+
274
+
``` sh
275
+
./shadow-sync --endpoint <endpoint> --ca_file <path to root CA1>
276
+
--cert <path to the certificate> --key <path to the private key>
See the [Basic job policy example](https://docs.aws.amazon.com/iot/latest/developerguide/basic-jobs-example.html) page for another policy example.
325
355
</details>
326
356
357
+
To run the job sample use the following command:
358
+
359
+
``` sh
360
+
./describe-job-execution --endpoint <endpoint> --ca_file <path to root CA1>
361
+
--cert <path to the certificate> --key <path to the private key>
362
+
--thing_name <thing name> --job_id <the job id>
363
+
```
364
+
365
+
Note that if you get a `Service Error 4 occurred` error, you may have incorrectly input the job id. The job id needs to exactly match the job id in the AWS console.
0 commit comments