0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

スタックチャンが最新ソースで動かない?Moddableへのパッチで解決した話

Posted at

はじめに

前回は、スタックチャンを Windows10 + WSL で書き込む内容(雑ですが)を紹介しました。

その際、スタックチャンの書き込みはできたもののうまく動かない事象に遭遇していました。
Web Serial API 経由での書き込みでも遭遇していた事象と同じです。(画面が真っ白になる)

今回、X(旧Twitter)で事象についてつぶやいていたところ、@stc1988 さんに偶然みつけてもらい助けてもらってスタックチャンの顔を拝めるところまできました。

その時の対応内容をまとめる(というか手順?)を残したいと思います。

修正内容

そのまんまの修正内容です。import の修正と、 manifest の修正です。一人では到底たどり着けない内容なのでとても感謝しています。

修正の適用

差分を提示いただいたので、適用は簡単です。

$ cd $MODDABLE
$ wget https://gist.githubusercontent.com/stc1988/aecb8e4e0c365ec8f0d99592e44dd5cf/raw/b72575b6f2772288a9526e31c54723d6136
f0861/cores3_touch.diff
--2025-05-13 00:41:15--  https://gist.githubusercontent.com/stc1988/aecb8e4e0c365ec8f0d99592e44dd5cf/raw/b72575b6f2772288a9526e31c54723d6136f0861/cores3_touch.diff
Resolving gist.githubusercontent.com (gist.githubusercontent.com)... 185.199.110.133, 185.199.111.133, 185.199.109.133, ...
Connecting to gist.githubusercontent.com (gist.githubusercontent.com)|185.199.110.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1152 (1.1K) [text/plain]
Saving to: ‘cores3_touch.diff’

cores3_touch.diff                        100%[==================================================================================>]   1.12K  --.-KB/s    in 0.002s

2025-05-13 00:41:15 (464 KB/s) - ‘cores3_touch.diff’ saved [1152/1152]

$ git apply cores3_touch.diff
error: corrupt patch at line 25

おや。。。なにか、25行目が気に入らないようです。
差分は小さいので今回は手動で修正しました。

動作確認

気を取り直して、WSL側からデプロイします。(ビルドまでの流れは前回の記事を参照してください)

npm run deploy --target=esp32/m5stack_cores3

出力結果(一部

Writing at 0x0029bf26... (94 %)
Writing at 0x002a6120... (95 %)
Writing at 0x002acca6... (96 %)
Writing at 0x002b2570... (97 %)
Writing at 0x002b80e7... (98 %)
Writing at 0x002be4f5... (99 %)
Writing at 0x002c3e2d... (100 %)
Wrote 2846864 bytes (1696306 compressed) at 0x00010000 in 24.3 seconds (effective 936.1 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 120...
Writing at 0x00008000... (100 %)
Wrote 3072 bytes (120 compressed) at 0x00008000 in 0.0 seconds (effective 492.8 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting via RTS pin...
Done

書き込みが終わりました。

再起動

数秒待ち・・・とうとう来ました!

GqwhKNZW8AAfZeR.jpeg

まとめ

スタックチャンの画面が真っ白になるのは Moddable SDK に不具合が紛れ込んでいたことが原因だったようです。 @stc1988 さんには助けていただき助かりました。

修正方法は明確なので最終的には修正が取り込まれれば手動による修正は避けられますね。

これで安心してスタックチャンで遊べるようになります。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?