micropython_compare_local_remote
Compare a local file with a file on a MicroPython device using SHA-256 hashes to verify they match.
Instructions
ローカルファイルとデバイス上のファイルが一致するか確認する。
Args: local_path: ホスト側ファイルパス。ワークスペース内のみ指定可能 remote_path: デバイス側ファイルパス timeout: コード送信から Raw REPL 復帰完了までの全体タイムアウト秒数
Returns: ok: 比較処理に成功したら True local_path: 比較したローカルパス remote_path: 比較したデバイス側パス local_sha256: ローカルファイルの sha256 remote_sha256: デバイス側ファイルの sha256 same: 両者が一致したら True error: エラー時のメッセージ
Notes: 比較は sha256 ハッシュで行う。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| timeout | No | ||
| local_path | Yes | ||
| remote_path | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| same | Yes | ||
| error | Yes | ||
| local_path | Yes | ||
| remote_path | Yes | ||
| local_sha256 | Yes | ||
| remote_sha256 | Yes |