<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[拡張モジュールの互換性について教えてください]]></title><description><![CDATA[<p dir="auto">M5Stackの拡張モジュールはGrayでもCoreS3でも共通で利用可能でしょうか？</p>
<p dir="auto">具体的には、最も性能の高そうな「CoreS3」</p>
<p dir="auto"><a href="https://www.switch-science.com/products/8960?_pos=17&amp;_sid=aea411e7e&amp;_ss=r" target="_blank" rel="noopener noreferrer nofollow ugc">https://www.switch-science.com/products/8960?_pos=17&amp;_sid=aea411e7e&amp;_ss=r</a></p>
<p dir="auto">に「PWRCANモジュール」<br />
<a href="https://www.switch-science.com/products/9816?_pos=3&amp;_sid=714545fdc&amp;_ss=r" target="_blank" rel="noopener noreferrer nofollow ugc">https://www.switch-science.com/products/9816?_pos=3&amp;_sid=714545fdc&amp;_ss=r</a></p>
<p dir="auto">および「GNSSモジュール」<br />
<a href="https://www.switch-science.com/products/9276?_pos=24&amp;_sid=aea411e7e&amp;_ss=r" target="_blank" rel="noopener noreferrer nofollow ugc">https://www.switch-science.com/products/9276?_pos=24&amp;_sid=aea411e7e&amp;_ss=r</a></p>
<p dir="auto">をスタックしてCAN通信や位置・姿勢取得を行いWiFi(UDP通信)でPCと情報の授受をしようと考えております。</p>
<p dir="auto">お手数をおかけいたしますがご教示のほどよろしくお願い申し上げます。</p>
]]></description><link>https://community.m5stack.com/topic/7069/拡張モジュールの互換性について教えてください</link><generator>RSS for Node</generator><lastBuildDate>Sun, 15 Mar 2026 01:42:24 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/7069.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 09 Dec 2024 05:24:28 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Wed, 18 Dec 2024 10:16:24 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/196501">@k0u1_H</a><br />
お役に立てて嬉しいです。</p>
]]></description><link>https://community.m5stack.com/post/27498</link><guid isPermaLink="true">https://community.m5stack.com/post/27498</guid><dc:creator><![CDATA[kuriko]]></dc:creator><pubDate>Wed, 18 Dec 2024 10:16:24 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Sun, 15 Dec 2024 09:41:05 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/168201">@kuriko</a><br />
色々な調べ事やコンパイルのトライ等で詰まってしまい、お返事が大変遅くなり申し訳ございません。</p>
<p dir="auto">調べるほどに1個だけを色々な用途で使っていくことを考慮すると、仰られるように「S3のコアは絶対に選択から外すべき」だという風に思いました。</p>
<p dir="auto">そこで以下のサイトを見て選ぶべきものを考えました。<br />
<a href="https://lang-ship.com/blog/work/m5unified-2-basic-gray-m5go-fire-core2-core2-for-aws/" target="_blank" rel="noopener noreferrer nofollow ugc">https://lang-ship.com/blog/work/m5unified-2-basic-gray-m5go-fire-core2-core2-for-aws/</a></p>
<p dir="auto">Fire v2.7がほぼ最善っぽく思いましたが間違っていないでしょうか。</p>
<h1>CORE2 for AWSという択も悪くない気がしましたが、コンパイル問題に関しては両者同格で、物理ボタンは使い易そうと考えてFireかなと思いました。</h1>
<p dir="auto">この度は、大変勉強させていただきました。<br />
kuriko様、お手数をお掛けいたしました。ありがとうございました！！</p>
]]></description><link>https://community.m5stack.com/post/27473</link><guid isPermaLink="true">https://community.m5stack.com/post/27473</guid><dc:creator><![CDATA[k0u1_H]]></dc:creator><pubDate>Sun, 15 Dec 2024 09:41:05 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Thu, 12 Dec 2024 06:40:43 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/196501">@k0u1_H</a><br />
僕の知る限り、そういった汎用的な方法は存在しないはずです。<br />
M5Stack.hは、M5チームがCore Basicのために作成したヘッダーファイルで、当時はM5UnifiedやM5GFXがなかったため、このヘッダーファイルに基づく多くの例は古い関数が含まれています。そのため、後に廃止されたり名前が変更された関数が多く、新しい開発ボードに移植するのは大変な作業です。<br />
僕が以前に言ったように、比較的古いモジュールやベース（特に大きなM5のロゴが印刷されたもの）を使用する場合は、Core Basicをコントローラーとして使用することをお勧めします。比較的新しいユニットやモジュールを使用する場合は、古いコントローラーと新しいコントローラーの両方から必要に応じて選択できます。</p>
]]></description><link>https://community.m5stack.com/post/27426</link><guid isPermaLink="true">https://community.m5stack.com/post/27426</guid><dc:creator><![CDATA[kuriko]]></dc:creator><pubDate>Thu, 12 Dec 2024 06:40:43 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Thu, 12 Dec 2024 04:34:31 GMT]]></title><description><![CDATA[<p dir="auto">＠kuriko<br />
連投となり恐れ入ります。</p>
<p dir="auto">種々のWeb情報を総合してゆくと、ESP32-S3を搭載するM5Stack CoreS3でESP32搭載のM5StackやM5Stack Core2用に書かれたスケッチ例をそのままではビルドできない様に思いました。</p>
<p dir="auto">#include &lt;M5Stack.h&gt;</p>
<p dir="auto">を</p>
<p dir="auto">#include &lt;M5CoreS3.h&gt;<br />
#include &lt;M5Unified.h&gt;</p>
<p dir="auto">に置き換えることは試みましたが、未定義エラーが増えました。</p>
<p dir="auto">上記だけでは上手くいきませんでしたが、基本的にはこのようにESP32向けのヘッダファイルとESP32-S3向け、または両対応のヘッダファイルと置き換えるのがCoreS3の利用方法なのではないかと思います。</p>
<p dir="auto">このIncludeするヘッダファイルの置き換えで(全てに対応できるとは限らないまでも)、コンパイルエラーを回避する機械的にやればよい定形処理のようなものはございませんでしょうか？</p>
<h1>Coreのアップグレードに係る基本的な部分なので公式情報がありそうな気もしますが…。</h1>
<p dir="auto">現状では一番最初にkuriko様にご助言頂きましたように、「CoreS3を選定するのは拡張モジュールを追加するなどの汎用的利用法を考えれば避けるべき選択」という結論になってしまいますため、ノウハウがあれば伝授頂けましたら大変助かります。</p>
]]></description><link>https://community.m5stack.com/post/27425</link><guid isPermaLink="true">https://community.m5stack.com/post/27425</guid><dc:creator><![CDATA[k0u1_H]]></dc:creator><pubDate>Thu, 12 Dec 2024 04:34:31 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Tue, 10 Dec 2024 10:21:17 GMT]]></title><description><![CDATA[<p dir="auto">同じようなエラーで困っている人への回答を見つけました。</p>
<p dir="auto"><a href="https://github.com/m5stack/M5Stack/issues/317" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/m5stack/M5Stack/issues/317</a></p>
<p dir="auto">あなたのデバイスに間違ったライブラリを使用しているためです。ESP32-S3デバイスはVSPIをサポートしていないため、M5StackライブラリではなくM5CoreS3ライブラリを使用することをお勧めします。</p>
<p dir="auto"><a href="https://www.reddit.com/r/esp32/comments/197zhss/issues_compiling_for_my_m5stack_cores3_vspi_error/" target="_blank" rel="noopener noreferrer nofollow ugc">https://www.reddit.com/r/esp32/comments/197zhss/issues_compiling_for_my_m5stack_cores3_vspi_error/</a></p>
<p dir="auto">M5Stack CoreS3は、HSPIまたはVSPIを持たないESP32-S3を使用します。SPI0 - SPI4を使用する必要があります。どれが使われているのかわからない。たぶんSPI0とSPI1は使用可能です。</p>
<p dir="auto">コンパイル中に流れる文字に"esp32s3"だけでなく"esp32"が散見されることを気にしていました。</p>
<p dir="auto">要するに、esp32のライブラリが使われるとCoreS3はアウト！ということでしょうか。</p>
<h1>GPIOのアサインを書き換えるような裏技があるようにも思えますが。</h1>
]]></description><link>https://community.m5stack.com/post/27414</link><guid isPermaLink="true">https://community.m5stack.com/post/27414</guid><dc:creator><![CDATA[k0u1_H]]></dc:creator><pubDate>Tue, 10 Dec 2024 10:21:17 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Tue, 10 Dec 2024 10:05:16 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/168201">@kuriko</a> said in <a href="/post/27405">拡張モジュールの互換性について教えてください</a>:</p>
<blockquote>
<p dir="auto">プロジェクトを再作成するかソフトウェアを再インストールすることで解決する可能性</p>
</blockquote>
<p dir="auto">実際にコンパイルまで試してくださるだなんて、誠にかたじけなく存じます。<br />
「プロジェクトを再作成」はどういう意味か分からなかったのですが、<br />
「ソフトウェアを再インストール」については、ご助言に従って、1.8.15のIDEを2.3.4に入れ替えてみました。<br />
ごく一部のコンパイルエラーが消えた気がしましたが、CANもISO485もコンパイル成功しないため、ライブラリも「ソフトウェアを再インストール」の一つなのかもしれないと思い、100近くはあったであろうlibrariesフォルダ内の全てのライブラリを削除してIDEから入れ直しました。</p>
<pre><code>※ 1.8.15では依存関係のライブラリの量が多すぎると、ボタンが画面の中に表示されませんでしたが、
　 2.3.4ではスクロールバー付きでボタンが見えるようになりました。
　 もしかすると依存ライブラリの一部が入っていなかった可能性があります。
</code></pre>
<p dir="auto">全て入れ替えましたが、下記についてはやはりVSPIがダメで、残念ながらM5CoreS3を選択するとコンパイルエラーでした。</p>
<pre><code>M5Stack/Unit/CAN
M5Stack/Unit/ISO485

c:\Users\HE42137\Documents\Arduino\libraries\M5Stack\src/utility/In_eSPI.h:633:20: error: 'VSPI' was not declared in this scope
	 uint8_t port = VSPI;
                    ^~~~
</code></pre>
<p dir="auto">ですが、M5CoreまたはM5Core2をボード選択した場合にはコンパイル成功しますので、M5CoreS3を選んだ場合特有のエラーに見えました。</p>
<p dir="auto">In_eSPI.hの633行目を確認してみると、「ESP32がdefineされていてUSE_HSPI_PORTは未定義」という条件でportに代入しようとするVSPIが未定義で起こるエラーに見えました。</p>
<pre><code>#if defined(ESP32)
#if defined(USE_HSPI_PORT)
    uint8_t port = HSPI;
#else
    uint8_t port = VSPI;
#endif
#endif
</code></pre>
<p dir="auto">このファイルの上の方にも以下のような記述がありますが、そもそもlibrariesフォルダの下にsocフォルダも無ければspi_reg.hもありません。</p>
<pre><code>#include &lt;SPI.h&gt;

#ifdef ESP32
#include "soc/spi_reg.h"
#ifdef USE_HSPI_PORT
#define SPI_PORT HSPI
#else
#define SPI_PORT VSPI
#endif
#endif
</code></pre>
<p dir="auto">librariesフォルダ配下の子ディレクトリまで含めて VSPI をグローバル検索すると、定義しているファイルは無いものの、以下が引っ掛かりました。</p>
<pre><code>M5GFX\src\lgfx\v1\platforms\esp32\Bus_SPI.cpp(95):     auto spi_port = (uint32_t)(cfg.spi_host) + 1;  // FSPI=1  HSPI=2  VSPI=3;
</code></pre>
<p dir="auto">上記コメントから、"VSPI"というのを使っている場所を"3"に置き換えれば想定されたビルドにはなるのかなとは思いました。</p>
<p dir="auto">※ M5CoreやM5Core2を選択した場合には、ここで引っ掛からないのが謎ではあるのですが…。</p>
<p dir="auto">ただ、そのような場当たり的な対応をしても意味がなく、"soc/spi_reg.h" を読み込めるように何かのファイルを用意するべきなのかと思います。</p>
<p dir="auto">"spi_reg.h"をどうすれば入手できるかと思いgoogle検索すると下記がhitしました。</p>
<pre><code>https://git.liberatedsystems.co.uk/jacob.eva/arduino-esp32/src/commit/1b2f34b0d6a668ba0e5c353f6c83dcab500c5028
</code></pre>
<p dir="auto">zipのダウンロードもできず、「git clone <a href="https://git.liberatedsystems.co.uk/jacob.eva/arduino-esp32.git%E3%80%8D%E3%82%82%E3%81%A7%E3%81%8D%E3%81%BE%E3%81%9B%E3%82%93%E3%81%A7%E3%81%97%E3%81%9F%E3%80%82" target="_blank" rel="noopener noreferrer nofollow ugc">https://git.liberatedsystems.co.uk/jacob.eva/arduino-esp32.git」もできませんでした。</a></p>
<p dir="auto">同じ検索の中にあった下記を参考に</p>
<pre><code>https://interface.cqpub.co.jp/esp32-arduino-ide-2/
</code></pre>
<p dir="auto">IDEの環境設定「追加のボードマネージャのURL」に下記URLを追加</p>
<pre><code>https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
</code></pre>
<p dir="auto">→ ボードマネージャで「esp32」を検索してインストールしました。</p>
<p dir="auto">もう一度下記を確認すると、ESP32-S2および/またはESP32-C3をボードマネージャにインストールするために、</p>
<pre><code>https://git.liberatedsystems.co.uk/jacob.eva/arduino-esp32
</code></pre>
<p dir="auto">上記と同様に下記を「追加のボードマネージャのURL」に記載することが書かれていました。</p>
<pre><code>https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_dev_index.json
</code></pre>
<p dir="auto">これを終えると、既にインストールしたばかりの「esp32」でしたがボードマネージャ上でUPDATE可能になっていたのでアップデートしました。</p>
<p dir="auto">ここまではやってみましたが、spi_reg.hがlibrariesフォルダに入ることもなく、コンパイル結果はエラーのまま変わらずでした。</p>
<p dir="auto">無意味なことをやった報告しかできずお恥ずかしい限りです。</p>
]]></description><link>https://community.m5stack.com/post/27413</link><guid isPermaLink="true">https://community.m5stack.com/post/27413</guid><dc:creator><![CDATA[k0u1_H]]></dc:creator><pubDate>Tue, 10 Dec 2024 10:05:16 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Tue, 10 Dec 2024 01:38:52 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/196501">@k0u1_H</a><br />
コンパイルの失敗はターゲットボードとは関係ないと思います。先ほど挙げた最初の 2 つの例を試してみましたが、私のコンピュータではエラーなく正常にコンパイルされました。VSPIとSD.hはArduino IDE自体のバグだと思いますが、プロジェクトを再作成するかソフトウェアを再インストールすることで解決する可能性があります。<br />
自分の環境:<br />
2021 MacBook Pro (M1 Pro)<br />
macOS Sequoia 15.1<br />
Arduino IDE 2.3.4</p>
]]></description><link>https://community.m5stack.com/post/27405</link><guid isPermaLink="true">https://community.m5stack.com/post/27405</guid><dc:creator><![CDATA[kuriko]]></dc:creator><pubDate>Tue, 10 Dec 2024 01:38:52 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Mon, 09 Dec 2024 10:35:23 GMT]]></title><description><![CDATA[<p dir="auto">＠kuriko<br />
ご教示有難うございます！</p>
<p dir="auto">以下のような「PWRCANモジュール」でライブラリの「スケッチ例」をコンパイルするとエラーになってしまうのも、ボードの古さによるところでしょうか。<br />
1. PwrCAN Module 13.2 CAN Transceiver TEST<br />
<a href="https://github.com/m5stack/M5Stack/tree/master/examples/Unit/CAN" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/m5stack/M5Stack/tree/master/examples/Unit/CAN</a><br />
2. PwrCAN Module 13.2 485 Communication Example<br />
<a href="https://github.com/m5stack/M5Stack/tree/master/examples/Unit/ISO485" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/m5stack/M5Stack/tree/master/examples/Unit/ISO485</a><br />
3. PwrCAN Module 13.2 Control Xiaomi Motor Example<br />
<a href="https://github.com/project-sternbergia/cybergear_m5" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/project-sternbergia/cybergear_m5</a></p>
<hr />
<p dir="auto">Arduino：1.8.15 (Windows 10), ボード："M5CoreS3, Disabled, QSPI PSRAM, QIO 80MHz, 16MB (128Mb),<br />
Core 1, Core 1, Hardware CDC and JTAG, Enabled, Disabled, Disabled, UART0 / Hardware CDC,<br />
16M Flash (3MB APP/9.9MB FATFS), 240MHz (WiFi), 921600, None, Disabled"<br />
：<br />
In file included from C:\Users\HE42137\Documents\Arduino\libraries\M5Stack\src/M5Display.h:8,<br />
from C:\Users\HE42137\Documents\Arduino\libraries\M5Stack\src/M5Stack.h:106,<br />
from C:\Users\HE42137\Documents\Arduino\libraries\M5Stack\examples\Unit\ISO485\ISO485.ino:16:<br />
C:\Users\HE42137\Documents\Arduino\libraries\M5Stack\src/utility/In_eSPI.h:633:20: error: 'VSPI' was not declared in this scope<br />
uint8_t port = VSPI;<br />
^~~~<br />
C:\Users\HE42137\Documents\Arduino\libraries\M5Stack\src/utility/In_eSPI.h:633:20: note: suggested alternative: 'SPI'<br />
uint8_t port = VSPI;<br />
^~~~<br />
SPI<br />
「SD.h」に対して複数のライブラリが見つかりました<br />
使用済：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\SD<br />
未使用：C:\Program Files (x86)\Arduino\libraries\SD<br />
「WiFiClient.h」に対して複数のライブラリが見つかりました<br />
使用済：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\WiFi<br />
未使用：C:\Program Files (x86)\Arduino\libraries\WiFi<br />
次のフォルダのライブラリM5Stackバージョン0.4.6を使用中：C:\Users\HE42137\Documents\Arduino\libraries\M5Stack<br />
次のフォルダのライブラリSPIバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\SPI<br />
次のフォルダのライブラリWireバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\Wire<br />
次のフォルダのライブラリFSバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\FS<br />
次のフォルダのライブラリSPIFFSバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\SPIFFS<br />
次のフォルダのライブラリSDバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\SD<br />
次のフォルダのライブラリHTTPClientバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\HTTPClient<br />
次のフォルダのライブラリWiFiバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\WiFi<br />
次のフォルダのライブラリWiFiClientSecureバージョン2.0.0を使用中：C:\Users\HE42137\AppData\Local\Arduino15\packages\m5stack\hardware\esp32\2.1.2\libraries\WiFiClientSecure</p>
<h2>exit status 1<br />
ボードM5CoreS3に対するコンパイル時にエラーが発生しました。</h2>
<p dir="auto">スケッチ例を弄ればコンパイルできるのでしょうね。<br />
下記にCoreS3のGPIOの設定まで書かれているので。<br />
<a href="https://docs.m5stack.com/en/module/Module13.2-PwrCAN" target="_blank" rel="noopener noreferrer nofollow ugc">https://docs.m5stack.com/en/module/Module13.2-PwrCAN</a></p>
<p dir="auto">少しでも処理の高速なものを使いたいですが、困りました。</p>
]]></description><link>https://community.m5stack.com/post/27400</link><guid isPermaLink="true">https://community.m5stack.com/post/27400</guid><dc:creator><![CDATA[k0u1_H]]></dc:creator><pubDate>Mon, 09 Dec 2024 10:35:23 GMT</pubDate></item><item><title><![CDATA[Reply to 拡張モジュールの互換性について教えてください on Mon, 09 Dec 2024 08:41:11 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://community.m5stack.com/uid/196501">@k0u1_H</a><br />
はい、ほとんどは互換性があります。最悪の場合は、一部のモジュールについては、CoreS3 上に対応するライブラリがない可能性があります。<br />
したがって、以前にリリースされた一部のモジュール (2020 年以前) については、Core Basic、Fire、Gray などの古い Core を使用することを個人的にお勧めします。</p>
]]></description><link>https://community.m5stack.com/post/27397</link><guid isPermaLink="true">https://community.m5stack.com/post/27397</guid><dc:creator><![CDATA[kuriko]]></dc:creator><pubDate>Mon, 09 Dec 2024 08:41:11 GMT</pubDate></item></channel></rss>