summaryrefslogtreecommitdiffstats
path: root/_site/log/etlas/index.html
diff options
context:
space:
mode:
Diffstat (limited to '_site/log/etlas/index.html')
-rw-r--r--_site/log/etlas/index.html153
1 files changed, 0 insertions, 153 deletions
diff --git a/_site/log/etlas/index.html b/_site/log/etlas/index.html
deleted file mode 100644
index 68c19ae..0000000
--- a/_site/log/etlas/index.html
+++ /dev/null
@@ -1,153 +0,0 @@
-<!DOCTYPE html>
-<html>
- <head>
- <meta charset="utf-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <title>Etlas: e-paper dashboard</title>
- <link rel="stylesheet" href="/assets/css/main.css">
- <link rel="stylesheet" href="/assets/css/skeleton.css">
-</head>
-
-
- <body>
-
- <div id="nav-container" class="container">
- <ul id="navlist" class="left">
-
- <li >
- <a href="/" class="link-decor-none">hme</a>
- </li>
- <li >
- <a href="/projects/" class="link-decor-none">poc</a>
- </li>
- <li >
- <a href="/about/" class="link-decor-none">abt</a>
- </li>
- <li>
- <a href="/cgi-bin/find.cgi" class="link-decor-none">lup</a>
- </li>
- <li>
- <a href="/feed.xml" class="link-decor-none">rss</a>
- </li>
- </ul>
-</div>
-
-
-
- <main>
- <div class="container">
- <div class="container-2">
- <h2 class="center" id="title">ETLAS: E-PAPER DASHBOARD</h2>
- <h5 class="center">05 SEPTEMBER 2024</h5>
- <br>
- <div class="twocol justify"><p>Repurposed the <a href="../e-reader/">e-reader</a> into something for regular use. News,
-stocks, weather dashboard. ESP32 NodeMCU D1 + 7.5” Waveshare e-paper + DHT22
-sensor.</p>
-
-<table style="border: none;">
- <tr style="border: none;">
- <td style="border: none;"><img src="dash.jpg" alt="front" style="width: 100%" /></td>
- <td style="border: none;"><img src="pcb.jpg" alt="back" style="width: 100%" /></td>
- </tr>
- <tr style="border: none;">
- <td colspan="2" style="border: none;"><img src="etlas_arch.png" alt="front" style="width: 100%" /></td>
- </tr>
-</table>
-
-<p>Stocks: Two weeks EOD data from Polygon.io (max possible). Flask app on VPS
-manages watchlist, relays the feed. Backend: httpd + htpasswd + slowcgi +
-Flask.</p>
-
-<p>gui_plot_stocks() plots a stepped graph; was easier to implement, but the code
-is hideous; triggers watchdog. vTaskDelay() prevents that.</p>
-
-<p>NOTE: Refactor. Bresenham’s?</p>
-
-<p>News: Channel NewsAsia RSS. MCU does the parsing. Didn’t plan to have a backend
-at the time. Now that I have one for stocks, should relay the feed for
-flexibility.</p>
-
-<p>Weather: DHT22 single-wire protocol. 26µs/50µs/70µs pulses are too fast for
-standard ESP32 APIs. Bit-banged relative pulse widths (ported from <a href="https://github.com/Fonger/ESP8266-RTOS-DHT" class="external" target="_blank" rel="noopener noreferrer">ESP8266</a>):</p>
-
-<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>static inline int dht_await_pin_state(int state, int timeout)
-{
- int t;
- static const uint16_t delta = 1;
-
- for (t = 0; t &lt; timeout; t += delta) {
- ets_delay_us(delta);
- if (gpio_get_level(DHT_PIN) == state)
- return t;
- }
- return 0;
-}
-
-static inline int dht_get_raw_data(unsigned char buf[BUFLEN])
-{
- int rc;
- unsigned char i, pwl, pwh;
-
- gpio_set_level(DHT_PIN, 0);
- ets_delay_us(1100);
- gpio_set_level(DHT_PIN, 1);
-
- if (!dht_await_pin_state(0, 40)) {
- rc = 1;
- xQueueSend(dht_evt_queue, &amp;rc, (TickType_t) 0);
- return 0;
- }
- if (!dht_await_pin_state(1, 80)) {
- rc = 2;
- xQueueSend(dht_evt_queue, &amp;rc, (TickType_t) 0);
- return 0;
- }
- if (!dht_await_pin_state(0, 80)) {
- rc = 3;
- xQueueSend(dht_evt_queue, &amp;rc, (TickType_t) 0);
- return 0;
- }
-
- for (i = 0; i &lt; BUFLEN; i++) {
- if (!(pwl = dht_await_pin_state(1, 50))) {
- rc = 4;
- xQueueSend(dht_evt_queue, &amp;rc, (TickType_t) 0);
- return 0;
- }
- if (!(pwh = dht_await_pin_state(0, 70))) {
- rc = 5;
- xQueueSend(dht_evt_queue, &amp;rc, (TickType_t) 0);
- return 0;
- }
- buf[i] = pwh &gt; pwl;
- }
- return 1;
-}
-</code></pre></div></div>
-
-<p>epd_init() stalls intermittently on first refresh() after flash. Toggling delay
-values in refresh() resolves it. If the first refresh succeeds, it remains
-stable. Root cause unknown–suspect noisy power supply due to powering display
-via MCU.</p>
-
-<p>Uptime: August 2024 - January 2026</p>
-
-<p>Commit:
-<a href="https://git.asciimx.com/etlas/commit/?id=a92c86ac1592c2137d3d1fec1668eacc2d0ca581">a92c86a</a></p>
-</div>
- <p class="post-author right">by W. D. Sadeep Madurange</p>
- </div>
- </div>
- </main>
-
- <div class="footer">
- <div class="container">
- <div class="twelve columns right container-2">
- <p id="footer-text">&copy; ASCIIMX - 2026</p>
- </div>
- </div>
-</div>
-
-
- </body>
-</html>