Using the Amazon Chime SDK for 3rd party devices
The Amazon Chime SDK is a set of real-time communications components that developers can use to quickly add audio, video, and screen sharing capabilities to their own applications. Developers can use the same communication infrastructure and services that power Amazon Chime, an online meetings service from AWS, to deliver engaging experiences in their applications. For instance, they can add video to a health application so patients can consult remotely with doctors on health issues. They can also add audio to a company website so customers can quickly connect with sales. By using the Amazon Chime SDK, developers can eliminate the cost, complexity, and friction of creating and maintaining their own real-time communication infrastructure and services.
You can get started using the Amazon Chime SDK today with the following simple steps. Afterwards, you have your own in-room setting experiment powered by Amazon Chime.
To use the device demo application, you should have the following prerequisites:
Note: deploying the serverless device demo may incur extra charges in your AWS account.
The device demo showcases a minimal app that can run in various hardware environments. It is composed of two parts:
Controller app – A small application that is responsible for sending actions to the room app. It also listens for data from the room to update its UI.
Room app – The application that handles the business logic. It listens for messages from the controller and runs them. It then sends a response back to the controller to update its state.
Building and deploying demo app
- Download a copy of SDK with a demo to your local development environment by running
git clone https://github.com/aws-samples/amazon-chime-sdk-js-device-demo.gitin your terminal
- Install dependencies by running
- Build device demo by running
npm run build
- Start a client by running
npm run start:client
- Open new terminal within device directory and run API server
npm run start:backend
Now you can navigate to https://localhost:3000/ (room app) application that handles the business logic. It listens for messages from the https://localhost:3000/controller (controller app) and runs them. It may then send a response back to the Controller to update its state.
Deploying the serverless device demo
You can deploy the demo as self-contained serverless application.
Run deployment script
- Open terminal and navigate to
- Run the following command:
node ./deploy.js -r us-east-1 -b <my-bucket> -s <my-stack-name>. Replace
<my-bucket>with your desired Amazon Simple Storage Service (Amazon S3) bucket name and
<my-stack-name>with your desired name for stack setup.
The script creates an Amazon S3 bucket and AWS CloudFormation stack with AWS Lambda and API Gateway resources required to run the demo. After the script finishes, it outputs an URL. The URL can be opened in browser to access room app. In a separate tab or window, open the controller app by appending
/controller path to the provided URL from the output.
Running application on Raspberry Pi
The Raspberry Pi 4 brings even more potency to the ultra-versatile tiny desktop computer. It’s the perfect candidate for our demo of a self-built conference device. The latest Raspberry Pi model has support for dual monitors, which we use in our demo to display meeting on one screen and a touchscreen monitor on the second. This will be used as the meeting controller.
If needed, checkout out the get started guide to set up your Raspberry Pi
- On the first (larger) screen, we open the provided url from the deployed script.
- On the second screen, as showed in our demo, we use a 7″ touch monitor as the controller device. Use the same url as before but with appended
/controllerat the end to let device know to load controller application.
Now you are set!
Description of key components
The concept is fairly similar to the Amazon Chime SDK serverless demo app . The main difference is the UI for our conference room application has no clickable elements. You control the app with a separate application that we refer to as the controller application. The controller application in this example is just a simple UI that provides a set of features. These include join and end meeting, toggle mute of the microphone and camera as well toggling content sharing view. The room application is used to view meeting-related content like attendees video and screen share content. It seamlessly works with the controller application for an in-room meeting experience.
In order to fully avoid incurring future charges, please delete all resources created by the AWS CloudFormation stack once you are done trying out the demo.
Next steps and resources
To learn more about how to build using the Amazon Chime SDK, here are few more resources you can use.
- Watch the Amazon Chime SDK online tech talk video
- Amazon Chime SDK how to build walkthrough video
- Building a virtual classroom application using Amazon Chime SDK
- Visit the Amazon Chime SDK GitHub repository
- Read the Amazon Chime SDK documentation
The Amazon Chime SDK is a set of real-time communications components that developers can use to quickly add audio calling, video calling, and screen sharing capabilities to their own device applications, whether it’s homemade in-room Raspberry Pi or dedicated 3rd party in-room conferencing device. Developers can leverage the same communication infrastructure and services that power Amazon Chime, an online meetings service from AWS, to deliver engaging experiences in their in-room conferencing applications.