<?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[Connecting relay to Core2]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">I have an issue connecting relay to my Core2.</p>
<p dir="auto">Here is my schematic:</p>
<p dir="auto"><img src="/assets/uploads/files/1633079304054-capture-d-%C3%A9cran_2021-10-01_11-08-03.png" alt="0_1633079302949_Capture d’écran_2021-10-01_11-08-03.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">Nothing happen when changing PIN21 state...</p>
<p dir="auto">Is G21 the good PIN to use?</p>
<p dir="auto">I tried G15 and G12 too, without succes using this command:</p>
<p dir="auto">pinMode(12, OUTPUT);<br />
digitalWrite(12, HIGH);</p>
<p dir="auto">What am I doing wrong?<br />
Which pins are available for my need, and what are the numbers to use in digitalWrite?</p>
<p dir="auto">Thanks for your help</p>
]]></description><link>https://community.m5stack.com/topic/3608/connecting-relay-to-core2</link><generator>RSS for Node</generator><lastBuildDate>Thu, 30 Apr 2026 11:55:17 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/3608.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 01 Oct 2021 09:12:54 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Connecting relay to Core2 on Sat, 02 Oct 2021 06:47:01 GMT]]></title><description><![CDATA[<p dir="auto">Hello <a class="plugin-mentions-user plugin-mentions-a" href="/user/leo05" aria-label="Profile: Leo05">@<bdi>Leo05</bdi></a></p>
<p dir="auto">hmm, not sure why GPIO27 didn't work - it's marked as GPIO on the M5 Bus - should be free to use. I assume you've set it to output first?</p>
<p dir="auto">If you're not stacking a module which requires a serial connection GPIO13 and GPIO14 should be usable too.</p>
<p dir="auto">If you are not using I2C on the Groove port then GPIO32 and GPIO33 should be free too.</p>
<p dir="auto">Also GPIO35 and GPIO36 are free, afaik, but those two can only be inputs.</p>
<p dir="auto">Thanks<br />
Felix</p>
]]></description><link>https://community.m5stack.com/post/15033</link><guid isPermaLink="true">https://community.m5stack.com/post/15033</guid><dc:creator><![CDATA[felmue]]></dc:creator><pubDate>Sat, 02 Oct 2021 06:47:01 GMT</pubDate></item><item><title><![CDATA[Reply to Connecting relay to Core2 on Fri, 01 Oct 2021 10:20:58 GMT]]></title><description><![CDATA[<p dir="auto">Thank you very mcuh for the fast answer Felix!</p>
<p dir="auto">You are right,  got one relay working with GIPO19 and digitalWrite(19, HIGH)</p>
<p dir="auto">But no succes with GPIO27, voltage does not change to 3.3V with digitalWrite(27, HIGH)... strange</p>
<p dir="auto">There is only 2 free GPIO to use? because I have 2 relays to connect but also one line with DS18B20 sensors and another with a water flowmeter.</p>
]]></description><link>https://community.m5stack.com/post/15021</link><guid isPermaLink="true">https://community.m5stack.com/post/15021</guid><dc:creator><![CDATA[Leo05]]></dc:creator><pubDate>Fri, 01 Oct 2021 10:20:58 GMT</pubDate></item><item><title><![CDATA[Reply to Connecting relay to Core2 on Fri, 01 Oct 2021 10:03:47 GMT]]></title><description><![CDATA[<p dir="auto">Hello <a class="plugin-mentions-user plugin-mentions-a" href="/user/leo05" aria-label="Profile: Leo05">@<bdi>Leo05</bdi></a></p>
<p dir="auto">all three GPIOs you've tried are no good as they are already used internally.<br />
GPIO12: BCLK (speaker)<br />
GPIO15: D/C (LCD)<br />
GPIO21: SDA (I2C)</p>
<p dir="auto">Check out the <a href="https://m5stack.oss-cn-shenzhen.aliyuncs.com/resource/docs/schematic/Core/CORE2_V1.0_SCH.pdf" target="_blank" rel="noopener noreferrer nofollow ugc">schematics</a>.</p>
<p dir="auto">I'd try GPIO19 or GPIO27.</p>
<p dir="auto">This <a href="https://www.gwendesign.ch/kb/m5stack/m5core2/#m5core2-bus-and-gpios-compared-to-m5stack" target="_blank" rel="noopener noreferrer nofollow ugc">overview</a> I've put together a while ago might be helpful too.</p>
<p dir="auto">Thanks<br />
Felix</p>
]]></description><link>https://community.m5stack.com/post/15020</link><guid isPermaLink="true">https://community.m5stack.com/post/15020</guid><dc:creator><![CDATA[felmue]]></dc:creator><pubDate>Fri, 01 Oct 2021 10:03:47 GMT</pubDate></item></channel></rss>