Host DFU (ESP32) failing with written length mismatch — worked previously on the same card

Has anyone run into this?

Host DFU on a NOTE-NBGLWX with a Starnote starts the download, fails about a second in, and reports written length mismatch to Notehub. Around 15 consecutive attempts, all the same.

The part I can’t explain is that it worked on this same card and board a few days ago — a 739 KB host image on 31 August, and a 934 KB Notecard firmware update on 7 August. Nothing changed on our side between those and the failures.

What I’ve ruled out so far:

  • Payload size — fails identically at 30 KB and at 745 KB
  • Payload content — fails for two unrelated image types
  • Link — fails on Wi-Fi at −45 dBm and on cellular
  • Supply — voltage is stable under load
  • Card statecard.restart and several card.dfu configurations make no difference

Card firmware is 11.3.1.17696. As far as I can tell this fails while the card is fetching the image, before my host reads any chunks — I’m at 512-byte dfu.get chunks, so this isn’t the chunk-size timing issue, though do correct me if I’ve misread where it’s failing.

I found Intermittent host ODFU failure: cannot allocate 8192 bytes {memory}, though that’s outboard DFU and we’re pulling the image with dfu.get instead. Is written length mismatch coming from the same place, or is it a separate path? And is there anything useful I should be capturing while it’s in this state?