[Ovmsdev] ESP-IDF v4 / v5 - baby steps

Michael Balzer dexter at expeedo.de
Sun Feb 5 18:48:26 HKT 2023


Ludovic,

I'm having trouble getting the experimental-esp-idf-v5 branch to even 
configure.

Configuring and building the "hello_world" example with idf5.0 works 
without any issues, so it's related to our sources.

I've tried removing the build directory, doing "idf.py python-clean", 
doing "idf.py clean" "idf.py fullclean", but I always get this, already 
when doing set-target:

balzer at leela:~/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3> 
idf.py set-target esp32
Adding "set-target"'s dependency "fullclean" to list of commands with 
default set of options.
Executing action: fullclean
Build directory 
'/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/build' 
not found. Nothing to clean.
Executing action: set-target
Set Target to: esp32, new sdkconfig created. Existing sdkconfig renamed 
to sdkconfig.old.
Running cmake in directory 
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/build
Executing "cmake -G Ninja -DPYTHON_DEPS_CHECKED=1 -DESP_PLATFORM=1 
-DIDF_TARGET=esp32 -DCCACHE_ENABLE=0 
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3"...
CMake Warning (dev) at CMakeLists.txt:8 (message):
   WARNING - OVMSv3 build is only supported on ESP-IDF 3.3.x
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found Git: /usr/bin/git (found version "2.35.3")
-- The C compiler identification is GNU 11.2.0
-- The CXX compiler identification is GNU 11.2.0
-- The ASM compiler identification is GNU
-- Found assembler: 
/home/balzer/.espressif/tools/xtensa-esp32-elf/esp-2022r1-11.2.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: 
/home/balzer/.espressif/tools/xtensa-esp32-elf/esp-2022r1-11.2.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc 
- skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: 
/home/balzer/.espressif/tools/xtensa-esp32-elf/esp-2022r1-11.2.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-g++ 
- skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Building ESP-IDF components for target esp32
Processing 2 dependencies:
[1/2] espressif/mdns (1.0.7)
[2/2] idf (5.0.0)
-- Found BISON: /usr/bin/bison (found version "3.0.4")
-- Found FLEX: /usr/bin/flex (found version "2.6.4")
-- IDF Version: 5.0.0 - NOT enabling strverscmp
CMake Error at /home/balzer/esp/esp-idf/tools/cmake/component.cmake:224 
(message):
   CMake Warning (dev) at build_properties.temp.cmake:8:

     Syntax Warning in cmake code at column 51



     Argument not separated from preceding token by whitespace.

   Call Stack (most recent call first):

/home/balzer/esp/esp-idf/tools/cmake/scripts/component_get_requirements.cmake:3 
(include)

   This warning is for project developers.  Use -Wno-dev to suppress it.



   CMake Error: Error required internal CMake variable not set, cmake 
may not
   be built correctly.

   Missing variable is:

   CMAKE_FIND_LIBRARY_PREFIXES

   CMake Error: Error required internal CMake variable not set, cmake 
may not
   be built correctly.

   Missing variable is:

   CMAKE_FIND_LIBRARY_SUFFIXES

Call Stack (most recent call first):
   /home/balzer/esp/esp-idf/tools/cmake/build.cmake:553 
(__component_get_requirements)
   /home/balzer/esp/esp-idf/tools/cmake/project.cmake:440 
(idf_build_process)
   CMakeLists.txt:18 (project)


-- Configuring incomplete, errors occurred!
See also 
"/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/build/CMakeFiles/CMakeOutput.log".
cmake failed with exit code 1, output of the command is in the 
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/build/log/idf_py_stderr_output_8211 
and 
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/build/log/idf_py_stdout_output_8211



Any idea about this?

Regards,
Michael


Am 02.02.23 um 22:38 schrieb Ludovic LANGE:
> Hi list,
>
> I started to split my big list of patches into smaller, more 
> manageable, easier to review PRs:
>
>   * missing headers
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/825>
>     #825
>   * ESP-IDF v5+: dependency on ovms_webserver.h
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/824>
>     #824
>   * ESP-IDF v5+: change type of TaskHandle_t
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/823>#823
>   * changes to (long deprecated) ADC constants
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/822>
>     #822
>   * ESP-IDF v5+: static assertion failed: std::vector must have the
>     same value_type as its allocator
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/821>
>     #821
>   * ESP-IDF v5+: static assertion failed: comparison object must be
>     invocable as const
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/820>
>     #820
>   * ESP-IDF v4+ : remove deprecated and unused esp_event_loop.h
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/819>
>     #819
>   * remove warning by replacing rom/queue.h with sys/queue.h
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/818>
>     #818
>   * remove warning : '_GNU_SOURCE' redefined
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/817>
>     #817
>   * ESP-IDF v4+ : esp_intr.h is deprecated, replaced by
>     esp_intr_alloc.h
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/816>
>     #816
>   * Add header and fix function signature
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/815>
>     #815
>   * replace some constants with their more adapted counterpart
>     <https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/813>
>     #813
>
> Let me know if it's the proper approach ; and if some of you can 
> review those changes and comment on them, it'll help merging those - 
> and progress in reaching ESP-IDFv5 compatibility.
>
> Best regards,
>
> Le 31/01/2023 à 01:49, Ludovic LANGE a écrit :
>> Hi list,
>>
>> Another quick post to share with you the progress on the ESP-IDFv5 + 
>> cmake endeavour:
>>
>>   * ESP-IDF v5 version of OVMSv3 is now officially booting and seems
>>     to work fine (then again, I'm not doing any real-world testing
>>     for lack of time / car at the moment - it's here that you can
>>     help me) with a few caveats detailed in the PR or the README.md
>>     <https://github.com/llange/Open-Vehicle-Monitoring-System-3/blob/experimental-esp-idf-v5/README.md>.
>>
>>   * The branch
>>     https://github.com/llange/Open-Vehicle-Monitoring-System-3/tree/experimental-esp-idf-v5
>>     is now ready for testing, sharing, studying, ...
>>
>>   * I created a draft PR
>>     https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/pull/810
>>     (just like for ESP-IDFv4), in order to show the diff and gather
>>     feedback. Not to be merged as-is.
>>
>>   * I'll try to break it into smaller low-impact / easy-to-review
>>     PR's that could be merged as-is in current master (warning
>>     corrections, header definitions, xxprintf type impact, etc...),
>>     so that the big pieces could be more easily reviewed.
>>
>>
>> Please note that those branches / PRs are still Work-In-Progress, and 
>> that I may certainly (and wrongly) `push --force` some changes as I 
>> rebase, update or split the big PR into smaller, easy to study PRs. 
>> I'll try not to but can't promise :-)
>> So if you checkout the branch, please be warned and know your git 
>> commands to either reset or rebase your working copy...
>>
>> Next on my list are, in no particular order:
>>
>>   * Have a few patches/bugs fixed in upstream wolfSSL (in progress)
>>     in order to enable
>>   * Check to see if we could upgrade mongoose (not absolutely
>>     necessary because it works / compile OK with a small patch)
>>   * Fix the remaining warnings
>>       o And change the ADC implementation that is deprecated now
>>       o deprecation of esp_vfs_fat_spiflash_mount /
>>         esp_vfs_fat_spiflash_unmount
>>   * Fix the WIP WIP WIP commits
>>   * Resume work on
>>     https://github.com/openvehicles/Open-Vehicle-Monitoring-System-3/issues/752
>>
>>
>> Boot time warnings to study and check if OK:
>>
>>   * W (1091) esp_psram: Virtual address not enough for PSRAM, map as
>>     much as we can. 4MB is mapped
>>   * W (2132) ADC: legacy driver is deprecated, please migrate to
>>     `esp_adc/adc_oneshot.h`   (<- this one is easy to understand...)
>>
>>
>> Additional instructions:
>>
>> When first building, your sdkconfig will be converted as some config 
>> options did change betwen ESP-IDF v3.x and v5.x.
>>
>> Run `menuconfig` and :
>>
>>   * *Select FREERTOS_ENABLE_BACKWARD_COMPATIBILITY*(=y)
>>     "configENABLE_BACKWARD_COMPATIBILITY"
>>   * *Unselect MG_ENABLE_SSL*(=n) "Enable MONGOOSE SSL/TLS support"
>>
>>
>> If any of you with some free time could be nice enough to try to 
>> reproduce such a build and share the experience here. Let me know how 
>> the instructions could be updated and what issues you are facing.
>>
>>
>> Best regards,
>
>
> _______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.openvehicles.com
> http://lists.openvehicles.com/mailman/listinfo/ovmsdev

-- 
Michael Balzer * Helkenberger Weg 9 * D-58256 Ennepetal
Fon 02333 / 833 5735 * Handy 0176 / 206 989 26

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20230205/a729e219/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 203 bytes
Desc: OpenPGP digital signature
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20230205/a729e219/attachment-0001.sig>


More information about the OvmsDev mailing list