<?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[How to use both 2 I2C interface on StickC-Plus2?]]></title><description><![CDATA[<h3>Env PlatformIO</h3>
<p dir="auto">platformio.ini:</p>
<pre><code>...
platform = espressif32
board = m5stick-c
framework = arduino
...
lib_deps =
	Wire
	m5stack/M5Unified
	m5stack/M5Unit-DDS
</code></pre>
<h3>Question:</h3>
<p dir="auto">I connect 2 modules to StickC-Plus2, one on 'grove' port, the other on 'Ext.8-pin'. Is it correct to connect this way( or to say, is it possible to communicate with 2 modules through I2C separately through GPIO25-GPIO26 and GPIO32-GPIO33)? If this is correct, then how should I write the code?</p>
<p dir="auto">Currently in my code, I defined the second 'TwoWire' object and initialized a module with it, but communication failed, while default 'TwoWire(0)' works well.</p>
<pre><code>TwoWire I2C_DDS = TwoWire(1);

...
	I2C_DDS.begin(DDS_SDA, DDS_SCL);
	dds.begin(&amp;I2C_DDS);
...
</code></pre>
]]></description><link>https://community.m5stack.com/topic/7061/how-to-use-both-2-i2c-interface-on-stickc-plus2</link><generator>RSS for Node</generator><lastBuildDate>Tue, 28 Apr 2026 22:33:29 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/7061.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 07 Dec 2024 17:40:08 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to use both 2 I2C interface on StickC-Plus2? on Mon, 09 Dec 2024 02:39:34 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/%E4%BF%BA%E3%81%8C%E3%82%AC%E3%83%B3%E3%83%80%E3%83%A0%E3%81%A0" aria-label="Profile: 俺がガンダムだ">@<bdi>俺がガンダムだ</bdi></a><br />
Look at the definition of TwoWire, number should be fixed</p>
]]></description><link>https://community.m5stack.com/post/27387</link><guid isPermaLink="true">https://community.m5stack.com/post/27387</guid><dc:creator><![CDATA[kuriko]]></dc:creator><pubDate>Mon, 09 Dec 2024 02:39:34 GMT</pubDate></item></channel></rss>