The Cirrent Agent (CA) is an embedded code library that manages the Wi-Fi connection process. The CA provides all of the functionality required for a product to connect to a ZipKey or a private Wi-Fi network. The library includes the following functions and capabilities:
ZipKey: The CA takes care of connecting to a ZipKey router's public Wi-Fi network.
Private Wi-Fi Network: The CA can connect to a private Wi-Fi network, using credentials retrieved from the Cirrent service, or entered via a local onboarding process, such as SoftAP, or provided through a programmatic interface from the Device Application.
Network Prioritization: The CA automatically prioritizes networks based on capabilities, performance levels, and reliability. Private Wi-Fi networks are prioritized over ZipKey networks to allow local discovery, direct connections, and full-bandwidth network access. Once the CA has been configured with private Wi-Fi credentials, it will no longer connect to a ZipKey hotspot unless the private network becomes unreachable (e.g. if the private network credentials were changed).
Cirrent Cloud integration: The CA automatically sends updates to the Cirrent Cloud when the connection status changes.
Configuration updates: The CA regularly updates its configuration from the Cirrent Cloud so that devices can take advantage of the expanding list of ZipKey hotspot providers.
Secure SoftAP: If the CA is not in range of a ZipKey-enabled router, the CA can be configured to bring up a SoftAP network, enabling the App to configure the private Wi-Fi credentials directly onto the device, via SoftAP.
- Secure BLE: If the CA is not in range of a ZipKey-enabled router, the CA can be configured to bring up a BLE network, enabling the App to configure the private Wi-Fi credentials directly onto the device, via BLE.
ZipKey AP: When the device is on a private network, the CA can be configured to bring up a ZipKey hotspot that can be used by other nearby devices for on boarding purposes.
When the ZipKey-enabled device is first powered up, the CA scans for nearby Wi-FI networks. If it sees a ZipKey network, it will automatically associate to that network, and upload its status to the Cirrent cloud. It will then make calls to the Cirrent cloud, looking for any actions that it should perform. The actions that the CA can perform include:
- Join private network. In this case the action contains the network credentials for the private network. The CA will send a status to the cloud saying that it is JOINING the private network. Then it will disconnect from the ZipKey network, associate to the private network, and if successful, send a status update to the cloud saying it has JOINED the private network. If it fails, it will rejoin the ZipKey network, and send a status to the cloud saying it has FAILED to join the private network, and has JOINED the ZipKey network.
- Delete private network. In this case, the CA will delete the referenced private network from its configuration, and if it is currently on that network, it will disconnect from it.
- Start WPS. The CA will initiate the WPS (Wi-Fi Protected Setup) to join the private network.
- Identify action. The CA will call product-specific code to have the product perform an identifying action (e.g. flash a light, make a sound) so that the user knows that right product is being onboarded.
- Product action. The CA will call product-specific code to have the product perform a product-specific action.
- Reset. Set the device back into its factory reset state, by deleting any private network and deleting the log files.