<?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[Reading analog temperature from LM35 sensor]]></title><description><![CDATA[<p dir="auto">I have M5Stack Core 2. I connected the LM35 sensor to Gnd, Vcc and SDL ports using a grove connector cable. The I am reading the sample using analogRead(32). I am getting values around 1163 which does not seem to change at lower temperature. Without connection there is a different consultant value. Please help.</p>
]]></description><link>https://community.m5stack.com/topic/3801/reading-analog-temperature-from-lm35-sensor</link><generator>RSS for Node</generator><lastBuildDate>Mon, 11 May 2026 14:20:27 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/3801.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 03 Dec 2021 18:38:41 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Reading analog temperature from LM35 sensor on Sat, 04 Dec 2021 09:51:57 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ankurj77" aria-label="Profile: ankurj77">@<bdi>ankurj77</bdi></a></p>
<p dir="auto">You will find in another post interesting information given by ROBALSTONA</p>
<p dir="auto"><a href="https://community.m5stack.com/topic/3782/waterproof-temperature-probe/5">https://community.m5stack.com/topic/3782/waterproof-temperature-probe/5</a></p>
]]></description><link>https://community.m5stack.com/post/15723</link><guid isPermaLink="true">https://community.m5stack.com/post/15723</guid><dc:creator><![CDATA[Arno]]></dc:creator><pubDate>Sat, 04 Dec 2021 09:51:57 GMT</pubDate></item><item><title><![CDATA[Reply to Reading analog temperature from LM35 sensor on Sat, 04 Dec 2021 09:16:37 GMT]]></title><description><![CDATA[<p dir="auto">Hello <a class="plugin-mentions-user plugin-mentions-a" href="/user/ankurj77" aria-label="Profile: ankurj77">@<bdi>ankurj77</bdi></a></p>
<p dir="auto">Short answers:</p>
<ul>
<li>no, most likely analog signals cannot be read from M5Core2 port A due to the two pull-up resistors.</li>
<li>no, port A doesn't need to be enabled first. It is already enabled.</li>
<li>no, analog signals don't need a clock. The clock is used for I2C.</li>
</ul>
<p dir="auto">Note: as mentioned before, I don't own an LM35 and cannot test this myself, so my conclusions, solely drawn from reading the schematic, could be incorrect.</p>
<p dir="auto">Long answer:<br />
M5Stack has defined three Groove ports A, B and C.</p>
<ul>
<li>A (red) is by default used for <a href="https://en.wikipedia.org/wiki/I%C2%B2C" target="_blank" rel="noopener noreferrer nofollow ugc">I2C</a> (found on M5Core2)</li>
<li>B (black) is by default used for <a href="https://en.wikipedia.org/wiki/Digital-to-analog_converter" target="_blank" rel="noopener noreferrer nofollow ugc">DAC</a> / <a href="https://en.wikipedia.org/wiki/Analog-to-digital_converter" target="_blank" rel="noopener noreferrer nofollow ugc">ADC</a> (found on M5GO Bottom2)</li>
<li>C (blue) is by default used for <a href="https://en.wikipedia.org/wiki/Universal_asynchronous_receiver-transmitter" target="_blank" rel="noopener noreferrer nofollow ugc">UART</a> (found on M5GO Bottom2)</li>
</ul>
<p dir="auto">There are exceptions to the above where a function can be setup and used on a port not meant for that. In case of port A in M5Core2 there are this two pull-up resistors already in place (which are required for I2C to function) but they also might or might not influence other usage.</p>
<p dir="auto">Given that in your case you are reading the same value independent of the actual temperature, I assume that yes, the pull-up resistor messes with the analog signal from the LM35 and therefore port A most likely cannot be used for the LM35.</p>
<p dir="auto">Your best bet would probably be to get an <a href="https://docs.m5stack.com/en/base/m5go_bottom2" target="_blank" rel="noopener noreferrer nofollow ugc">M5GO Bottom2</a> and then use port B (ADC) for the LM35. Or you could get an <a href="https://docs.m5stack.com/en/unit/envIII" target="_blank" rel="noopener noreferrer nofollow ugc">EnvIII</a> Sensor (temperature and humidity air pressure) which uses I2C and works on port A.</p>
<p dir="auto">Thanks<br />
Felix</p>
]]></description><link>https://community.m5stack.com/post/15722</link><guid isPermaLink="true">https://community.m5stack.com/post/15722</guid><dc:creator><![CDATA[felmue]]></dc:creator><pubDate>Sat, 04 Dec 2021 09:16:37 GMT</pubDate></item><item><title><![CDATA[Reply to Reading analog temperature from LM35 sensor on Fri, 03 Dec 2021 21:53:24 GMT]]></title><description><![CDATA[<p dir="auto">Does it mean that analog inputs cannot be read from grove ports on Core 2? Do I need to enable the Port A first somehow or do I need to enable the clock (port 33). The documentation is quite sleek and I cannot wrap my head around this.</p>
]]></description><link>https://community.m5stack.com/post/15714</link><guid isPermaLink="true">https://community.m5stack.com/post/15714</guid><dc:creator><![CDATA[ankurj77]]></dc:creator><pubDate>Fri, 03 Dec 2021 21:53:24 GMT</pubDate></item><item><title><![CDATA[Reply to Reading analog temperature from LM35 sensor on Fri, 03 Dec 2021 20:51:02 GMT]]></title><description><![CDATA[<p dir="auto">Hello <a class="plugin-mentions-user plugin-mentions-a" href="/user/ankurj77" aria-label="Profile: ankurj77">@<bdi>ankurj77</bdi></a></p>
<p dir="auto">according to the M5Core2 schematic, GPIO32 and GPIO33, both already have a 5.1 k pull-up resistor in place, since Groove port A normally is meant to be used for I2C.</p>
<p dir="auto">That said, I don't have an LM35 to test myself, but most likely this pull-up resistor has an influence on the final value read from the analog output of the LM35.</p>
<p dir="auto">Thanks<br />
Felix</p>
]]></description><link>https://community.m5stack.com/post/15710</link><guid isPermaLink="true">https://community.m5stack.com/post/15710</guid><dc:creator><![CDATA[felmue]]></dc:creator><pubDate>Fri, 03 Dec 2021 20:51:02 GMT</pubDate></item></channel></rss>