<?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[Tab5: disable speaker when headphones are plugged in]]></title><description><![CDATA[<p dir="auto">Dear all,</p>
<p dir="auto">I noticed that the hardware demo which comes preloaded on the Tab5 doesn't disable the speaker as soon as headphones are plugged in. Sound plays on both, speaker and headphones.</p>
<p dir="auto">However, the pop up telling me that I connected or disconnected headphones works flawlessly, so the headphones are recognized by the software.</p>
<p dir="auto">For my upcoming project I need the speaker to be silent while sound plays on the headphones.<br />
Is there a way do disable the speaker but keep the headphones activated? I couldn't find something in the libraries and examples on GitHub...</p>
<p dir="auto">Thanks and kind regards!</p>
]]></description><link>https://community.m5stack.com/topic/7938/tab5-disable-speaker-when-headphones-are-plugged-in</link><generator>RSS for Node</generator><lastBuildDate>Wed, 29 Apr 2026 09:07:47 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/7938.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 11 Dec 2025 08:39:19 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Tab5: disable speaker when headphones are plugged in on Fri, 12 Dec 2025 09:35:31 GMT]]></title><description><![CDATA[<p dir="auto">Thank you!<br />
I was not precise enough in my earlier post:<br />
I had already found the code to detect the connected headphones, the part that I was missing was how to turn off the speaker as soon as the headphones are detected (and if it was possible to turn it off independently from the speaker).</p>
<p dir="auto">Thanks to your comment and some poking around on GitHub I realized that I overlooked the GPIO extension. There is a SPK_EN pin there (Pin 1 on the first extension) that connects to the onboard amplifier and, according to its datasheet, can be used to turn the amplifier off.</p>
<p dir="auto">Since the headphones are not connected to the amplifier, this should mute the speaker without influencing the headphones - I haven't tried it yet, but that's my guess based on the schematics.</p>
]]></description><link>https://community.m5stack.com/post/30302</link><guid isPermaLink="true">https://community.m5stack.com/post/30302</guid><dc:creator><![CDATA[milaidin]]></dc:creator><pubDate>Fri, 12 Dec 2025 09:35:31 GMT</pubDate></item><item><title><![CDATA[Reply to Tab5: disable speaker when headphones are plugged in on Thu, 11 Dec 2025 23:00:25 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/milaidin" aria-label="Profile: milaidin">@<bdi>milaidin</bdi></a> :<br />
Poking around in the <a href="https://docs.m5stack.com/en/core/Tab5#schematics" target="_blank" rel="noopener noreferrer nofollow ugc">schematic</a> shows that the Audio jack has a switch pin connected to a line labelled <code>HP_DET</code> on the board. As far as I can tell this line is pulled low via <code>R47</code>&amp;<code>R48</code> unless there is a plug inserted. when it is pulled high via <code>R49</code> instead.<br />
This <code>HP_DET</code> line does not go directly  to the P4 chip, instead it goes to <code>U6</code>, which is a I2C I/O expander chip on the system I2C bus.</p>
<p dir="auto">If the source for the demo is available look for how this line is read, then turn the amplifier on/off as needed. The code for that should also be in the demo.</p>
]]></description><link>https://community.m5stack.com/post/30300</link><guid isPermaLink="true">https://community.m5stack.com/post/30300</guid><dc:creator><![CDATA[easytarget]]></dc:creator><pubDate>Thu, 11 Dec 2025 23:00:25 GMT</pubDate></item></channel></rss>