Provision ACK Modules for Production


Before you mount an Alexa Connect Kit (ACK)-based module to the printed circuit board, you program the ACK module. Programming steps include provisioning credentials onto the module, securing the module through module locking, and generating the required barcodes for device identification and Frustration-Free Setup (FFS).

Prerequisites

Before you provision the modules, set up your client and server machines. For more details, see Set Up Client - Server Machines for Production.

Steps to provision and lock modules

Complete the following steps to provision, lock, and generate barcodes during module production.

  1. Provision test modules.
  2. Provision production modules.
  3. Lock the module.
  4. Generate barcodes.

Step 1: Provision test modules

You can test provisioning on test modules to learn the time it takes to provision and how to generate control logs without locking the modules.

To provision the device on a client machine

  1. Connect your client machine to the module by using PuTTY.

  2. Create an environment variable called ACKSDKTOOLS_TEST_MODE with a value of 1.
  3. To apply the new variable, restart your machine.
  4. In a PuTTY terminal window on the client machine, enter the following command.
    • Set <port> to the serial port, such as COM9 on Windows.

Copied to clipboard.

provision -p /dev/<module_port> -x <path/to/ProvisioningInfo_<device_type>.conf> -g <DSN prefix> -s <server-ip-address/hostname> -sp 5000 -cd <path/to/CertificationDeclaration> --ca <certificate used by server> --token <path to token file> -l DEBUG --test
  1. If provisioning succeeds, the command displays the following response on the terminal.
    Logging into provision.log with logging level DEBUG
    Writing certificate to the module
    Provisioning successful!
    
  2. If provisioning fails, review the client and server logs to determine the error. You see the log filenames in the command response.

Step 2: Provision production modules

Provisioning a module for manufacturing generates a device serial number (DSN), gets a signed certificate from the server, and writes both to the module. On success, provisioning generates Matter audit logs.

To provision the device on a client machine

  1. Connect your client machine to the module by using PuTTY.

  2. In a Windows terminal window on the client machine, enter the following command.

    • Set <port> to the serial port, such as COM9 on Windows.

Copied to clipboard.

provision -p /dev/<module_port> -x <path/to/ProvisioningInfo_<device_type>.conf> -g <DSN prefix> -s <server-ip-address/hostname> -sp 5000 -cd <path/to/CertificationDeclaration> --ca <certificate used by server> --token <path to token file> -l DEBUG
  1. If provisioning succeeds, the command displays the following response on the terminal.
    Logging into provision.log with logging level DEBUG
    Writing certificate to the module
    Provisioning successful!
    
  2. If provisioning fails, review the client and server logs to determine the error. You see the log filenames in the command response.
  3. On success, the command generates an audit log file in the audit_logs_upload folder under the data folder on the server. Keep this file to upload to Amazon in a later step.

Step 3: Lock the module

In this step, you lock the module to prevent any unauthorized modifications or tampering.

To lock the module, in a Windows terminal window on the client machine, enter the following command at the command prompt. Make sure that you connect your client machine to the module.

Copied to clipboard.

modulelock -p /dev/<module_port> -s <server-ip-address/hostname> -sp 5000 --ca <certificate used by server> --token <path to token file>

Step 4: Generate barcodes

After you provision the module, you generate a unique set of barcodes: the FFS barcode and Matter QR code. The FFS barcode on the package identifies a specific device. Amazon scans the FFS package barcode during order fulfillment and pre-registers the device with the Amazon customer account. Pre-registration enables FFS to authenticate device ownership and enable simple setup.

This step generates the following files:

  • DVC_<DSN>.png – The Matter QR code or device barcode. You print or stick this code on the device to allow customers to scan and register the device. The barcode serves as a unique identifier for the device during manufacturing.
  • DVC_<DSN>_qr_code_content.txt – The text content of the QR code.
  • PKG_<DSN>.png – The FFS barcode. You print this barcode on the product package to enable Matter Simple Setup (MSS).
    For more details, see Provisionee Barcode Specification / 1D Barcode requirements.
  • PKG_<DSN>_barcode_content.txt – The text content of the package barcode.

To generate a barcode for a module

  1. Connect your client machine to the module by using PuTTY.

  2. On the client machine, in a Windows terminal window, enter the following command.

Copied to clipboard.

barcode -p /dev/<device_port>
  1. If the command succeeds, the following response displays on the terminal.
    Barcode files successfully created in C:\Users\... directory.
    
  2. Store the QR code and barcode in your database with the device information.

Next steps

During the module programming phase, you upload audit logs and device control logs to Amazon. For more details, see Upload Production Logs.


Was this page helpful?

Last updated: frontmatter-missing