diff --git a/Firmware/simulator/README.md b/Firmware/simulator/README.md index 7ed6c18..70a1e90 100644 --- a/Firmware/simulator/README.md +++ b/Firmware/simulator/README.md @@ -29,6 +29,7 @@ One row per day, in short; the details are in the sections of this file (the lin | Date | What changed | |---|---| +| 10 Nov 2026 | Teensy page: the pretend UM982 reports its temperature (59 °C, from `HWSTATUSA`) and the module's name on the network reads `AiO-3F2A`, as the firmware now does. | | 9 Nov 2026 | **Set up AgOpenWeb from your measures** 1.3: front corner, drawbar at the tyre, turns by headland, reasons ([the page](#set-up-agopenweb-from-your-measures)). Seed drill: 19 sections offline; short start page. [Action](#how-it-is-built) on Node 24. Check: pages in a web card's frame ([How it is built](#how-it-is-built)). | | 8 Nov 2026 | **Set up AgOpenWeb from your measures**: a calculator that turns the tractor and implement measures into the U-turn, headland and tramline settings, with the reasons, a drawing, examples and drawbars kept off the rear tyres ([the page](#set-up-agopenweb-from-your-measures)). | | 7 Nov 2026 | The seed drill page's four tabs and Firmware tab checked, with a made-up newer `.bin` "on GitHub"; `firmware.json` lists the seed drill `.bin` once it is on `main`; the modules' names on the network ([How it is built](#how-it-is-built)). | diff --git a/Firmware/simulator/sim-common.js b/Firmware/simulator/sim-common.js index 7a40bbc..81b05a9 100644 --- a/Firmware/simulator/sim-common.js +++ b/Firmware/simulator/sim-common.js @@ -342,6 +342,7 @@ function Module(key) { L.push([9.0, "[status] GPS: RTK float (fix 5, 25 satellites, correction age 1.0 s)"]); L.push([9.5, "[status] GPS: the receiver sends (last 5 s): " + rxTypes()]); if (hasImu) L.push([10.0, "[status] " + h.imu + ": data OK (roll, and heading without dual antenna)"]); + if (um) L.push([11.0, "[status] GPS receiver: temperature 59 C (UM982 HWSTATUSA, first field 59493, read as thousandths of a degree)"]); if (dual && rx.dual === "um982" && cfg.hprAcceptFloat) L.push([12.0, "[status] Dual: dual-antenna heading OK (HPR QF 5 float), sent as " + (classic ? "$PAOGI" : "$GNTHS")]); L.push([22.0, "[status] GPS: RTK fixed (fix 4, 26 satellites, correction age 0.8 s)"]); if (dual) L.push([22.0, "[status] Dual: dual-antenna heading OK (" + (rx.dual === "f9p" ? "second F9P, RELPOSNED, RTK" : "HPR QF 4") + " fixed), sent as " + (classic ? "$PAOGI" : "$GNTHS")]); @@ -437,9 +438,11 @@ function Module(key) { if (p === 1 && !f9p2Here()) return "none"; // GPS2 set to a second F9P, but a XIAO is there return T() < 3 ? "wait" : "ok"; } - // the receiver's temperature (UBX-MON-SYS, polled every 10 s): the X20P answers 0 (not filled), an F9P on HPG 1.13 does not answer + // the receiver's temperature (UBX-MON-SYS, polled every 10 s): the X20P answers 0 (not filled), an F9P on HPG 1.13 does not answer; + // a UM982 answers HWSTATUSA (thousandths of a degree in its first field) function rxTemp(p, t) { const kind = p === 0 ? rx.kind : "ublox", fw = p === 0 ? rx.fw : "HPG 1.13"; + if (kind === "um982") return t < 11 ? {tempSt: "ask"} : {temp: 59, tempSt: "ok"}; if (kind !== "ublox") return {tempSt: ""}; if (fw === "HPG 1.13") return {tempSt: t < 35 ? "ask" : "none"}; return {tempSt: t < 15 ? "ask" : "zero"}; // the X20P (HPG 2.11) answers, always with 0 (bench, 4 Nov 2026): not filled @@ -493,7 +496,7 @@ function Module(key) { const j = {fw: fwName() + " " + fwVer(), built: built(), target: "fw_teensy41", marker: "AiO-WEB-OTA-1", up: up, ip: ip(), cpuMhz: 450, cpuTemp: r2(46.2 + wob(t, 1.5, 0.05), 1), cpuTempMax: 51.2, cpuHot: false, // the Teensy's clock and temperature (zSafety.ino) prev: st.prev || null}; // the firmware that ran before the last update, kept in the flash (zOTA.ino otaPrevGet) - j.net = {link: true, mdns: "AiO 3F2A", aog: t >= 6, aogIp: t >= 6 ? st.net + ".10" : "0.0.0.0", host: host, hostBoth: false, helloAgo: t >= 6 ? 0 : -1, + j.net = {link: true, mdns: "AiO-3F2A", aog: t >= 6, aogIp: t >= 6 ? st.net + ".10" : "0.0.0.0", host: host, hostBoth: false, helloAgo: t >= 6 ? 0 : -1, rtcm: rtcm, rtcmKB: r2(rtcmT * 1.31, 1), rtcmBps: rtcm ? Math.round(1310 + wob(t, 60, 0.2)) : 0, rtcmOk: Math.floor(rtcmT * 4.6), rtcmBad: t > 60 ? 1 : 0, rtcmTypes: rtcm ? (um ? "1006 1008 1033 1075 1085 1095 1125 1230" : "1005 1074 1084 1094 1124 1230") : "", radio: false, radioKB: 0, radioBps: 0, radioOk: 0, radioBad: 0, radioTypes: ""}; diff --git a/Firmware/v4.5_AiO_WEB/CLAUDE.md b/Firmware/v4.5_AiO_WEB/CLAUDE.md index fbcacf5..0331e49 100644 --- a/Firmware/v4.5_AiO_WEB/CLAUDE.md +++ b/Firmware/v4.5_AiO_WEB/CLAUDE.md @@ -98,7 +98,7 @@ The files are flat, but they group into modules like the AiO 26 `lib/aio_*` fold | `zHandlers.ino` | GGA / VTG / HPR handlers, epoch assembly, IMU heading fusion, standard / classic output, PGN 247 vehicle geometry | | `zNMEAParser.h` | NMEA parser (Glinnes Hulden, CC0) | | `zDualF9P.ino` | Second F9P on Serial2: UBX-NAV-RELPOSNED → dual heading and roll; its flags (refPosMiss / refObsMiss, relPosHeadingValid) explain a missing heading | -| `zReceiver.ino` / `.h` | Receiver identification (VERSIONA / UBX-MON-VER), its temperature (UBX-MON-SYS), u-blox and UM982 settings from the web page, UBX frames taken out of the stream | +| `zReceiver.ino` / `.h` | Receiver identification (VERSIONA / UBX-MON-VER), its temperature (UBX-MON-SYS; a UM982: HWSTATUSA), u-blox and UM982 settings from the web page, UBX frames taken out of the stream | | `zRxCheck.ino` / `.h` | Receiver check: data at 460800, baud search, settings against the AgOpenGPS files | | `zRxConfig.h` | AOGConfigOMatic settings (generated by a script, do not edit by hand) | | `zUdpNtrip.ino`, `zRtcm.h` | NTRIP from the program (UDP 2233) to the receiver; RTCM message counter | diff --git a/Firmware/v4.5_AiO_WEB/README.md b/Firmware/v4.5_AiO_WEB/README.md index b3a7a82..431504c 100644 --- a/Firmware/v4.5_AiO_WEB/README.md +++ b/Firmware/v4.5_AiO_WEB/README.md @@ -31,7 +31,7 @@ One row per day, in short; the details are in the sections of this file (the lin | Date | What changed | |---|---| -| 10 Nov 2026 | A temperature that a device does not give (UM982, some u-blox firmware, an older XIAO program) now reads just *not reported* ([Identification](#identification)). | +| 10 Nov 2026 | The UM982's temperature is read (`HWSTATUSA`); one a device does not give reads *not reported* ([Identification](#identification)). Tabs and light/dark button 44 px high, 8 px corners; network name `AiO-xxxx`, with a hyphen ([Web page](#web-page)). | | 9 Nov 2026 | The page's questions (TM171, receiver set-up, settings, firmware, restart) in its own box: the browser's pop-ups show nothing inside an AgOpenWeb web card, so those buttons did nothing there ([Web page](#web-page)). | | 7 Nov 2026 | Add-on card (`_aowcard._tcp`) under a unique name, on the Connections card. Status cards reordered, steering settings folded into Steering; Machine tab reads the sprayer's PGN 161 (rate, alarms) ([Web page](#web-page)). Shorter notes, short headers. | | 4 Nov 2026 | Built at **450 MHz** (cooler; the loop has time to spare). Temperatures on the cards: the Teensy with its clock ([Firmware tab](#web-page)), the u-blox [receivers](#identification), the [TM171](#imu-tm171-or-bno085) and the [XIAO](#xiao-esp32c3--esp32s3). | @@ -69,13 +69,13 @@ One row per day, in short; the details are in the sections of this file (the lin ## Web page -Open `http:///`, normally `http://192.168.5.126/` (the third number follows the subnet set in AgOpenWeb), or **`http://aio.local/`**: the module announces its name and its page by mDNS (DNS-SD `_http._tcp`, and `_aowcard._tcp` for the official AgOpenWeb's add-on cards), which works on Windows, Mac, iPhone and Linux (on many Android phones use the IP). In AgOpenWeb's web cards, ⚙ › **Search the network** lists the page within a second under the module's name on the network, **AiO** and four digits of the Teensy's own id (e.g. `AiO 3F2A`, shown on the Connections card), next to the XIAO's, the sprayer's and the seed drill's. There is no password: anyone on the module's network can open it. +Open `http:///`, normally `http://192.168.5.126/` (the third number follows the subnet set in AgOpenWeb), or **`http://aio.local/`**: the module announces its name and its page by mDNS (DNS-SD `_http._tcp`, and `_aowcard._tcp` for the official AgOpenWeb's add-on cards), which works on Windows, Mac, iPhone and Linux (on many Android phones use the IP). In AgOpenWeb's web cards, ⚙ › **Search the network** lists the page within a second under the module's name on the network, **AiO** and four digits of the Teensy's own id (e.g. `AiO-3F2A`, shown on the Connections card), next to the XIAO's, the sprayer's and the seed drill's. There is no password: anyone on the module's network can open it. **Another network** (not 192.168.5.x): the module keeps its subnet in the EEPROM. AgOpenWeb / AgOpenGPS change it when their subnet is set (PGN 201, the module restarts). It can also be changed by hand on the **XIAO's WiFi page** (WiFi tab → Module network), which is on WiFi whatever the module's IP is and shows the module's IP; type the first three numbers and the module restarts at the new IP. The module's own page only shows its IP (in the header): if you can open it you are on the right network already, and a wrong subnet typed there would leave the page unreachable. Dark or light: the ☀ / ☾ button at the top (remembered by the browser), otherwise the device's setting. -Every question the page asks (write to the TM171, load the receiver's settings, switch the WAS check off, install firmware, restart…) opens in a box of the page itself, not a browser pop-up: inside an AgOpenWeb web card the browser's pop-ups show nothing, so those buttons did nothing there (official `Docs/ADD_ON_CARDS.md`: the card's frame has no `allow-modals`). +Every question the page asks (write to the TM171, load the receiver's settings, switch the WAS check off, install firmware, restart…) opens in a box of the page itself, not a browser pop-up: inside an AgOpenWeb web card the browser's pop-ups show nothing, so those buttons did nothing there (official `Docs/ADD_ON_CARDS.md`: the card's frame has no `allow-modals`). The tabs and the light/dark button at the top are 44 px high, with the same 8 px corners as that box's buttons: a size a finger hits on the cab's screen. **Without a module:** the [simulator](https://renatorgr.github.io/Boards/) shows this page and the XIAO's with a pretend module behind them (any GPS, IMU, steering and program; tractor driving or parked), rebuilt from the code on every change. See [`Firmware/simulator`](../simulator). @@ -162,9 +162,11 @@ After the receiver's first second, the Teensy asks it what it is: `VERSIONA` (UM What goes to the program does not depend on this: a receiver that sends HPR is treated as dual antenna. -**Temperature** (since 4 Nov 2026): once a u-blox receiver is identified, the Teensy asks it for `UBX-MON-SYS` every 10 s and shows its temperature in the GNSS card (a row under the receiver) and on the GPS tab (the second F9P: in the dual-antenna card and in its check). A firmware without that message never answers (after three tries), and a receiver that answers 0 every time does not fill the field (Messages has the bytes of its first answer). The UM982 is not asked yet (Unicore's manual lists a `HWSTATUS` hardware status log; the firmware does not read it). In these cases the row reads just *not reported*, like the XIAO row when its program is older than 4 Nov 2026. A temperature that does arrive is always shown. +**Temperature** (since 4 Nov 2026): once a u-blox receiver is identified, the Teensy asks it for `UBX-MON-SYS` every 10 s and shows its temperature in the GNSS card (a row under the receiver) and on the GPS tab (the second F9P: in the dual-antenna card and in its check). A firmware without that message never answers (after three tries), and a receiver that answers 0 every time does not fill the field (Messages has the bytes of its first answer). In these cases the row reads just *not reported*, like the XIAO row when its program is older than 4 Nov 2026. A temperature that does arrive is always shown. -Seen on the bench on 4 Nov 2026: the ZED-X20P (HPG 2.11) answers with 0, the ZED-F9P on HPG 1.13 does not answer. So for now no receiver here shows a temperature; a newer receiver firmware may. +A **UM982** is asked `HWSTATUSA` (its hardware status) at the same pace, since 10 Nov 2026. The answer, as Renato's receiver (R4.10Build13495) gave it: `#HWSTATUSA,…;59493,0.914,1.025,1.805,1,-0.822,0.0,0x84,1,0x0377,0,0*6e81c92f`. After the `;` come one number, then the 0.9 V, 1.0 V and 1.8 V supplies, the clock and the hardware flags. The firmware shows that first number, divided by 1000, as the temperature in °C (59 °C here, in the closed box after 40 minutes). What could be read of Unicore's manual does not name that field, so this is a deduction, not a documented fact: the manual's own example has 66807 there, and a number that starts lower on a cold morning and climbs as the box warms confirms it. The first answer after start-up goes to Messages with the number as it came (`GPS receiver: temperature 59 C (UM982 HWSTATUSA, first field 59493, …)`), to compare a cold start with a warm one. A line with a wrong CRC is dropped, and a value outside -40 to 125 °C reads *not reported*. The poll waits while the page reads or writes the UM982's settings, and its answer stays out of the UM982 console. + +Seen on the bench on 4 Nov 2026: the ZED-X20P (HPG 2.11) answers with 0, the ZED-F9P on HPG 1.13 does not answer. So of the receivers here only the UM982 shows a temperature; a newer u-blox firmware may. ### Receiver check (GPS tab) @@ -393,7 +395,7 @@ The addresses only mean something with that build. Send the `.elf` too: Arduino NativeEthernet runs the network stack (FNET) from a 1 ms timer interrupt, which could change the stack's memory in the middle of a network call from the loop (the crash at `0x0001D542`). The firmware stops that timer after `Ethernet.begin()` and runs the stack itself from the loop and in every wait for the network (`zNet.h`). NativeEthernet itself is not changed. -The mDNS responder (`aio.local`; the page announced as `_http._tcp` for the fork's **Search the network** and as `_aowcard._tcp` with TXT `v=1` and `path=/` for the official AgOpenWeb's add-on cards, `Docs/ADD_ON_CARDS.md`, both under the instance name `AiO xxxx`) is FNET's own, started after the IP is set (`mdnsStart` in `zEthernet.ino`) and run by the same polling. The four digits come from the Teensy's serial id, because the Ethernet MAC is the same on every AiO board. +The mDNS responder (`aio.local`; the page announced as `_http._tcp` for the fork's **Search the network** and as `_aowcard._tcp` with TXT `v=1` and `path=/` for the official AgOpenWeb's add-on cards, `Docs/ADD_ON_CARDS.md`, both under the instance name `AiO-xxxx`) is FNET's own, started after the IP is set (`mdnsStart` in `zEthernet.ino`) and run by the same polling. The four digits come from the Teensy's serial id, because the Ethernet MAC is the same on every AiO board. ## Main loop diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/README.md b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/README.md index 74fdcce..db5785f 100644 --- a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/README.md +++ b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/README.md @@ -23,6 +23,7 @@ Version 4.5, the same number as the Teensy firmware it goes with (v4.5_AiO_WEB). | Date | What changed | |---|---| +| 10 Nov 2026 | Tabs and the light/dark button 44 px high with 8 px corners; the WiFi tab's password to confirm in a card of its own, no longer a field across the page ([What it does](#what-it-does)). Messages give the size of an updated program, not 0 bytes. | | 9 Nov 2026 | The page's questions (save and restart, install, the module's firmware, subnet) in its own box: the browser's pop-ups show nothing inside an AgOpenWeb web card, so those buttons did nothing there ([What it does](#what-it-does)). | | 7 Nov 2026 | Add-on card (`_aowcard._tcp`) under the XIAO's own WiFi name ([What it does](#what-it-does)). Program → module shows up to 64 sections (PGN 229); the WiFi settings save in one row; a shorter note in the Module firmware card; short file headers. | | 4 Nov 2026 | The XIAO's temperature in its card, here and on the Teensy page; the Teensy's clock and temperature in the [Module card](#what-it-does). | @@ -63,6 +64,8 @@ Version 4.5, the same number as the Teensy firmware it goes with (v4.5_AiO_WEB). - Changes (WiFi, update, restart) **ask for the password of the XIAO's own network**, to confirm. - The question before each one (save and restart, install, the module's firmware, the subnet) opens in a box of the page itself, not a browser pop-up: inside an AgOpenWeb web card the browser's pop-ups show nothing, so those buttons did nothing there. + - The tabs and the light/dark button at the top are 44 px high, with the same 8 px corners as that box's buttons: a size a finger hits on the cab's screen. + - On the WiFi tab the password and **Save and restart the XIAO** have a card of their own, *Confirm and save*, as wide as the other two. - Typed once, it is filled in both tabs until the page is closed. - The page never shows or stores it. - Just viewing the page needs nothing more than being on the network. diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/v4.5_XIAO_ESP32.ino b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/v4.5_XIAO_ESP32.ino index 569be59..edfcae3 100644 --- a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/v4.5_XIAO_ESP32.ino +++ b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/v4.5_XIAO_ESP32.ino @@ -540,6 +540,7 @@ static void apiScan() // Program update: the .bin from "Sketch > Export Compiled Binary" static bool updOk = false; static String updErr; +static size_t updBytes = 0; // size of the program received (Update.progress() reads 0 once Update.end() has run) // How long an upload may wait for the next data from the browser (3 Nov 2026). The web server gives up after 5 s // (HTTP_MAX_SEND_WAIT), and a weak Wi-Fi link can pause longer than that: the upload was then cut off with nothing @@ -577,6 +578,7 @@ static void updateUpload() { if (updErr.length() == 0) { + updBytes = up.totalSize; if (Update.end(true)) updOk = true; else updErr = Update.errorString(); } @@ -596,7 +598,7 @@ static void updateDone() { if (updOk) { - logEvent("Program update: %u bytes checked, restarting", (unsigned)Update.progress()); + logEvent("Program update: %u bytes checked, restarting", (unsigned)updBytes); server.send(200, "application/json", "{\"ok\":true}"); rebootAtMs = millis() + 1500; } diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/xPage.h b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/xPage.h index 4849149..ef3c3c3 100644 --- a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/xPage.h +++ b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32/xPage.h @@ -29,19 +29,18 @@ const char XIAO_PAGE[] PROGMEM = R"XIAOPAGE( @media (prefers-color-scheme:light){:root:not([data-theme]){color-scheme:light;--bg:#f2f4ef;--card:#ffffff;--ink:#1c2318;--mute:#5f6b5a;--line:#d4dbcf;--ok:#2e7d32;--warn:#b45309;--bad:#c62828;--acc:#4c7d2a;--accInk:#ffffff;--soft:#e9eee5}} *{box-sizing:border-box} body{margin:0;background:var(--bg);color:var(--ink);accent-color:var(--acc);font:15px/1.45 system-ui,-apple-system,"Segoe UI",Roboto,sans-serif} -header{display:flex;align-items:center;gap:10px;padding:10px 16px;background:var(--card);border-bottom:1px solid var(--line)} +header{display:flex;align-items:center;gap:10px;padding:2px 16px;min-height:48px;background:var(--card);border-bottom:1px solid var(--line)} #top{position:sticky;top:0;z-index:3} /* header and tabs stay in view while the page scrolls (small windows, the program's web cards) */ header h1{font-size:16px;margin:0;font-weight:650;white-space:nowrap} header .sub{color:var(--mute);font-size:13px;flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis} .dot{width:11px;height:11px;border-radius:50%;background:var(--bad);flex:none} .dot.on{background:var(--ok)} -nav{display:flex;gap:6px;padding:8px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} -nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:999px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} +nav{display:flex;gap:6px;padding:4px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} +nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:8px;min-height:44px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} nav button.on{background:var(--acc);border-color:var(--acc);color:var(--accInk)} main{padding:14px 16px 40px;max-width:1100px;margin:0 auto} .grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:12px} .grid3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px} -.saverow{grid-column:1/-1;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:0 12px;align-items:end;padding:0 14px}.saverow .note{grid-column:1/-1} @media (max-width:760px){.grid3{grid-template-columns:1fr}} .card{background:var(--card);border:1px solid var(--line);border-radius:12px;padding:12px 14px;min-width:0} .card h2{font-size:12.5px;text-transform:uppercase;letter-spacing:.05em;color:var(--mute);margin:0 0 8px;font-weight:650} @@ -86,7 +85,7 @@ h3{font-size:14px;margin:14px 0 4px} .info{background:color-mix(in srgb,var(--acc) 16%,transparent);border:1px solid var(--acc);border-radius:12px;padding:9px 12px;margin:0 0 12px;font-weight:600} .info.warn{background:color-mix(in srgb,var(--warn) 16%,transparent);border-color:var(--warn)} a{color:var(--acc)} -.tbtn{margin-left:auto;flex:none;border:1px solid var(--line);background:var(--soft);color:var(--ink);border-radius:999px;padding:3px 11px;font:inherit;font-size:13px;font-weight:650;cursor:pointer} +.tbtn{margin-left:auto;flex:none;border:1px solid var(--line);background:var(--soft);color:var(--ink);border-radius:8px;min-width:44px;min-height:44px;padding:0;font:inherit;font-size:18px;font-weight:650;cursor:pointer} @media (max-width:520px){header .sub{display:none}} /* the page's own question box (ask / askText in the script): the browser's confirm() and prompt() show nothing inside an AgOpenWeb web card (its frame has no allow-modals), so the page never uses them; buttons 44 px high, as the cards ask */ @@ -156,10 +155,10 @@ a{color:var(--acc)} -
+

Confirm and save

-

The XIAO restarts to apply them. If you change the name or the password of the XIAO network, connect the phone to the new network again. Forgot the password? Through the USB port on the panel, in the serial monitor: wifi-reset.

+

The XIAO restarts to apply the new settings. If you change the name or the password of the XIAO network, connect the phone to the new network again. Forgot the password? Through the USB port on the panel, in the serial monitor: wifi-reset.

diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/README.md b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/README.md index 3adf594..e3fe73f 100644 --- a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/README.md +++ b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/README.md @@ -4,7 +4,7 @@ The same program (`v4.5_XIAO_ESP32`, for the Teensy firmware v4.5_AiO_WEB), comp The ESP32C3 and the ESP32S3 are different chips: each needs its own file. -**Built:** 9 Nov 2026 (C3 15:49, S3 15:50), from the program as it is after the pull request that moves the page's questions (save and restart, install, the module's firmware) into the page's own box, for the AgOpenWeb web cards. Compiled in the cloud with the ESP32 core 3.3.12 (arduino-cli, the board's default settings, the same as in the program's README). +**Built:** 10 Nov 2026 (C3 20:40, S3 20:41), from the program as it is after the pull request that makes the tabs and the light/dark button 44 px high and gives the WiFi tab's password its own card. Compiled in the cloud with the ESP32 core 3.3.12 (arduino-cli, the board's default settings, the same as in the program's README). When the program in `v4.5_XIAO_ESP32` changes, compile these files again and upload them over the old ones, with the same names. **Install from GitHub** on the XIAO page offers a file when it was compiled later than the program running on the XIAO (the date is read from the file). | File | What for | diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3.bin b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3.bin index a91427a..b4126e8 100644 Binary files a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3.bin and b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3.bin differ diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3_USB.bin b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3_USB.bin index 0fdac97..4c1e3aa 100644 Binary files a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3_USB.bin and b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32C3_USB.bin differ diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3.bin b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3.bin index bd7ddcf..799830b 100644 Binary files a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3.bin and b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3.bin differ diff --git a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3_USB.bin b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3_USB.bin index 4838fcb..7ee692a 100644 Binary files a/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3_USB.bin and b/Firmware/v4.5_AiO_WEB/v4.5_XIAO_ESP32_bin/v4.5_XIAO_ESP32S3_USB.bin differ diff --git a/Firmware/v4.5_AiO_WEB/zEthernet.ino b/Firmware/v4.5_AiO_WEB/zEthernet.ino index b0986e9..1371f2c 100644 --- a/Firmware/v4.5_AiO_WEB/zEthernet.ino +++ b/Firmware/v4.5_AiO_WEB/zEthernet.ino @@ -78,9 +78,10 @@ void EthernetStart() // of the Teensy's own serial id (mdnsName; the Ethernet MAC is the same on every AiO board). It is FNET's own // responder (fnet_mdns, built into NativeEthernet), run from loop() by netPoll() like the rest of the stack; it // answers queries sent from any port by unicast (RFC 6762 6.7), which is how AgOpenWeb asks. A name clash on -// the network is settled by FNET (it adds a number to the name). +// the network is settled by FNET (it adds a number to the name). The name is written like the XIAO's ("XIAO-3F2A") and the +// sprayer's ("Sprayer-5F28"): a hyphen, no space. #define MDNS_HOST "aio" -char mdnsName[12] = ""; // "AiO 3F2A": the instance name of both services (the Connections card, zWeb.ino) +char mdnsName[12] = ""; // "AiO-3F2A": the instance name of both services (the Connections card, zWeb.ino) #ifdef ARDUINO_TEENSY41 static const fnet_mdns_txt_key_t* aowcardTxt() // the TXT record of "_aowcard._tcp" @@ -93,7 +94,7 @@ static const fnet_mdns_txt_key_t* aowcardTxt() // the TXT record of "_aowcard._ static void mdnsStart() { #ifdef ARDUINO_TEENSY41 - snprintf(mdnsName, sizeof(mdnsName), "AiO %04X", (unsigned)(HW_OCOTP_MAC0 & 0xFFFF)); + snprintf(mdnsName, sizeof(mdnsName), "AiO-%04X", (unsigned)(HW_OCOTP_MAC0 & 0xFFFF)); MDNS.begin(MDNS_HOST, 2); // the host name and room for two services MDNS.setServiceName(mdnsName); // NativeEthernet: one instance name for every service MDNS.addService("_http._tcp", 80); // the web page, for the fork's "Search the network" diff --git a/Firmware/v4.5_AiO_WEB/zHandlers.ino b/Firmware/v4.5_AiO_WEB/zHandlers.ino index 6fdbbc0..f0f013e 100644 --- a/Firmware/v4.5_AiO_WEB/zHandlers.ino +++ b/Firmware/v4.5_AiO_WEB/zHandlers.ino @@ -390,6 +390,8 @@ static void rxReplyNote(const char* l) const bool answer = !strncmp(l, "$command", 8); // the answer to the Teensy's own VERSIONA (zReceiver.ino) is not shown in the console if (answer && (int32_t)(rxIdQuietUntil - millis()) > 0 && (int32_t)(rxReplyUntilMs - millis()) <= 0 && strstr(l, "VERSIONA")) return; + // nor is the one to its HWSTATUSA, the UM982's temperature poll + if (answer && (int32_t)(rxTempQuietUntil - millis()) > 0 && (int32_t)(rxReplyUntilMs - millis()) <= 0 && strstr(l, "HWSTATUSA")) return; // nor are the answers to the page's UM982 settings (zReceiver.ino), unless a command was typed in the console if (answer && umQuiet() && (int32_t)(rxReplyUntilMs - millis()) <= 0) return; if (!answer && ((int32_t)(rxReplyUntilMs - millis()) <= 0 || isNormalOutput(l))) return; @@ -422,6 +424,7 @@ void rawNmeaTee(char c) rawLine[rawLen] = '\0'; if (nmeaLineOk(rawLine)) rxCkGood[RXCK_GPS]++; // valid data at 460800 (zRxCheck.ino) if (!strncmp(rawLine, "#VERSIONA", 9)) rxIdLine(rawLine); // the Unicore receiver's answer (zReceiver.ino) + else if (!strncmp(rawLine, "#HWSTATUSA", 10)) rxTempLine(rawLine); // the UM982's temperature (zReceiver.ino) else if (!umIsReply(rawLine)) noteRxType(rawLine); // answers to commands are not sentence types } if (rawLen > 6 && rawLine[0] == '$') diff --git a/Firmware/v4.5_AiO_WEB/zReceiver.h b/Firmware/v4.5_AiO_WEB/zReceiver.h index 9e6707a..3c451be 100644 --- a/Firmware/v4.5_AiO_WEB/zReceiver.h +++ b/Firmware/v4.5_AiO_WEB/zReceiver.h @@ -42,14 +42,17 @@ extern uint32_t rxIdQuietUntil; // millis: the console ignores the answer // AiO_WEB 4 Nov 2026: the receivers' own temperature, UBX-MON-SYS (tempValue, degrees C), polled by zReceiver.ino // (GPS1) and zDualF9P.ino (the second F9P). A firmware without that message never answers: after RX_TEMP_TRIES -// unanswered polls the page says so. The UM982 has no such command. A receiver that answers 0 every time does not -// fill the field (the ZED-X20P on HPG 2.11, seen 4 Nov 2026 in a 24 C room): "not reported" too, until it sends -// another value. +// unanswered polls the page says so. A receiver that answers 0 every time does not fill the field (the ZED-X20P on +// HPG 2.11, seen 4 Nov 2026 in a 24 C room): "not reported" too, until it sends another value. +// A UM982 is asked HWSTATUSA (its hardware status) at the same pace: the first field of the answer, in thousandths +// of a degree (rxTempLine in zReceiver.ino says what is known about that field). #define RX_TEMP_NONE -128 // not reported (yet) #define RX_TEMP_MS 10000 // polled this often, once the receiver is identified and talking #define RX_TEMP_TRIES 3 // unanswered polls before "this firmware does not report it" extern int8_t rxTemp; // GPS1 extern uint32_t rxTempMs; // when GPS1 last reported it (0 = never) +extern uint32_t rxTempQuietUntil; // millis: the console ignores the answer to the automatic HWSTATUSA until then +void rxTempLine(const char* line); // the UM982's "#HWSTATUSA..." line const char* rxTempState(uint32_t reportedMs, uint8_t asks, bool real); // "ok", "old", "zero", "ask" or "none" for the page void rxTempZeroLog(const char* who, const uint8_t* p, uint16_t len); // the first answer with 0: logged once void rxTempJson(Json& j); // GPS1: "temp" (when known) and "tempSt" diff --git a/Firmware/v4.5_AiO_WEB/zReceiver.ino b/Firmware/v4.5_AiO_WEB/zReceiver.ino index 7534b39..4a65380 100644 --- a/Firmware/v4.5_AiO_WEB/zReceiver.ino +++ b/Firmware/v4.5_AiO_WEB/zReceiver.ino @@ -3,7 +3,7 @@ Written 2026 by Claude (Anthropic) for renatorgr. The u-blox messages and configuration keys are those of the u-blox ZED-F9P / ZED-X20P interface descriptions (UBX-MON-VER, UBX-CFG-VALGET, UBX-CFG-VALSET, UBX-ACK); the Unicore - commands (VERSIONA, CONFIG, MASK, UNMASK, UNILOGLIST, MODE, UNLOG, SAVECONFIG and the log + commands (VERSIONA, HWSTATUSA, CONFIG, MASK, UNMASK, UNILOGLIST, MODE, UNLOG, SAVECONFIG and the log commands) are those of the Unicore N4 high precision commands and logs reference. The history of changes is in the README changelog and in the git log. Licence: GNU General Public License v3 or later (file COPYING), WITHOUT ANY WARRANTY. @@ -62,9 +62,10 @@ static uint32_t rxIdAskMs = 0; static uint32_t rxByteMs = 0; // last byte from the receiver static uint32_t rxTalkSinceMs = 0; // talking without a gap since static bool rxSilentSeen = true; // silent for RXID_SILENT_MS since the last round -// AiO_WEB 4 Nov 2026: its temperature (UBX-MON-SYS, zReceiver.h) +// AiO_WEB 4 Nov 2026: its temperature (UBX-MON-SYS; a UM982: HWSTATUSA; zReceiver.h) int8_t rxTemp = RX_TEMP_NONE; uint32_t rxTempMs = 0; +uint32_t rxTempQuietUntil = 0; static uint32_t rxTempAskMs = 0; static uint8_t rxTempAsks = 0; // unanswered polls (stops at RX_TEMP_TRIES) static bool rxTempReal = false; // a value other than 0 came (0 every time = the field is not filled) @@ -1143,8 +1144,8 @@ const char* umWriteRaw(const char* const* cmds, uint8_t n, const char* what) // ---------------------------------------------------------------- temperature (AiO_WEB 4 Nov 2026) // For the page: "ok" reported lately, "old" (no answer for a while), "ask" (not answered yet), "none" (asked -// RX_TEMP_TRIES times, never answered: a firmware without UBX-MON-SYS), "zero" (it answers, always with 0: the field -// is not filled). Also used for the second F9P (zDualF9P.ino). +// RX_TEMP_TRIES times, never answered: a firmware without UBX-MON-SYS or HWSTATUSA), "zero" (it answers, always with 0, +// or a UM982 with something that is not a temperature: the field is not filled). Also used for the second F9P (zDualF9P.ino). const char* rxTempState(uint32_t reportedMs, uint8_t asks, bool real) { if (reportedMs) return !real ? "zero" : millis() - reportedMs < 3 * RX_TEMP_MS ? "ok" : "old"; @@ -1154,7 +1155,41 @@ const char* rxTempState(uint32_t reportedMs, uint8_t asks, bool real) FLASHMEM void rxTempJson(Json& j) { if (rxTemp != RX_TEMP_NONE) j.i("temp", rxTemp); - j.str("tempSt", rxKind == RX_UBLOX ? rxTempState(rxTempMs, rxTempAsks, rxTempReal) : ""); + j.str("tempSt", rxKind == RX_UBLOX || rxKind == RX_UM982 ? rxTempState(rxTempMs, rxTempAsks, rxTempReal) : ""); +} + +// The UM982's answer to HWSTATUSA, its hardware status (zHandlers.ino, rawNmeaTee), as Renato's sent it on 10 Nov 2026: +// #HWSTATUSA,71,GPS,FINE,2444,241114900,0,0,18,13;59493,0.914,1.025,1.805,1,-0.822,0.0,0x84,1,0x0377,0,0*6e81c92f +// After the ';' come the first field, the 0.9 V, 1.0 V and 1.8 V supplies, the clock flag and drift and the hardware +// flags. What could be read of Unicore's manual does not name the first field. Read as thousandths of a degree C it +// is the chip's temperature: 59.5 C here, in the closed box after 40 minutes; the manual's own example has 66807. +// It is taken only from a line with the right CRC-32 and between -40 and 125 C; anything else reads "not reported" +// on the page. The first answer goes to Messages with the number as it came, to compare a cold start with a warm one. +FLASHMEM void rxTempLine(const char* l) +{ + if (rxKind != RX_UM982) return; + const char* star = strrchr(l, '*'); + const char* s = strchr(l, ';'); + if (!star || !s || s > star) return; + uint32_t crc = 0; // Unicore: CRC-32 (0xEDB88320, from 0) of the text between '#' and '*' + for (const char* p = l + 1; p < star; p++) + { + crc ^= (uint8_t)*p; + for (uint8_t b = 0; b < 8; b++) crc = (crc & 1) ? (crc >> 1) ^ 0xEDB88320UL : crc >> 1; + } + if (crc != strtoul(star + 1, nullptr, 16)) return; // damaged line: wait for the next one + char* end = nullptr; + const long m = strtol(s + 1, &end, 10); + const bool ok = end != s + 1 && *end == ',' && m >= -40000L && m <= 125000L; + const int8_t v = ok ? (int8_t)((m + (m >= 0 ? 500 : -500)) / 1000) : RX_TEMP_NONE; + if (!rxTempMs) + { + if (ok) StatusLog.line("[status] GPS receiver: temperature %d C (UM982 HWSTATUSA, first field %ld, read as thousandths of a degree)", (int)v, m); + else StatusLog.line("[status] GPS receiver: temperature not reported (UM982 HWSTATUSA: the first field, %.*s, is not a temperature)", (int)min(strcspn(s + 1, ",*"), (size_t)12), s + 1); + } + rxTempReal = ok; // not ok: "zero" for the page, which reads "not reported" + rxTemp = v; + rxTempMs = millis() | 1; } // The first UBX-MON-SYS answer with 0 C, in Messages with its bytes: tempValue is byte 18 (counted from 0), after @@ -1215,6 +1250,19 @@ void receiverLoop() { if (ubxSend(0x0A, 0x39, nullptr, 0)) { rxTempAskMs = now; if (!rxTempMs) rxTempAsks++; } } + // a UM982 is asked HWSTATUSA at the same pace (rxTempLine), but not while the page reads or writes its + // settings, nor while a command typed in the console waits for its answer + else if (talks && rxKind == RX_UM982 && !umQuiet() && (int32_t)(rxReplyUntilMs - now) <= 0 && !rxTxLen && !rxCkBusy(RXCK_GPS) + && now - rxTempAskMs >= RX_TEMP_MS && (rxTempMs || rxTempAsks < RX_TEMP_TRIES)) + { + static const uint8_t HWSTATUSA[] = "HWSTATUSA\r\n"; + if (rxTxQueue(HWSTATUSA, sizeof(HWSTATUSA) - 1)) + { + rxTempAskMs = now; + rxTempQuietUntil = now + 2000; // its "$command,HWSTATUSA,response: OK" stays out of the console + if (!rxTempMs) rxTempAsks++; + } + } break; } ubxOpLoop(now); diff --git a/Firmware/v4.5_AiO_WEB/zWebPage.h b/Firmware/v4.5_AiO_WEB/zWebPage.h index 0519a85..69f8730 100644 --- a/Firmware/v4.5_AiO_WEB/zWebPage.h +++ b/Firmware/v4.5_AiO_WEB/zWebPage.h @@ -39,14 +39,14 @@ const char WEB_PAGE[] PROGMEM = R"WEBPAGE( @media (prefers-color-scheme:light){:root:not([data-theme]){color-scheme:light;--bg:#f2f4ef;--card:#ffffff;--ink:#1c2318;--mute:#5f6b5a;--line:#d4dbcf;--ok:#2e7d32;--warn:#b45309;--bad:#c62828;--acc:#4c7d2a;--accInk:#ffffff;--soft:#e9eee5}} *{box-sizing:border-box} body{margin:0;background:var(--bg);color:var(--ink);accent-color:var(--acc);font:15px/1.45 system-ui,-apple-system,"Segoe UI",Roboto,sans-serif} -header{display:flex;align-items:center;gap:10px;padding:10px 16px;background:var(--card);border-bottom:1px solid var(--line)} +header{display:flex;align-items:center;gap:10px;padding:2px 16px;min-height:48px;background:var(--card);border-bottom:1px solid var(--line)} #top{position:sticky;top:0;z-index:3} /* header and tabs stay in view while the page scrolls (small windows, the program's web cards) */ header h1{font-size:16px;margin:0;font-weight:650;white-space:nowrap} header .sub{color:var(--mute);font-size:13px;flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis} .dot{width:11px;height:11px;border-radius:50%;background:var(--bad);flex:none} .dot.on{background:var(--ok)} -nav{display:flex;gap:6px;padding:8px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} -nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:999px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} +nav{display:flex;gap:6px;padding:4px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} +nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:8px;min-height:44px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} nav button.on{background:var(--acc);border-color:var(--acc);color:var(--accInk)} main{padding:14px 16px 40px;max-width:1100px;margin:0 auto} .grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(270px,1fr));gap:12px} @@ -109,7 +109,7 @@ progress{width:100%;height:14px} .alert{background:color-mix(in srgb,var(--bad) 18%,transparent);border:1px solid var(--bad);border-radius:12px;padding:9px 12px;margin:0 0 12px;white-space:pre-line;font-weight:600} .info{background:color-mix(in srgb,var(--acc) 16%,transparent);border:1px solid var(--acc);border-radius:12px;padding:9px 12px;margin:0 0 12px;font-weight:600} a{color:var(--acc)} -.tbtn{margin-left:auto;flex:none;border:1px solid var(--line);background:var(--soft);color:var(--ink);border-radius:999px;padding:3px 11px;font:inherit;font-size:13px;font-weight:650;cursor:pointer} +.tbtn{margin-left:auto;flex:none;border:1px solid var(--line);background:var(--soft);color:var(--ink);border-radius:8px;min-width:44px;min-height:44px;padding:0;font:inherit;font-size:18px;font-weight:650;cursor:pointer} @media (max-width:520px){header .sub{display:none}} /* the page's own question box (ask / askText in the script): the browser's confirm() and prompt() show nothing inside an AgOpenWeb web card (its frame has no allow-modals), so the page never uses them; buttons 44 px high, as the cards ask */ @@ -500,7 +500,7 @@ function render(s){ set("alt",(g.lat!==null&&g.alt)?Number(g.alt).toFixed(2)+" m":"–"); set("crc",String(g.crcErr),g.crcErr?"warn":""); set("rxModel",g.model?g.model+(g.rxFw?" · "+g.rxFw:""):"–"); - {const gt=g.temp!==undefined;for(const id of ["rxTempT","rxTemp"])$(id).classList.toggle("hidden",!gt);if(gt)set("rxTemp",g.temp+" °C"+(g.tempSt==="old"?" (old reading)":""));} /* its temperature when it reports it (UBX-MON-SYS) */ + {const gt=g.temp!==undefined;for(const id of ["rxTempT","rxTemp"])$(id).classList.toggle("hidden",!gt);if(gt)set("rxTemp",g.temp+" °C"+(g.tempSt==="old"?" (old reading)":""));} /* its temperature when it reports it (UBX-MON-SYS; a UM982: HWSTATUSA) */ const d=s.dual,f2=d.f9p2||null; // AiO_WEB: the dual heading comes from the UM982 (HPR) or from a second F9P on the GPS2 port (RELPOSNED) const f9=d.src==="f9p"||(!d.src&&!!f2&&f2.on); @@ -794,14 +794,14 @@ function fillUbx(u){ s.disabled=v[n]===undefined;} for(const n of UBX_CB){const c=f[n];c.checked=!!v[n];c.disabled=v[n]===undefined||((n==="gga"||n==="vtg")&&v[n]>0);} } -// a receiver's temperature row: a reading always shows (u-blox: UBX-MON-SYS, polled every 10 s); without one (an older u-blox -// firmware that never answers, one that answers 0, the UM982 that the firmware does not ask yet) it reads just "not reported" -function tempText(v,st,kind){if(v!==undefined)return v+" °C"+(st==="old"?" (old reading)":"");if(kind==="um982"||st==="zero"||st==="none")return NO_TEMP;if(st==="ask")return "asking…";return "–";} +// a receiver's temperature row: a reading always shows (u-blox: UBX-MON-SYS, UM982: HWSTATUSA, polled every 10 s); without one +// (a receiver firmware that never answers, or that answers with no temperature) it reads just "not reported" +function tempText(v,st){if(v!==undefined)return v+" °C"+(st==="old"?" (old reading)":"");if(st==="zero"||st==="none")return NO_TEMP;if(st==="ask")return "asking…";return "–";} function renderGps(j){ const k=j.kind,asking=j.id==="wait"||j.id==="ask"; set("gModel",j.model||(k==="um982"?"Unicore":asking&&j.talks?"asking…":"not identified"),j.model||k?"":"warn"); set("gKind",k==="ublox"?"u-blox":k==="um982"?"Unicore":"–"); - set("gFw",j.fw||"–");set("gProt",j.prot||"–");set("gTemp",tempText(j.temp,j.tempSt,k));$("gProtT").classList.toggle("hidden",k!=="ublox");$("gProt").classList.toggle("hidden",k!=="ublox"); /* u-blox only */ + set("gFw",j.fw||"–");set("gProt",j.prot||"–");set("gTemp",tempText(j.temp,j.tempSt));$("gProtT").classList.toggle("hidden",k!=="ublox");$("gProt").classList.toggle("hidden",k!=="ublox"); /* u-blox only */ const um=k==="um982"; /* NMEA version: UM982 only, from its CONFIG (zReceiver.ino) */ set("gNmea",um&&j.um&&j.um.nmea||"–");$("gNmeaT").classList.toggle("hidden",!um);$("gNmea").classList.toggle("hidden",!um); set("gId",!j.talks?"the receiver sends nothing":j.id==="done"?ago(j.idAgo):j.id==="none"?(j.hpr?"no answer (it sends HPR: Unicore)":"no answer"):"asking…",!j.talks||j.id==="none"?"warn":""); @@ -1019,7 +1019,7 @@ function renderCk(j){ const ublox=j.kind==="ublox",um=j.kind==="um982"; for(const port of [0,1]){ const p=c.ports[port],id="ck"+port; - if(port===1){$("ck1").classList.toggle("hidden",!p.on);if(!p.on)continue;set("ck1Model",p.model||"–");set("ck1Temp",tempText(p.temp,p.tempSt,"ublox"));} + if(port===1){$("ck1").classList.toggle("hidden",!p.on);if(!p.on)continue;set("ck1Model",p.model||"–");set("ck1Temp",tempText(p.temp,p.tempSt));} ckHealth(id+"Data",p); const fast=p.health==="ok"&&Math.abs(p.hz[0]-100)>5?"warn":""; if(port===0){const n=["GGA","VTG","HPR"].slice(0,um||p.hz[2]?3:2),hzs=n.map((x,i)=>p.hz[i]); diff --git a/Seeder/Seeder_ESP32/README.md b/Seeder/Seeder_ESP32/README.md index 4f2bf2e..429bc1b 100644 --- a/Seeder/Seeder_ESP32/README.md +++ b/Seeder/Seeder_ESP32/README.md @@ -10,7 +10,7 @@ by a 12 V DPDT relay. Two boards: - a **KinCony KC868-A32** (ESP32, 32 relays, network socket), each relay switching an external DPDT relay. -Version 0.2.6, made from [Sprayer_ESP32](../../Sprayer/Sprayer_ESP32) v0.8 when the seed drill +Version 0.2.7, made from [Sprayer_ESP32](../../Sprayer/Sprayer_ESP32) v0.8 when the seed drill got its own folder. Written from the Relay24_ESP32 design and KinCony's pin list: it has not run on either board yet. @@ -20,6 +20,7 @@ One row per day, in short; the details are in the sections of this file (the lin | Date | What changed | |---|---| +| 10 Nov 2026 | **0.2.7**: the tabs at the top of the page are 44 px high with 8 px corners, like the buttons of the page's question box: easier to hit on the cab's screen ([How it works](#how-it-works)). | | 9 Nov 2026 | **0.2.5**: *Sections on the seed drill* (Settings): the Sowing tab shows all before the program asks, relays past them idle. **0.2.6**: questions in the page's own box: the browser's pop-ups show nothing in an AgOpenWeb web card ([How it works](#how-it-works)). | | 7 Nov 2026 | **0.2.2**: add-on card (`_aowcard._tcp`) under its Wi-Fi name; `_aow-ui` and `/aow/status` gone. **0.2.3**: four tabs as the sprayer's ([How it works](#how-it-works)). **0.2.4**: Module tab: Module card, one Network settings card. Code shared with the sprayer marked ([Notes](#notes)). | | 2 Nov 2026 | **0.2.1**: the Wi-Fi settings on the page as on the XIAO page, with a search for networks ([Setup](#setup)). | @@ -66,7 +67,9 @@ Relay24_ESP32 (192.168.5.123) ──► DPDT relays 1–19 ──► 19 actuator in the [simulator](https://renatorgr.github.io/Boards/seeder/), rebuilt from this code on every change. Every question the page asks (save and restart, install a program, the password) opens in a box of the page itself, not a browser pop-up: inside an AgOpenWeb web - card the browser's pop-ups show nothing, so those buttons did nothing there. + card the browser's pop-ups show nothing, so those buttons did nothing there. The tabs at the + top are 44 px high, with the same 8 px corners as that box's buttons: a size a finger hits + on the cab's screen. ## Choosing the board @@ -121,7 +124,7 @@ The relays close when their PCF8574 pin is **LOW** (`RELAY_ON_HIGH 0`). 4. Relay24_ESP32: plug the DevKitC's USB socket into the computer (the board can be powered or not). KC868-A32: power it with 12 V and plug its USB socket in, as in KinCony's guide. *Tools → Port*: its COM port. Click *Upload*. -5. Serial Monitor at **115200**: it prints `Seeder_ESP32 v0.2.6` and `ready`. +5. Serial Monitor at **115200**: it prints `Seeder_ESP32 v0.2.7` and `ready`. Later program updates: *Sketch → Export compiled binary* in the Arduino IDE, then on the page's *Firmware* tab *Choose .bin* (`Seeder_ESP32.ino.bin` from this folder, not the diff --git a/Seeder/Seeder_ESP32/Seeder_ESP32.ino b/Seeder/Seeder_ESP32/Seeder_ESP32.ino index 53e64a4..8f4e5bf 100644 --- a/Seeder/Seeder_ESP32/Seeder_ESP32.ino +++ b/Seeder/Seeder_ESP32/Seeder_ESP32.ino @@ -9,7 +9,7 @@ Licence: GNU General Public License v3 or later (Firmware/v4.5_AiO_WEB/COPYING), WITHOUT ANY WARRANTY. SPDX-License-Identifier: GPL-3.0-or-later */ -// Seeder_ESP32.ino v0.2.6 (2026-11-09), not yet run on a board. +// Seeder_ESP32.ino v0.2.7 (2026-11-10), not yet run on a board. // // Boards (BOARD below): // - Relay24_ESP32 (folder Relay24_ESP32 of this repository): an ESP32 DevKitC V4 plugged into a board with @@ -62,7 +62,7 @@ #include "dPage.h" #define FW_NAME "Seeder_ESP32" -#define FW_VERSION "0.2.6" +#define FW_VERSION "0.2.7" // ---------------------------------------------------------------- board and pins // BOARD says which board this is (change the line below, or compile with -DBOARD=...): diff --git a/Seeder/Seeder_ESP32/Seeder_ESP32.ino.bin b/Seeder/Seeder_ESP32/Seeder_ESP32.ino.bin index da11aa8..4f5bc00 100644 Binary files a/Seeder/Seeder_ESP32/Seeder_ESP32.ino.bin and b/Seeder/Seeder_ESP32/Seeder_ESP32.ino.bin differ diff --git a/Seeder/Seeder_ESP32/Seeder_ESP32.ino.merged.bin b/Seeder/Seeder_ESP32/Seeder_ESP32.ino.merged.bin index a2b18af..08ffb39 100644 Binary files a/Seeder/Seeder_ESP32/Seeder_ESP32.ino.merged.bin and b/Seeder/Seeder_ESP32/Seeder_ESP32.ino.merged.bin differ diff --git a/Seeder/Seeder_ESP32/dPage.h b/Seeder/Seeder_ESP32/dPage.h index 01b1b79..9bf4fb3 100644 --- a/Seeder/Seeder_ESP32/dPage.h +++ b/Seeder/Seeder_ESP32/dPage.h @@ -30,8 +30,8 @@ header h1{font-size:16px;margin:0;font-weight:650;white-space:nowrap} header .sub{color:var(--mute);font-size:13px;flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis} .dot{width:11px;height:11px;border-radius:50%;background:var(--bad);flex:none} .dot.on{background:var(--ok)} -nav{display:flex;gap:6px;padding:8px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} -nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:999px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} +nav{display:flex;gap:6px;padding:4px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} +nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:8px;min-height:44px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} nav button.on{background:var(--acc);border-color:var(--acc);color:var(--accInk)} nav button.new::after{content:"";display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--ok);margin-left:6px;vertical-align:middle} nav button.on.new::after{background:var(--accInk)} diff --git a/Sprayer/Sprayer_ESP32/README.md b/Sprayer/Sprayer_ESP32/README.md index 2287efb..52a6713 100644 --- a/Sprayer/Sprayer_ESP32/README.md +++ b/Sprayer/Sprayer_ESP32/README.md @@ -4,7 +4,7 @@ Section control for an 8 m sprayer boom with 8 sections of 1 m, driven by **AgOp **AgOpenGPS** over Wi-Fi, on an **ESP32 8-relay board**. It also measures boom pressure and flow, and has its own web page. -Version 0.10.5 (successor of [Sprayer_Nano](../Sprayer_Nano) v0.3): runs on the bench, not yet +Version 0.10.6 (successor of [Sprayer_Nano](../Sprayer_Nano) v0.3): runs on the bench, not yet tested on the sprayer. ## Changelog @@ -13,6 +13,7 @@ One row per day, in short; the details are in the sections of this file (the lin | Date | What changed | |---|---| +| 10 Nov 2026 | **0.10.6**: the tabs at the top of the page are 44 px high with 8 px corners, like the buttons of the page's question box: easier to hit on the cab's screen ([How it works](#how-it-works)). | | 9 Nov 2026 | **0.10.5**: the page's questions (save and restart, install, password) in its own box: the browser's pop-ups show nothing inside an AgOpenWeb web card, so those buttons did nothing there ([How it works](#how-it-works)). | | 7 Nov 2026 | **0.10.2**: add-on card (`_aowcard._tcp`) under its Wi-Fi name; `_aow-ui` and `/aow/status` gone. **0.10.3**: alarms also as PGN 221 ([Messages](#messages)). **0.10.4**: Module tab: Module card, one Network settings card. Code shared with the seed drill marked ([Notes](#notes)). | | 2 Nov 2026 | **0.10**: rate (L/ha), target pressure and alarms worked out on the module and sent to the program (PGN 161); the page gets Spraying, [Settings](#setup), Module and Firmware tabs, with Install from GitHub. **0.10.1**: Wi-Fi settings as on the XIAO page. | @@ -80,7 +81,8 @@ ESP32_Relay_X8 board ──► 8 relays ──► 8 solenoid valves (NC), one pe A `.bin` for another board, another module's program or the `.merged.bin` is refused. Every question the page asks (save and restart, install a program, the password) opens in a box of the page itself, not a browser pop-up: inside an AgOpenWeb web card the browser's - pop-ups show nothing, so those buttons did nothing there. + pop-ups show nothing, so those buttons did nothing there. The tabs at the top are 44 px high, + with the same 8 px corners as that box's buttons: a size a finger hits on the cab's screen. Without the board, the page can be tried in the [simulator](https://renatorgr.github.io/Boards/sprayer/), rebuilt from this code on every change. @@ -148,7 +150,7 @@ divider (to-GND ÷ total) in the page's calibration. 4. *Tools → Port*: the adapter's COM port. 5. Hold **IO0**, press and release **EN**, release IO0. Click *Upload*. When it says "Hard resetting", press **EN** once. -6. Serial Monitor at **115200**: it prints `Sprayer_ESP32 v0.10.5` and `ready`. +6. Serial Monitor at **115200**: it prints `Sprayer_ESP32 v0.10.6` and `ready`. "Failed to connect": TX and RX are probably swapped, or step 5 was skipped. diff --git a/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino b/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino index cce88d6..3fba738 100644 --- a/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino +++ b/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino @@ -7,7 +7,7 @@ Licence: GNU General Public License v3 or later (file COPYING), WITHOUT ANY WARRANTY. SPDX-License-Identifier: GPL-3.0-or-later */ -// Sprayer_ESP32.ino v0.10.5 (2026-11-09), not yet tested on the sprayer. +// Sprayer_ESP32.ino v0.10.6 (2026-11-10), not yet tested on the sprayer. // // Board: "ESP32_Relay_X8" (303E32DC810): ESP32-WROOM-32E, 8 relays, 5-30 V DC in, LM2596 on board. // Or any ESP32 dev module with relay modules, up to 16 relays (BOARD_DEVKIT below). @@ -55,7 +55,7 @@ #include "sPage.h" #define FW_NAME "Sprayer_ESP32" -#define FW_VERSION "0.10.5" +#define FW_VERSION "0.10.6" // ---------------------------------------------------------------- board and pins // BOARD says which board this is (change the line below, or compile with -DBOARD=...): diff --git a/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.bin b/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.bin index c57f831..64c41c6 100644 Binary files a/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.bin and b/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.bin differ diff --git a/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.merged.bin b/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.merged.bin index 8a54409..c6494df 100644 Binary files a/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.merged.bin and b/Sprayer/Sprayer_ESP32/Sprayer_ESP32.ino.merged.bin differ diff --git a/Sprayer/Sprayer_ESP32/sPage.h b/Sprayer/Sprayer_ESP32/sPage.h index 7b9139d..e2ec365 100644 --- a/Sprayer/Sprayer_ESP32/sPage.h +++ b/Sprayer/Sprayer_ESP32/sPage.h @@ -30,8 +30,8 @@ header h1{font-size:16px;margin:0;font-weight:650;white-space:nowrap} header .sub{color:var(--mute);font-size:13px;flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis} .dot{width:11px;height:11px;border-radius:50%;background:var(--bad);flex:none} .dot.on{background:var(--ok)} -nav{display:flex;gap:6px;padding:8px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} -nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:999px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} +nav{display:flex;gap:6px;padding:4px 12px;overflow-x:auto;background:var(--card);border-bottom:1px solid var(--line)} +nav button{border:1px solid var(--line);background:var(--card);color:var(--ink);border-radius:8px;min-height:44px;padding:7px 14px;font:inherit;font-size:14px;cursor:pointer;white-space:nowrap} nav button.on{background:var(--acc);border-color:var(--acc);color:var(--accInk)} nav button.new::after{content:"";display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--ok);margin-left:6px;vertical-align:middle} nav button.on.new::after{background:var(--accInk)}