mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
cmake: Add new flasher_args.json file for IDE parsing, document metadata files better
This commit is contained in:
parent
2a3e2b8eed
commit
f1d3bfc0c7
@ -7,3 +7,8 @@ foreach(part project app bootloader)
|
|||||||
"${CMAKE_BINARY_DIR}/flash_${part}_args"
|
"${CMAKE_BINARY_DIR}/flash_${part}_args"
|
||||||
)
|
)
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
|
configure_file(
|
||||||
|
"${CMAKE_CURRENT_LIST_DIR}/flasher_args.json.in"
|
||||||
|
"${CMAKE_BINARY_DIR}/flasher_args.json"
|
||||||
|
)
|
||||||
|
11
components/esptool_py/flasher_args.json.in
Normal file
11
components/esptool_py/flasher_args.json.in
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
{
|
||||||
|
"write_flash_args" : [ "--flash_mode", "${ESPFLASHMODE}",
|
||||||
|
"--flash_size", "${ESPFLASHSIZE}",
|
||||||
|
"--flash_freq", "${ESPFLASHFREQ}" ],
|
||||||
|
"flash_files" : {
|
||||||
|
"0x1000" : "bootloader/bootloader.bin",
|
||||||
|
"0x8000" : "partition_table/partition-table.bin",
|
||||||
|
"${CONFIG_APP_OFFSET}" : "${PROJECT_NAME}.bin",
|
||||||
|
"${PHY_PARTITION_OFFSET}" : "${PHY_PARTITION_BIN_FILE}"
|
||||||
|
}
|
||||||
|
}
|
@ -638,7 +638,7 @@ You can pass any of these flasher argument files to ``esptool.py`` as follows::
|
|||||||
|
|
||||||
Alternatively, it is possible to manually copy the parameters from the argument file and pass them on the command line.
|
Alternatively, it is possible to manually copy the parameters from the argument file and pass them on the command line.
|
||||||
|
|
||||||
The build directory also contains a generated file ``project_description.json`` which contains project information, including project flash information, in the JSON format. This file is used by ``idf.py`` and can also be used by other tools which need information about the project build.
|
The build directory also contains a generated file ``flasher_args.json`` which contains project flash information, in JSON format. This file is used by ``idf.py`` and can also be used by other tools which need information about the project build.
|
||||||
|
|
||||||
Building the Bootloader
|
Building the Bootloader
|
||||||
=======================
|
=======================
|
||||||
@ -727,6 +727,14 @@ The following variables no longer have default values:
|
|||||||
|
|
||||||
It is no longer necessary to set ``COMPONENT_SRCDIRS`` if setting ``COMPONENT_SRCS`` (in fact, ``COMPONENT_SRCDIRS`` is ignored if ``COMPONENT_SRCS`` is set).
|
It is no longer necessary to set ``COMPONENT_SRCDIRS`` if setting ``COMPONENT_SRCS`` (in fact, ``COMPONENT_SRCDIRS`` is ignored if ``COMPONENT_SRCS`` is set).
|
||||||
|
|
||||||
|
Build System Metadata
|
||||||
|
=====================
|
||||||
|
|
||||||
|
For integration into IDEs and other build systems, when cmake runs the build process generates a number of metadata files in the ``build/`` directory. To regenerate these files, run ``cmake`` or ``idf.py reconfigure`` (or any other ``idf.py`` build command).
|
||||||
|
|
||||||
|
- ``project_description.json`` contains some general information about the project, configured paths, etc.
|
||||||
|
- ``flasher_args.json`` contains esptool.py arguments to flash the project's binary files. There are also ``flash_*_args`` files which can be used directly with esptool.py. See `Flash arguments`.
|
||||||
|
- ``CMakeCache.txt`` is the CMake cache file which contains other information about the CMake process, toolchain, etc.
|
||||||
|
|
||||||
.. _esp-idf-template: https://github.com/espressif/esp-idf-template
|
.. _esp-idf-template: https://github.com/espressif/esp-idf-template
|
||||||
.. _cmake: https://cmake.org
|
.. _cmake: https://cmake.org
|
||||||
|
@ -6,12 +6,6 @@
|
|||||||
"app_elf": "${PROJECT_NAME}.elf",
|
"app_elf": "${PROJECT_NAME}.elf",
|
||||||
"app_bin": "${PROJECT_NAME}.bin",
|
"app_bin": "${PROJECT_NAME}.bin",
|
||||||
"git_revision": "${IDF_VER}",
|
"git_revision": "${IDF_VER}",
|
||||||
"project_binaries": {
|
|
||||||
"bootloader": [ "0x1000", "bootloader/bootloader.bin" ],
|
|
||||||
"partition_table": [ "0x8000", "partition_table/partition-table.bin" ],
|
|
||||||
"app": [ "${CONFIG_APP_OFFSET}", "${PROJECT_NAME}.bin" ],
|
|
||||||
"phy_data": [ "${PHY_PARTITION_OFFSET}", "${PHY_PARTITION_BIN_FILE}" ]
|
|
||||||
},
|
|
||||||
"phy_data_partition": "${CONFIG_ESP32_PHY_INIT_DATA_IN_PARTITION}",
|
"phy_data_partition": "${CONFIG_ESP32_PHY_INIT_DATA_IN_PARTITION}",
|
||||||
"monitor_baud" : "${CONFIG_MONITOR_BAUD}"
|
"monitor_baud" : "${CONFIG_MONITOR_BAUD}"
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user