Microchip® Advanced Software Framework

aws_iot_config.h File Reference

MAIN configuration.

AWS IoT specific configuration file.

Copyright (c) 2017-2018 Microchip Technology Inc. and its subsidiaries.

Macros

#define AWS_IOT_CERTIFICATE_FILENAME   " "
 
#define AWS_IOT_MQTT_CLIENT_ID   "SAMD21_MQTT"
 
#define AWS_IOT_MQTT_HOST   "AGOO5J5NTHNQB.iot.us-west-2.amazonaws.com"
 
#define AWS_IOT_MQTT_MAX_RECONNECT_WAIT_INTERVAL   8000
 Maximum time interval after which exponential back-off will stop attempting to reconnect. More...
 
#define AWS_IOT_MQTT_MIN_RECONNECT_WAIT_INTERVAL   1000
 Minimum time before the First reconnect attempt is made as part of the exponential back-off algorithm. More...
 
#define AWS_IOT_MQTT_NUM_SUBSCRIBE_HANDLERS   5
 Maximum number of topic filters the MQTT client can handle at any given time. This should be increased appropriately when using Thing Shadow. More...
 
#define AWS_IOT_MQTT_PORT   8883
 
#define AWS_IOT_MQTT_RX_BUF_LEN   512
 Any message that comes into the device should be less than this buffer size. If a received message is bigger than this buffer size the message will be dropped. More...
 
#define AWS_IOT_MQTT_TX_BUF_LEN   512
 Any time a message is sent out through the MQTT layer. The message is copied into this buffer anytime a publish is done. This will also be used in the case of Thing Shadow. More...
 
#define AWS_IOT_MY_THING_NAME   "SAMD21_MQTT"
 
#define AWS_IOT_PRIVATE_KEY_FILENAME   " "
 
#define AWS_IOT_ROOT_CA_FILENAME   " "
 
#define MAX_ACKS_TO_COMEIN_AT_ANY_GIVEN_TIME   10
 At Any given time we will wait for this many responses. This will correlate to the rate at which the shadow actions are requested. More...
 
#define MAX_JSON_TOKEN_EXPECTED   120
 These are the max tokens that is expected to be in the Shadow JSON document. Include the metadata that gets published. More...
 
#define MAX_SHADOW_TOPIC_LENGTH_BYTES   MAX_SHADOW_TOPIC_LENGTH_WITHOUT_THINGNAME + MAX_SIZE_OF_THING_NAME
 This size includes the length of topic with Thing Name. More...
 
#define MAX_SHADOW_TOPIC_LENGTH_WITHOUT_THINGNAME   60
 All shadow actions have to be published or subscribed to a topic which is of the format $aws/things/{thingName}/shadow/update/accepted. This refers to the size of the topic without the Thing Name. More...
 
#define MAX_SIZE_CLIENT_ID_WITH_SEQUENCE   MAX_SIZE_OF_UNIQUE_CLIENT_ID_BYTES + 10
 This is size of the extra sequence number that will be appended to the Unique client Id. More...
 
#define MAX_SIZE_CLIENT_TOKEN_CLIENT_SEQUENCE   MAX_SIZE_CLIENT_ID_WITH_SEQUENCE + 20
 This is size of the the total clientToken key and value pair in the JSON. More...
 
#define MAX_SIZE_OF_THING_NAME   20
 The Thing Name should not be bigger than this value. Modify this if the Thing Name needs to be bigger. More...
 
#define MAX_SIZE_OF_UNIQUE_CLIENT_ID_BYTES   80
 Maximum size of the Unique Client Id. For More info on the Client Id refer Acknowledgments. More...
 
#define MAX_THINGNAME_HANDLED_AT_ANY_GIVEN_TIME   10
 We could perform shadow action on any thing Name and this is maximum Thing Names we can act on at any given time. More...
 
#define SHADOW_MAX_SIZE_OF_RX_BUFFER   AWS_IOT_MQTT_RX_BUF_LEN+1
 Maximum size of the SHADOW buffer to store the received Shadow message. More...
 

#define AWS_IOT_CERTIFICATE_FILENAME   " "
#define AWS_IOT_MQTT_CLIENT_ID   "SAMD21_MQTT"
#define AWS_IOT_MQTT_HOST   "AGOO5J5NTHNQB.iot.us-west-2.amazonaws.com"
#define AWS_IOT_MQTT_MAX_RECONNECT_WAIT_INTERVAL   8000

Maximum time interval after which exponential back-off will stop attempting to reconnect.

#define AWS_IOT_MQTT_MIN_RECONNECT_WAIT_INTERVAL   1000

Minimum time before the First reconnect attempt is made as part of the exponential back-off algorithm.

#define AWS_IOT_MQTT_NUM_SUBSCRIBE_HANDLERS   5

Maximum number of topic filters the MQTT client can handle at any given time. This should be increased appropriately when using Thing Shadow.

#define AWS_IOT_MQTT_PORT   8883
#define AWS_IOT_MQTT_RX_BUF_LEN   512

Any message that comes into the device should be less than this buffer size. If a received message is bigger than this buffer size the message will be dropped.

Referenced by aws_iot_mqtt_connect().

#define AWS_IOT_MQTT_TX_BUF_LEN   512

Any time a message is sent out through the MQTT layer. The message is copied into this buffer anytime a publish is done. This will also be used in the case of Thing Shadow.

Referenced by aws_iot_mqtt_connect().

#define AWS_IOT_MY_THING_NAME   "SAMD21_MQTT"
#define AWS_IOT_PRIVATE_KEY_FILENAME   " "
#define AWS_IOT_ROOT_CA_FILENAME   " "
#define MAX_ACKS_TO_COMEIN_AT_ANY_GIVEN_TIME   10

At Any given time we will wait for this many responses. This will correlate to the rate at which the shadow actions are requested.

Referenced by AckStatusCallback(), getNextFreeIndexOfAckWaitList(), HandleExpiredResponseCallbacks(), and initializeRecords().

#define MAX_JSON_TOKEN_EXPECTED   120

These are the max tokens that is expected to be in the Shadow JSON document. Include the metadata that gets published.

Referenced by initDeltaTokens(), and registerJsonTokenOnDelta().

#define MAX_SHADOW_TOPIC_LENGTH_BYTES   MAX_SHADOW_TOPIC_LENGTH_WITHOUT_THINGNAME + MAX_SIZE_OF_THING_NAME
#define MAX_SHADOW_TOPIC_LENGTH_WITHOUT_THINGNAME   60

All shadow actions have to be published or subscribed to a topic which is of the format $aws/things/{thingName}/shadow/update/accepted. This refers to the size of the topic without the Thing Name.

#define MAX_SIZE_CLIENT_ID_WITH_SEQUENCE   MAX_SIZE_OF_UNIQUE_CLIENT_ID_BYTES + 10

This is size of the extra sequence number that will be appended to the Unique client Id.

#define MAX_SIZE_CLIENT_TOKEN_CLIENT_SEQUENCE   MAX_SIZE_CLIENT_ID_WITH_SEQUENCE + 20

This is size of the the total clientToken key and value pair in the JSON.

Referenced by AckStatusCallback(), addToAckWaitList(), aws_iot_shadow_delete(), aws_iot_shadow_get(), and iot_shadow_action().

#define MAX_SIZE_OF_THING_NAME   20

The Thing Name should not be bigger than this value. Modify this if the Thing Name needs to be bigger.

Referenced by addToAckWaitList(), and aws_iot_shadow_connect().

#define MAX_SIZE_OF_UNIQUE_CLIENT_ID_BYTES   80

Maximum size of the Unique Client Id. For More info on the Client Id refer Acknowledgments.

Referenced by aws_iot_shadow_connect().

#define MAX_THINGNAME_HANDLED_AT_ANY_GIVEN_TIME   10

We could perform shadow action on any thing Name and this is maximum Thing Names we can act on at any given time.

#define SHADOW_MAX_SIZE_OF_RX_BUFFER   AWS_IOT_MQTT_RX_BUF_LEN+1

Maximum size of the SHADOW buffer to store the received Shadow message.

Referenced by AckStatusCallback(), and shadow_delta_callback().