Skip to content

OpenCarMind EdgeOS 2.1.0 for ESP-Mosaico (ESP32-S31)

Latest

Choose a tag to compare

@AlveeeRahman AlveeeRahman released this 13 Nov 00:09
1053f9d

Updated 13 November 2026: fixed build

The images on this release were replaced on 13 November 2026 with a fixed build from main (bcd05ad). The version name stays OpenCarMind EdgeOS 2.1.0. The release tag still points to 1053f9d, the commit of the first build, and the source of the fixed build is main at bcd05ad. If you downloaded it before, check your file against the checksums below and replace the first build.

Fixed

  • Restart loop in the car. Once a drive had saved its driving-pattern file, every start crashed about 14 seconds later with a stack overflow in the task that talks to the car, and safe mode did not stop it. The pattern file is now read without the large copy, that task needs about half the stack it did, and safe mode turns the pattern code off. Each start also writes one line to obd/resets.csv: the reset reason, how long the board ran, the task that crashed, and the battery voltage, temperature and current.
  • Stopping a drive. Hold End drive for 1 second, or use Settings > LOGGING AND POWER > Stop logging. The board stops the car link, saves and closes the drive files, pauses the battery log and waits until the storage is quiet, then shows "Safe to unplug". It takes 35 seconds at most. If something blocks it, it says "Not safe to unplug yet" with the reason and a Try again button. Logging stays off until you tap Start logging or restart the board. The hold now also works when you lift your finger after 1 second or move it slightly.
  • Turn off. Settings > LOGGING AND POWER > Turn off stops logging the same way, stops the adapter search and darkens the screen once it is safe to unplug. A tap wakes it. The board's POWER button still switches the power, but the firmware cannot see it, so use Turn off first.

Checked on the board. A bench build with a simulated car reproduced the restart loop with the board's own pattern file (5 crashes in a row), and the fixed firmware loaded the same file with no crash. A 13.5-minute simulated drive ran with no crash and 2,836 bytes of the car task's stack never used. Every stop test reached "Safe to unplug" in 1.0 to 1.6 seconds, also while the car kept answering, and no new drive started after it. The fixed release firmware runs on the board with boot health good. Still to check in a real car: a long drive, stopping with your own adapter, and Turn off.

For the Espressif ESP-Mosaico (ESP32-S31) only. For the Waveshare ESP32-S3 car board, keep using the OpenCarMind 2.5.1 release. Do not flash this image on an S3.

OpenCarMind EdgeOS 2.1.0 is the next version of the ESP-Mosaico firmware. It keeps everything in OpenCarMind EdgeOS 2.0.0 and adds three AI services and a Health app. It is not related to Ubiquiti's EdgeOS router software.

Items marked "built, being checked on the board" passed their tests on a computer and run on the board, but have not shown their real result there yet.

The first build of 12 November was built from main (1053f9d). The board checks below ran on build 81017a5, which differs from this image only by one icon table's linkage (a code-scanning fix) and the build stamp. The ESP32-S3 firmware is unchanged.

What is new

Health app

  • A new app right after Board, with three pages you pick with the tabs under the title: Battery, Guard and AI.
  • Each page opens with one status card in plain words: a colour, an icon and a word (Good, Learning, Check soon, Act now), a headline, what it means and what to do. For example "Battery is wearing out", "Holds 76 % of its rated charge, runs shorter on battery", "Plan to replace the cell".
  • The header counts what needs you: "All good", "1 thing to check", "2 things to check". It is amber or red by the worst one.
  • Recent issues: the last five of each page with their time, newest first, and when each one ended.
  • When a battery wear, a battery alarm, a guard block or an adapter question starts, the banner shows "Check soon" or "Act now", the headline and Open Health. A tap opens the right page, a swipe closes it. While you drive, amber issues only go into the list and red ones show for 10 seconds.
  • The Health icon on Home gets an amber or red dot while an issue is active.
  • The details stay below the card for checks: charge, current, power and temperature, the health estimate, the resistance, the anomaly check and its score, the guard's counts, score bars and log, and each AI feature's runs, late runs, worst time against its deadline and work per run against its budget.
  • Read-only. The only button is Clear block.

Battery health from your own charges (built, being checked on the board)

  • A small model estimates the battery's health from the shape of a charge: how much charge goes in between 3.9 V and 4.1 V, where the charge curve has its steepest part, how long the last part of the charge takes and how fast its current falls, the resistance after a load starts, and the temperature.
  • It learns your cell from its first 10 deep charges and keeps that in the board's memory. A deep charge starts below about 3.6 V and ends full. Until then Health says "learning (n of 10 charges)".
  • When a charge from nearly empty to full has been counted, that count is used instead, because it is more exact.
  • The model was trained on lab cells, not on this one. Read its figure as a trend for your cell, not as an exact value.

Battery anomaly detector (built, being checked on the board)

  • Looks at the battery once a minute: the voltage against what the estimator expects, the drift at rest, the current at rest, the heating, the resistance, the load and read glitches.
  • Learns your cell's normal for 24 hours first. The learning is kept, so a restart does not start it again.
  • Only a small autoencoder can raise the alarm. On the test data it gave about one false alarm in 400 hours. Two simpler scores are logged for checks only.
  • An alarm writes a message, and Health names what looks unusual in plain words: it warms up more than usual, loses charge while resting, its current reading looks wrong, its voltage drops more under load, the board draws more power than usual, the connection glitches, or the charge reading drifts. It never switches anything off.

Network guard (built, being checked on the board)

  • Watches what the board's radios already receive: the Bluetooth adverts during a scan, the car link's response times and what a Wi-Fi round sees. The radio code only counts. No address or network name is kept or logged.
  • Learns for two hours after every start and blocks nothing in that time.
  • After that it blocks advert floods and address rotation attacks, Wi-Fi beacon floods and Wi-Fi deauth bursts.
  • A block stops new adapter offers and re-pair requests, listens only to your paired adapter, stops a Wi-Fi round before it sets the clock and keeps the clock, and keeps rows out of the learning.
  • A block never cuts your car link, never sends anything, never pairs and never changes the clock. It lifts 10 minutes after the last suspicious window, or at once with Clear block.
  • A car link that answers much slower than usual gives a note and keeps those rows out of the learning. It never blocks.
  • Settings > Network guard: blocking on or off. On by default. Off means it only logs.

AI services

  • All AI services share one worker below the screen and the models and are admitted by response-time analysis, as in 2.0.0.
  • The admission self-test now runs five times and the fastest run decides, with one more try 30 s later. On one boot of seven in the 2.0.x board check, a single slow run had refused the battery estimator for the whole boot.
  • When deadlines are missed the AI services slow down first. The network guard then checks every fourth window.

Fixes

  • The network guard no longer scores the first Wi-Fi scan after a start. It had nothing to compare with, so every network looked new (290 of 256 right after boot).
  • Health no longer compares a response time with a CPU budget. The AI card says "on time" against the deadline, and the details say "worst time 12.9 ms (limit 1,000 ms)" and "work per run 0.23 ms (budget 2 ms)".
  • The battery current at rest reads "resting, 0 mA" instead of "+0 mA charging". It reads "charging +n mA" or "on battery -n mA" otherwise.
  • The degradation ladder's message fits the event log (it was cut at 55 characters).
  • "CHARGE n mA" on Home and the AI card on Board fit their boxes.

Checked on the board

Build 81017a5 (Health in plain words), flashed through the 1200-baud door with no buttons, every time.

  • Health on the board: the real states (battery learning, guard learning this place, AI on time), and on a debug build that puts a state into the Health view only (never into the battery gauge or the settings): battery good, worn, three anomaly reasons, guard watching, blocking and adapter mismatch, AI slowed, in both themes. The banner's Open Health opened the right page, and a swipe closed it.
  • The first Wi-Fi scan after a start was not scored (16 networks seen, 0 scans scored, Guard shows "no data").
  • A 10-minute soak: boot health good at 68.8 s, the AI services admitted on core 1 (5.00 ms against 1,000 ms), no restart, no USB drop, no missed screen frame deadline, and no missed AI deadline in 1,181 AI runs. The 1200-baud door worked from the new build.
  • Internal RAM stayed above 60 KB. The lowest was 78,003 B, during a Wi-Fi round with the Health app open.

Build 73db232, flashed through the 1200-baud door with no buttons, every time.

  • Boot health good at 68.8 s. All three AI services admitted on core 1: worst-case response 5.00 ms against a 1,000 ms deadline. Self-tests (the fastest of five runs) 229 µs, 19 µs and 58 µs. The first run of each was 2 to 7 times slower, which is why the fastest run now decides.
  • A 10-minute soak: no restart, no USB drop, no missed screen frame deadline, no missed scheduler deadline, and no missed AI deadline in 1,181 AI runs.
  • Internal RAM stayed above 60 KB in every phase. The lowest was 78,227 B during a Wi-Fi round with the Health app open.
  • The network guard ran in its shadow with low scores (0 to 34 of 256 on the Bluetooth scan), blocked nothing and asked nothing. No pairing prompt for the neighbour's weak adapter.
  • The Wi-Fi clock sync was accepted as normal.
  • The Health app's three pages, in the dark and the light theme.
  • The battery anomaly detector started its 24-hour warm-up.

Not checked on the board yet

Pairing with your own adapter, a real drive, the battery on its own (unplugged), the network guard in a busy car park, the battery health model (it needs 10 deep charges), and the anomaly detector after its 24-hour warm-up.

Flash it

You need esptool 5.6.0 or later and pyserial. No buttons are needed.

  1. Plug the board in. Open its USB port at 1200 baud and close it again: python -c "import serial; serial.Serial('/dev/cu.usbmodemXXXX', 1200).close()"
  2. A new port appears (the ROM's). Write the image to it:
    esptool --chip esp32s31 --port <ROM port> --before no-reset --after hard-reset write-flash --flash-mode dio --flash-freq 80m --flash-size 16MB 0x0 OpenCarMind-EdgeOS-2.1.0-ESP-Mosaico-ESP32-S31-merged.bin
  3. The board restarts into OpenCarMind EdgeOS 2.1.0. Pair it again from the desktop app.

The merged image erases the NVS partition: the pairing with the desktop app, the saved Wi-Fi networks and the settings go. The drive logs on the NAND are not touched. To keep them, write only the app parts (bootloader at 0x2000, partition table at 0x8000, otadata at 0xf000, the app at 0x20000). Your settings move to the new format by themselves. Going back to 2.0.0 after that resets the settings to their defaults. Check the download against SHA256SUMS.

User manual: docs/manual/edgeos-2.1.0.md. Full guide: docs/MOSAICO.md.