<?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[earth sensor module - looking for an example for digital reading]]></title><description><![CDATA[<p dir="auto">Hello, the earth sensor has an digital and an analog output pin. All examples are focused on analog reading.<br />
Can someone provide an example for digital reading?</p>
]]></description><link>https://community.m5stack.com/topic/6577/earth-sensor-module-looking-for-an-example-for-digital-reading</link><generator>RSS for Node</generator><lastBuildDate>Wed, 29 Apr 2026 13:42:08 GMT</lastBuildDate><atom:link href="https://community.m5stack.com/topic/6577.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 22 Jun 2024 17:34:15 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to earth sensor module - looking for an example for digital reading on Sun, 23 Jun 2024 07:16:08 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/herb" aria-label="Profile: herb">@<bdi>herb</bdi></a> What are you hoping to achieve as Digital rating only provides a 1 or 0.<br />
the only way to get values is through analogue and there is a project in the project zone of uiflow 2 found here <a href="https://uiflow2.m5stack.com/?pkey=3dd144a31f32480e9a7ed95461a9107a" target="_blank" rel="noopener noreferrer nofollow ugc">https://uiflow2.m5stack.com/?pkey=3dd144a31f32480e9a7ed95461a9107a</a></p>
]]></description><link>https://community.m5stack.com/post/25653</link><guid isPermaLink="true">https://community.m5stack.com/post/25653</guid><dc:creator><![CDATA[ajb2k3]]></dc:creator><pubDate>Sun, 23 Jun 2024 07:16:08 GMT</pubDate></item><item><title><![CDATA[Reply to earth sensor module - looking for an example for digital reading on Sun, 23 Jun 2024 02:38:57 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/herb" aria-label="Profile: herb">@<bdi>herb</bdi></a> Here you go:<br />
<a href="https://github.com/m5stack/M5Stack/blob/master/examples/Unit/EARTH/EARTH.ino" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/m5stack/M5Stack/blob/master/examples/Unit/EARTH/EARTH.ino</a><br />
Both analog and digital.<br />
The earth sensor is rather...'simple'<br />
<img src="/assets/uploads/files/1719088366751-screenshot-2024-06-22-at-4.32.26-pm-resized.png" alt="Screenshot 2024-06-22 at 4.32.26 PM.png" class=" img-fluid img-markdown" /><br />
from the docs page<br />
<a href="https://docs.m5stack.com/en/unit/earth" target="_blank" rel="noopener noreferrer nofollow ugc">https://docs.m5stack.com/en/unit/earth</a><br />
you can see that the 'Ain' just reads the voltage across the sensor and the 'Din' is at least the threshold comparator, adjusted by the trim pot on back.</p>
]]></description><link>https://community.m5stack.com/post/25647</link><guid isPermaLink="true">https://community.m5stack.com/post/25647</guid><dc:creator><![CDATA[teastain]]></dc:creator><pubDate>Sun, 23 Jun 2024 02:38:57 GMT</pubDate></item></channel></rss>