<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">I’ve added a ‘network status’ command. Can you try it, when you get DNS errors, to see what the DNS servers are set to?<div class=""><br class=""></div><div class="">Regards, Mark</div><div class=""><br class=""></div><div class=""><div><blockquote type="cite" class=""><div class="">On 12 Mar 2018, at 10:29 AM, Mark Webb-Johnson <<a href="mailto:mark@webb-johnson.net" class="">mark@webb-johnson.net</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><blockquote type="cite" class="">Working on the OTA web UI.</blockquote><div class=""><br class=""></div>That will be very useful. Thanks.<div class=""><br class=""></div><div class=""><blockquote type="cite" class="">a) Flashing and changing the boot partition outputs some irritating overflow and "??" log messages:</blockquote></div><div class=""><blockquote type="cite" class="">Can these safely be ignored? The flashed partitions seem to work correctly.</blockquote><div class=""><br class=""></div><div class="">Yes, I too find these ugly. It is a ‘make monitor weirdism:</div><div class=""><br class=""></div></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><div class=""><a href="https://www.esp32.com/viewtopic.php?t=4199" class="">https://www.esp32.com/viewtopic.php?t=4199</a></div></div><div class=""><br class=""></div><div class=""><i class="">No, no need to worry. Those are from the ``make monitor`` command. As soon as this sees a hex number scroll by that smells like an address in the ESP32 memory map, it tries to be helpful and converts it to a symbol. In some cases, this leads it to weird messages like this.</i></div></blockquote><div class=""><br class=""></div><div class=""><blockquote type="cite" class="">b) How do you get back to the factory partition if something went so wrong you can't use the "ota" command?<br class=""></blockquote></div><div class=""><br class=""></div><div class="">Supposedly if the OTA partition doesn’t boot (or checksum mismatch, etc), the bootloader will boot factory.</div><div class=""><br class=""></div><div class="">The selection of current boot partition is in the otadata partition:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class=""># OVMS 16MB flash ESP32 Partition Table</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class=""># Name,   Type, SubType, Offset,   Size</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">nvs,      data, nvs,     0x9000,  0x4000</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">otadata,  data, ota,     0xd000,  0x2000</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">phy_init, data, phy,     0xf000,  0x1000</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">factory,  app,  factory, 0x10000,  4M</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">ota_0,    app,  ota_0,   ,         4M</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">ota_1,    app,  ota_1,   ,         4M</span></font></div><div class=""><font face="Andale Mono" class=""><span style="font-size: 18px;" class="">store,    data, fat,     ,         1M</span></font></div></div></blockquote><div class=""><br class=""></div><div class="">I guess zapping that would reset to defaults (factory boot)? I think erase_region may do that:</div><div class=""><br class=""></div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;" class=""><div class=""><pre style="box-sizing: border-box; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace; font-size: 13.600000381469727px; margin-top: 0px; margin-bottom: 16px; word-wrap: normal; padding: 16px; overflow: auto; line-height: 1.45; background-color: rgb(246, 248, 250); border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; color: rgb(36, 41, 46);" class=""><code style="box-sizing: border-box; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace; padding: 0px; margin: 0px; background-color: transparent; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; word-break: normal; border: 0px; display: inline; overflow: visible; line-height: inherit; word-wrap: normal;" class="">esptool.py erase_region 0xd000 0x2000</code></pre></div></blockquote><div class=""><br class=""></div><div class="">But, haven’t tried it myself.</div><div class=""><br class=""><div class=""><blockquote type="cite" class="">c) ota flash http still gives me a DNS lookup error on any other host than <a href="http://api.openvehicles.com/" class="">api.openvehicles.com</a> and fails to download from <a href="http://api.openvehicles.com" class="">api.openvehicles.com</a>, regardless of<br class="">the type of network (wifi/modem).</blockquote></div><div class=""><br class=""></div><div class="">I saw this a few months ago, but not recently.</div><div class=""><br class=""></div><div class="">Line 107 of ovms_net.cpp. It just does a getaddrinfo() on the host.</div><div class=""><br class=""></div><div class="">Regards, Mark.</div><div class=""><br class=""><blockquote type="cite" class=""><div class="">On 12 Mar 2018, at 7:13 AM, Michael Balzer <<a href="mailto:dexter@expeedo.de" class="">dexter@expeedo.de</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Working on the OTA web UI.<br class=""><br class="">Some questions:<br class=""><br class="">a) Flashing and changing the boot partition outputs some irritating overflow and "??" log messages:<br class=""><br class="">OVMS > ota flash vfs /sd/ovms3.done<br class="">Current running partition is: ota_0<br class="">Target partition is: ota_1<br class="">Source image is 1480592 bytes in size<br class="">Preparing flash partition...<br class="">Flashing image partition...<br class="">Setting boot partition...<br class="">OTA flash was successful<br class="">  Flashed 1480592 bytes from /sd/ovms3.done<br class="">  Next boot will be from 'ota_1'<br class="">I (1316956) esp_image: segment 0: paddr=0x00810020 vaddr=0x3f400020 size=0x5879c (362396) map<br class="">I (1317156) esp_image: segment 1: paddr=0x008687c4 vaddr=0x3ffb0000 size=0x0382c ( 14380)<br class="">I (1317156) esp_image: segment 2: paddr=0x0086bff8 vaddr=0x40080000 size=0x00400 (  1024)<br class="">0x40080000: _WindowOverflow4 at /home/balzer/esp/esp-idf/components/freertos/./xtensa_vectors.S:1685<br class=""><br class="">I (1317166) esp_image: segment 3: paddr=0x0086c400 vaddr=0x40080400 size=0x03c10 ( 15376)<br class="">I (1317176) esp_image: segment 4: paddr=0x00870018 vaddr=0x400d0018 size=0xfb154 (1028436) map<br class="">0x400d0018: _flash_cache_start at ??:?<br class=""><br class="">I (1317746) esp_image: segment 5: paddr=0x0096b174 vaddr=0x40084010 size=0x0e5b4 ( 58804)<br class="">0x40084010: spi_flash_mmap at /home/balzer/esp/esp-idf/components/spi_flash/./flash_mmap.c:293<br class=""><br class="">I (1317776) esp_image: segment 6: paddr=0x00979730 vaddr=0x400c0000 size=0x00034 (    52)<br class="">I (1317776) esp_image: segment 0: paddr=0x00810020 vaddr=0x3f400020 size=0x5879c (362396) map<br class="">I (1317976) esp_image: segment 1: paddr=0x008687c4 vaddr=0x3ffb0000 size=0x0382c ( 14380)<br class="">I (1317986) esp_image: segment 2: paddr=0x0086bff8 vaddr=0x40080000 size=0x00400 (  1024)<br class="">0x40080000: _WindowOverflow4 at /home/balzer/esp/esp-idf/components/freertos/./xtensa_vectors.S:1685<br class=""><br class="">I (1317986) esp_image: segment 3: paddr=0x0086c400 vaddr=0x40080400 size=0x03c10 ( 15376)<br class="">I (1317996) esp_image: segment 4: paddr=0x00870018 vaddr=0x400d0018 size=0xfb154 (1028436) map<br class="">0x400d0018: _flash_cache_start at ??:?<br class=""><br class="">I (1318566) esp_image: segment 5: paddr=0x0096b174 vaddr=0x40084010 size=0x0e5b4 ( 58804)<br class="">0x40084010: spi_flash_mmap at /home/balzer/esp/esp-idf/components/spi_flash/./flash_mmap.c:293<br class=""><br class="">I (1318606) esp_image: segment 6: paddr=0x00979730 vaddr=0x400c0000 size=0x00034 (    52)<br class=""><br class="">…<br class=""><br class="">OVMS > ota boot ota_1<br class="">Boot from ota_1 at 0x00810000 (size 0x00400000)<br class="">I (301766) esp_image: segment 0: paddr=0x00810020 vaddr=0x3f400020 size=0x5879c (362396) map<br class="">I (301966) esp_image: segment 1: paddr=0x008687c4 vaddr=0x3ffb0000 size=0x0382c ( 14380)<br class="">I (301976) esp_image: segment 2: paddr=0x0086bff8 vaddr=0x40080000 size=0x00400 (  1024)<br class="">0x40080000: _WindowOverflow4 at /home/balzer/esp/esp-idf/components/freertos/./xtensa_vectors.S:1685<br class=""><br class="">I (301976) esp_image: segment 3: paddr=0x0086c400 vaddr=0x40080400 size=0x03c10 ( 15376)<br class="">I (301986) esp_image: segment 4: paddr=0x00870018 vaddr=0x400d0018 size=0xfb154 (1028436) map<br class="">0x400d0018: _flash_cache_start at ??:?<br class=""><br class="">I (302556) esp_image: segment 5: paddr=0x0096b174 vaddr=0x40084010 size=0x0e5b4 ( 58804)<br class="">0x40084010: spi_flash_mmap at /home/balzer/esp/esp-idf/components/spi_flash/./flash_mmap.c:293<br class=""><br class="">I (302596) esp_image: segment 6: paddr=0x00979730 vaddr=0x400c0000 size=0x00034 (    52)<br class=""><br class=""><br class="">Can these safely be ignored? The flashed partitions seem to work correctly.<br class=""><br class=""><br class="">b) How do you get back to the factory partition if something went so wrong you can't use the "ota" command?<br class=""><br class="">I would have expected "make flash" to reset the boot partition to "factory", as all flashes are only done there, but it doesn't.<br class=""><br class="">So if you're on another partition with a broken firmware, how do you recover? Is there a way to set the boot partition using esptool.py?<br class=""><br class=""><br class="">c) ota flash http still gives me a DNS lookup error on any other host than <a href="http://api.openvehicles.com/" class="">api.openvehicles.com</a> and fails to download from <a href="http://api.openvehicles.com/" class="">api.openvehicles.com</a>, regardless of<br class="">the type of network (wifi/modem).<br class=""><br class="">OVMS > ota flash http <a href="http://www.google.com/ovms3.bin" class="">www.google.com/ovms3.bin</a><br class="">Current running partition is: factory<br class="">Target partition is: ota_0<br class="">Download firmware from <a href="http://www.google.com/ovms3.bin" class="">www.google.com/ovms3.bin</a> to ota_0<br class="">Error: Request failed<br class="">W (666891) net: DNS lookup on <a href="http://www.google.com/" class="">www.google.com</a> failed err=200<br class=""><br class="">OVMS > ota flash http <a href="http://api.openvehicles.com/test.bin" class="">api.openvehicles.com/test.bin</a><br class="">Current running partition is: factory<br class="">Target partition is: ota_0<br class="">Download firmware from <a href="http://api.openvehicles.com/test.bin" class="">api.openvehicles.com/test.bin</a> to ota_0<br class="">[…dead, needs reset]<br class=""><br class="">Is this a local problem of mine?<br class=""><br class=""><br class="">Regards,<br class="">Michael<br class=""><br class="">-- <br class="">Michael Balzer * Helkenberger Weg 9 * D-58256 Ennepetal<br class="">Fon 02333 / 833 5735 * Handy 0176 / 206 989 26<br class=""><br class=""><br class="">_______________________________________________<br class="">OvmsDev mailing list<br class=""><a href="mailto:OvmsDev@lists.teslaclub.hk" class="">OvmsDev@lists.teslaclub.hk</a><br class=""><a href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" class="">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br class=""></div></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></div></body></html>