You can use the integration standalone without an existing instance of nRF Asset Tracker for AWS <aws-getting-started>
.
Before you start setting up the Memfault integration for AWS, make sure that you fulfill the following prerequisites:
To clone the nRF Asset Tracker Memfault integration for AWS IoT project and install the dependencies, use the following commands:
- git clone --branch --single-branch \
https://github.com/NordicSemiconductor/asset-tracker-cloud-memfault-aws-js memfault-aws
cd memfault-aws
# Install the dependencies npm ci
You can retrieve the project settings from the settings page of the Memfault dashboard of your organization.
aws ssm put-parameter --type String --name /${STACK_NAME:-nrf-memfault}/thirdParty/memfault/projectKey --value <your memfault project key> aws ssm put-parameter --type String --name /${STACK_NAME:-nrf-memfault}/thirdParty/memfault/organization --value <your organization slug> aws ssm put-parameter --type String --name /${STACK_NAME:-nrf-memfault}/thirdParty/memfault/project --value <your project slug>
Administrators can access and manage the organization authorization token at Admin
> Organization Auth Tokens
in the Memfault UI.
aws ssm put-parameter --type String --name /${STACK_NAME:-nrf-memfault}/thirdParty/memfault/authToken --value <your auth token>
You can configure the topic that devices use to publish Memfault chunks through the CDK context variable memfaultTopic
. The topic defaults to +/memfault/#
.
To deploy the Memfault integration to your AWS account, run the following command:
npx cdk deploy
After a successful deployment, make sure that your devices are allowed to publish to the configured MQTT topic (<deviceId>/memfault
) by default. If you are using nRF Asset Tracker for AWS <aws-getting-started>
, this is already the case. Otherwise, refer to the AWS IoT Core Policies on how to configure permissions.
Once devices start publishing Memfault heartbeats and core dumps, they appear in your Memfault dashboard.