Clone this repository with the --recursive
option.
$ git clone --recursive https://github.com/meganetaaan/stack-chan.git
$ cd stack-chan/firmware
$ npm i
On the host PC, install ModdableSDK and Install ESP-IDF on the host PC. There are three ways to do this
Stack-Chan has npm scripting of the setup procedure.
Run the following command in the stack-chan/firmware
directory.
$ npm run setup
$ npm run setup -- --device=esp32
The script internally uses xs-dev
to automate the setup of ModdableSDK and ESP-IDF.
This repository provides a Dockerfile build environment. You can build, write and debug firmware inside a Docker container.
Note: This has been tested and confirmed to work on Linux (Ubuntu 20.04). It is not recommended for use on Windows (WSL) or MacOS, as there have been reported issues with connecting to devices from the container side.
Run the following command in the stack-chan/firmware
directory.
$ ./docker/build-container.sh
$ ./docker/launch-container.sh
# Run inside container
$ npm install
This project includes DevContainer preference for VSCode. You can open the project in a container with the following commands
>Remote-Containers: Reopen in Container
Follow the instructions on the official website (English) to install ModdableSDK and ESP-IDF. If you cannot setup CLI or Docker properly, please do this.
You can test the environment with the npm run doctor
command.
If the installation was successful, the version of Moddable SDK will be displayed as follows, and esp32 will be displayed in Supported target devices.
$ npm run doctor
> stack-chan@0.2.1 doctor
> xs-dev doctor
xs-dev environment info:
CLI Version 0.20.0
OS Linux
Arch x64
NodeJS Version v16.14.2 (/usr/local/bin/node)
Python Version 3.8.10 (/home/sskw/.espressif/python_env/idf4.4_py3.8_env/bin/python)
Moddable SDK Version 3.6.0 (/home/sskw/.local/share/moddable)
Supported target devices lin, esp32
ESP32 IDF Directory /home/sskw/.local/share/esp32/esp-idf
If this is related to an error when using the CLI, please create an issue at "https://github.com/hipsterbrown/xs-dev/issues/new" with the above info.