Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ inputs:
runs:
using: composite
steps:
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 16
node-version: 22
- name: Cache node modules
uses: actions/cache@v3
env:
Expand All @@ -27,7 +27,7 @@ runs:
if [ -z "${{ inputs.target-branch }}" ]; then
npm run setup
else
npm run setup -- --target-branch ${{ inputs.target-branch }}
npm run setup -- --branch ${{ inputs.target-branch }}
fi
working-directory: ./firmware
shell: bash
Expand Down
14 changes: 3 additions & 11 deletions firmware/docs/getting-started-wsl2_ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -250,13 +250,9 @@ $ npm install

コマンド`npm run setup`によってスクリプトを実行します。スクリプトによって、自動で`Moddable`のインストールが行われます。

以下に示す1つ目のコマンドの実行直後、`Ubuntu`に設定したパスワードの入力が要求されますので入力してください。
パスワード入力後、一定時間は同様のコマンドを実行してもパスワードは要求されません。
2つ目のコマンドでは、再度パスワードが要求されない内に実行してください。
もし、何らかの理由で1つめのコマンド実行から時間がかかってしまった場合は1つ目のコマンドの実行からやり直してください。
システムパッケージのインストールが必要な場合は、コマンド内で`Ubuntu`に設定したパスワードの入力が要求されます。

```bash
$ sudo echo "Temporary SuperUser Grant"
$ npm run setup
```

Expand All @@ -265,15 +261,11 @@ $ npm run setup
### `M5Stack`向けに`Moddable`をセットアップ

以下のコマンドで`Moddable`の環境を`M5Stack`向けにセットアップします。
`npm run setup -- --device=esp32`はスクリプトを実行し、自動で環境のセットアップを行います
`npm run setup -- --device=esp32`はスクリプトを実行し、ESP-IDF v5.3を選択して自動で環境のセットアップを行います

1つ目のコマンドを実行直後、`Ubuntu`に設定したパスワードの入力が要求されますので入力してください。
パスワード入力後、一定時間は同様のコマンドを実行してもパスワードは要求されません。
2つ目のコマンドでは、このパスワードが要求されない内に実行してください。
もし、何らかの理由で1つめのコマンド実行から時間がかかってしまった場合は1つ目のコマンドの実行からやり直してください。
システムパッケージのインストールが必要な場合は、コマンド内で`Ubuntu`に設定したパスワードの入力が要求されます。

```bash
$ sudo echo "Temporary SuperUser Grant"
$ npm run setup -- --device=esp32
```

Expand Down
18 changes: 6 additions & 12 deletions firmware/docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ Stack-chan can be developed on Windows 11, MacOS, and Linux. For Windows 11, ple
* [cmake](https://cmake.org/)
* [git](https://git-scm.com/)
* [Node.js](https://nodejs.org/en/)
* As for the mod for cherrup_ble_lite, you need to use V18.x.x as it does not support the new Node.js.
* I've confirmed that other mods work with v22.8.x.
* Node.js 20 or later is required. Operation has been confirmed with v22.8.x.
* The cherrup_ble_lite mod requires Node.js 18 because it does not support newer versions. Use a separate Node.js 18 environment when working on that mod.
* The operation has been confirmed with Python 3.12. (Please download and install macOS from https://www.python.org instead of installing it with brew.))
* xcode-select (macOS only)

Expand All @@ -44,33 +44,27 @@ Stack-chan has npm scripted setup instructions.

In the `stack-chan/firmware` directory, run the following command:

Immediately after executing the first command shown below, you will be asked to enter the password set in Ubuntu.
After entering the password, the password will not be requested even if the same command is executed for a certain period of time.

For the second command, run it before you are prompted for a password again. If, for some reason, it takes a long time to execute the first command, please start over from the execution of the first command.
On Linux/Ubuntu, each setup command prompts for your password when administrator privileges are needed to install system packages.

```console
$ sudo echo "emporary SuperUser Grant"
$ npm run setup
$ npm run setup -- --device=esp32
```

For macOS, when installing npm run setup -- --device=esp32, if the version of xcode-select is outdated, it may stop at "Error: Command failed with exit code 1: python3 -m pip install pyserial". In that case, manually remove xcode-select and install xcode-select (xcord-select –install) again.
You can remove xcode-select with "sudo rm -rf /Library/Developer/CommandLineTools".
Internally, [`xs-dev`](https://github.com/HipsterBrown/xs-dev) is used to automate the setup of ModdableSDK and ESP-IDF.
Internally, the repository setup script pins Moddable SDK 4.9.5 and ESP-IDF v5.3, then uses [`xs-dev`](https://github.com/HipsterBrown/xs-dev) to install their tools and dependencies. This prevents newer incompatible ESP-IDF releases from being selected.

The moddable configuration script xs-dev-export.sh is not automatically loaded when starting the terminal.
Add source ~/.local/share/xs-dev-export.sh to ~/.bashrc or ~/.zshrc.

The script internally uses [`xs-dev`](https://github.com/HipsterBrown/xs-dev) to automate the setup of ModdableSDK and ESP-IDF.

## Set up Manual

Follow the instructions on the [official website (English)](https://github.com/Moddable-OpenSource/moddable/blob/public/documentation/Moddable%20SDK%20-%20Getting%20Started.md) to install ModdableSDK and ESP-IDF.
If you cannot setup xs-dev(CLI) properly, please do this.

- **Stack-chan RT version assumes that Moddable SDK 4.9.5 and ESP-IDF 5.3.0 will work.**
- **We have confirmed that intel mac works with Moddable SDK 4.7.0 + ESP-IDF 5.1.0 python 3.9.0. To use it on Intel Macs, you can install it by changing "setup": "xs-dev setup --target-branch 4.9.5" to "setup": "xs-dev setup --target-branch 4.7.0" in firmware/package.json, but it is not supported.**
- **We have confirmed that intel mac works with Moddable SDK 4.7.0 + ESP-IDF 5.1.0 python 3.9.0. To use it on Intel Macs, change `MODDABLE_VERSION` to `4.7.0` and `ESP_IDF_VERSION` to `v5.1` in `firmware/scripts/setup.js`, but this configuration is not supported.**

## Set up PSRAM and Environment Variable

Expand Down Expand Up @@ -105,7 +99,7 @@ stack-chan environment info:
55d005ac9f0764a4ebc561b7d0a2a29a66ee5199
/home/ubuntu/stack-chan
xs-dev environment info:
CLI Version 0.32.3
CLI Version 1.12.1
OS Linux
Arch x64
Shell /bin/bash
Expand Down
15 changes: 6 additions & 9 deletions firmware/docs/getting-started_ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
* [cmake](https://cmake.org/)
* [git](https://git-scm.com/)
* [Node.js](https://nodejs.org/en/)
* cherrup_ble_liteのmodに関しては、新しいNode.jsに対応していないためV18.x.xを使用する必要があります
* その他のmodはv22.8.xで動作することは確認しています
* Node.js 20以降が必要です。v22.8.xでの動作を確認しています
* cherrup_ble_liteのmodは新しいNode.jsに対応していないため、作業時は別途Node.js 18の環境を使用してください
* Python3.12で動作確認ができています。(macOSはbrewでインストールするのではなく[https://www.python.org](https://www.python.org)からダウンロードしインストールしてください。)
* xcode-select(macOSのみ)

Expand All @@ -44,19 +44,16 @@ $ npm install
スタックチャンはセットアップ手順をnpmスクリプト化しています。
`stack-chan/firmware`ディレクトリで次のコマンドを実行します。

以下に示す1つ目のコマンドの実行直後、Ubuntuに設定したパスワードの入力が要求されますので入力してください。 パスワード入力後、一定時間は同様のコマンドを実行してもパスワードは要求されません。

2つ目のコマンドでは、再度パスワードが要求されない内に実行してください。 もし、何らかの理由で1つめのコマンド実行から時間がかかってしまった場合は1つ目のコマンドの実行からやり直してください。
Linux/Ubuntuでは、システムパッケージのインストールが必要な場合に各セットアップコマンド内でパスワードの入力が要求されます。

```console
$ sudo echo "emporary SuperUser Grant"
$ npm run setup
$ npm run setup -- --device=esp32
```

macOSの場合は、npm run setup -- --device=esp32のインストールの時、xcode-selectのバージョンが古いと"Error: Command failed with exit code 1: python3 -m pip install pyserial"で止まることがあります。その場合は、xcode-selectを手動で削除してから再度xcode-select(xcord-select –install)をインストールしてください。
xcode-selectの削除は"sudo rm -rf /Library/Developer/CommandLineTools"でできます。
内部で[`xs-dev`](https://github.com/HipsterBrown/xs-dev)を使ってModdableSDKやESP-IDFのセットアップを自動化しています。
リポジトリ内のセットアップスクリプトでModdable SDK 4.9.5とESP-IDF v5.3を固定した上で、[`xs-dev`](https://github.com/HipsterBrown/xs-dev)を使ってツールと依存パッケージのセットアップを自動化しています。これにより、互換性のない新しいESP-IDFが選択されることを防ぎます。


### 手動でセットアップする
Expand All @@ -65,7 +62,7 @@ xcode-selectの削除は"sudo rm -rf /Library/Developer/CommandLineTools"でで
xs-dev(CLI)でうまくセットアップできない場合はこちらを行ってください。

- **スタックチャン アールティver.では、Moddable SDK 4.9.5、ESP-IDF 5.3.0 での動作を想定しています。**
- **intel macはModdable SDK 4.7.0 + ESP-IDF 5.1.0 python3.9.0で動作することは確認しています。intel macで使用するには`firmware/package.json`の`"setup": "xs-dev setup --target-branch 4.9.5"`を`"setup": "xs-dev setup --target-branch 4.7.0"`にすることでインストールできますがサポート対象外になります。**
- **intel macはModdable SDK 4.7.0 + ESP-IDF 5.1.0 python3.9.0で動作することは確認しています。intel macで使用するには`firmware/scripts/setup.js`の`MODDABLE_VERSION`を`4.7.0`、`ESP_IDF_VERSION`を`v5.1`に変更することでインストールできますがサポート対象外になります。**

### PSRAMと環境変数のセットアップ

Expand Down Expand Up @@ -101,7 +98,7 @@ stack-chan environment info:
55d005ac9f0764a4ebc561b7d0a2a29a66ee5199
/home/ubuntu/stack-chan
xs-dev environment info:
CLI Version 0.32.3
CLI Version 1.12.1
OS Linux
Arch x64
Shell /bin/bash
Expand Down
Loading
Loading