MacOS 10.14+ Setup Instructions

This lesson shows you how to set up your macOS computer (host machine) to be able to download the code from the GitHub repository, view and edit the code, compile it to be usable by the hardware, and upload it to the hardware’s flash memory. These installation steps are sufficient for the Getting Started tutorial, which uses Espressif’s AWS account and services for the ESP RainMaker platform.

Silicon Labs USB to UART bridge setup

The Core2 for AWS communicates with the host machine through a Silicon Labs CP210x USB to UART bridge. The on-board CP2104 is an USB-to-UART bridge that facilitates host communication with the ESP32-D0WD microcontroller. The microcontroller communicates bi-directionally over UART 0, which the CP210x translates through a virtual communications port on the host machine it establishes over USB-C. To be able to mount the virtual serial port and communicate across it, you must download and install the corresponding driver.

  1. Ensure the device is not connected to host machine.
  2. Download the macOS Silicon Labs CP210x driver here .
  3. Extract the contents of the download, mount the SiLabsUSBDriverDisk.dmg disk image.
  4. Run the Install C210x VCP Driver installer.
    • On macOS 10.13 and later, the installation of the SiLabs system extension may be blocked. To unblock, open your Mac’s System Preferences Security & Privacy pane, unlock changes by clicking the , allow the developer, and then relock by clicking the . For more information, see Apple Technical Note TN2459 .
  5. Restart your host machine now to ensure the driver is applied.

Visual Studio Code installation

Visual Studio Code (VS Code) is an open source integrated development environment (IDE) which allows you to view, edit, and manage code and more. Download the latest Visual Studio Code for your operating system. To troubleshoot issues with Visual Studio Code installation or usage, please refer to their documentation .

The application sits within your Downloads folder. We recommend that you optionally move it to your user’s Application folder to make it more easily accessible in the future.

Installing PlatformIO

PlatformIO (PIO) provides a professional embedded development platform which simplifies embedded software development. The Visual Studio Code extension provides the functionality of the Platform IO command line interface (CLI) in a graphical interface. You can download the extension and read more about PlatformIO here .

You must restart VS Code after PlatformIO extension installation finishes.

Cloning the code repository

All of the projects and files exist in a GitHub repository , where you can also view the revision history of each file in the repository (repo). To clone the code you’ll need for the tutorials, you’ll be using the PIO interface:

  1. Click the PlatformIO logo on the VS Code activity bar (left most menu).
  2. From PlatformIO’s Quick Access menu, under Miscellaneous, select Clone Git Project.
  3. Paste into the text field and then select the location you want to save the project in.

    PlatformIO Clone Git Project

Downloading and installing the phone apps

The ESP RainMaker Phone Apps are available for iOS and Android phones to provide Wi-Fi network configuration, user-creation, user-device association and device control. The apps can be found here:

If you do not posess a compatible Android or iOS device, you can use the RainMaker CLI and substitute the provided instructions.

Identifying the device communication port

If you haven’t already, it’s time to unbox the Core2 for AWS and connect it to your host computer’s USB 2.0 port using the supplied USB-A to USB-C cable that facilitates communication between them. Additionally, included in the package is a hex key that you can use to install additional modules (sold separately). The device should automatically turn on once you plug it in, but if it doesn’t, press the power button.

How to turn M5Stack Core2 for AWS on or off

With the device ready and the software for this tutorial installed, let’s identify the port your device is virtually mounted to so that you can perform read & write operations to that specific port.

  1. From PlatformIO’s Quick Access menu, under PIO Home, select Devices.
  2. Click the icon next to the port with the description “CP2104 USB to UART Bridge Controller” (usually /dev/cu.SLAB_USBtoUART) to copy the device port.
If your Core2 for AWS does not show up in the list of devices, check that it’s powered on and you are using the supplied USB-A to USB-C cable. Some USB-C hubs have compatibility issues with establishing a serial port.


With everything set up and your host machine ready and able to communicate with the Core2 for AWS, let’s continue to the next chapter — Running the ESP RainMaker Agent .

Questions? Please use M5Stack Forum

AWS IoT Kit now features direct access to M5Stack Forum , which is a community-driven, questions-and-answers service. Search re:Post using the Core2 for AWS tag to see if your question has been asked and answered. If not, ask a new question using the Core2 for AWS tag.