Commit Graph

71 Commits

Author SHA1 Message Date
Ivan Grokhotkov
e70d534566 tools/idf.py: promote esp32c3 from preview to supported target 2021-01-28 11:12:56 +01:00
Fu Hanxi
0146f258d7 style: format python files with isort and double-quote-string-fixer 2021-01-26 10:49:01 +08:00
Ivan Grokhotkov
bac77b4bf7 Merge branch 'feature/idf-list-ports' into 'master'
idf.py: Use function for port detection from esptool.py in idf.py and idf_monitor.py

Closes IDFGH-3104

See merge request espressif/esp-idf!11359
2021-01-08 21:36:08 +08:00
Angus Gratton
60ec13b122 Merge branch 'feature/make_uf2' into 'master'
tools: Wrap flash binaries into a UF2 file for flashing through USB MSC

See merge request espressif/esp-idf!11587
2021-01-05 07:17:27 +08:00
martin.gano
f83039a0cb Imporove port detection in idf.py
Closes https://github.com/espressif/esp-idf/issues/5125
2020-12-31 14:25:52 +01:00
Marius Vikhammer
7fe16bae25 tools: merge C3 changes into master 2020-12-30 07:04:12 +08:00
Roland Dobai
548ea1bdd5 tools: Wrap flash binaries into a UF2 file for flashing through USB MSC
@mmoskal This commit adds basic support for UF2 into ESP-IDF.
2020-12-29 18:14:47 +01:00
Ivan Grokhotkov
8f3a3181e6 tools: decode esp32c3 stack dumps in idf_monitor.py
This follows a similar approach as UART core dump handling in
idf_monitor. Panic handler message is detected in the output,
collected into a file, and the file is passed to the decoding script.
In this case, the decoding script acts as a tiny GDB server, so we
can ask GDB to perform the backtrace.
2020-12-22 20:02:48 +11:00
Jakob Hasse
52093fa4ef linux: added linux target
* add toolchain file
* add linux to preview targets
* add stub for dfu number in cmake
* excluded unity runner per default
* Added esp_attr.h and esp_partition.h linux stubs
* component.cmake check list for emptyness
* added switch for linux in unity cmake file
* Added Linux host example app
2020-12-14 18:53:14 +08:00
martin.gano
346b002d9a enable autocompletion for command idf.py 2020-11-03 23:27:58 +01:00
Mahavir Jain
20af94ff53 Coredump config option rename throughout IDF 2020-09-30 20:22:27 +05:30
martin.gano
b599f127b5 add new command to idf 2020-09-21 23:38:52 +02:00
David Cermak
3b3409fb20 idf.py: Fixed gdb target to exit cleanly when no openocd watch task
When idf.py gdb starts, it expects openocd was started in the background
and creates a thread to watch for openocd errors. when gdb target exits,
the debug_ext.py aims to cleanup all threads and processes, but fails
with traceback if openocd-watch thread not available, which could happen
if openocd started separately.
2020-09-18 08:30:21 +02:00
Angus Gratton
ad295037a8 idf.py: Disable CMake --warn-uninitialized option by default
Can still be enabled by passing --cmake-warn-uninitialized on the command line

Prevents CMake warnings printed by default if IDF_PATH is underneath the CMake
project directory.

The reason for this is that CMake --warn-uninitialized only enables checks
inside the project directory (ie top-level CMakeLists.txt directory and
subdirectories), it doesn't enable for files included from other directories.

(The only way to enable warnings in other directories is to pass
--check-system-dirs and this looks like it's only useful for CMake's own
developers as it prints a lot of warnings from inside CMake otherwise - see
https://gitlab.kitware.com/cmake/cmake/-/issues/19645 )

Plan to follow up with a later commit to clean up most of the warnings (which
aren't problems for CMake execution), but we'll also disable this option by
default to avoid this unexpected triggering of IDF warnings.
2020-08-26 09:53:56 +10:00
Ivan Grokhotkov
6467f5dd54 tools: idf.py: default to board/esp32s2-kaluga-1.cfg for ESP32-S2
NFC. Kaluga-1 config is same as devkitj + esp32s2.
2020-07-24 15:54:47 +02:00
Ivan Grokhotkov
ba717a298f Merge branch 'bugfix/verify-directory-exists' into 'master'
Bugfix: add check for existence build directory

Closes IDF-984

See merge request espressif/esp-idf!9695
2020-07-24 19:53:27 +08:00
Ivan Grokhotkov
ba5aa21720 Merge branch 'bugfix/idf_monitor_baudrate_arg_crash' into 'master'
idf monitor: fix crash when monitor baudrate argument set

Closes IDF-1902

See merge request espressif/esp-idf!9546
2020-07-21 22:07:04 +08:00
Ivan Grokhotkov
7f977094bd Merge branch 'feature/idfpy_add_help_subcommand' into 'master'
idf.py: Add help and build-system-targets subcommands

Closes IDF-1884

See merge request espressif/esp-idf!9615
2020-07-21 22:06:14 +08:00
martin.gano
25b4b977d0 Add checking if the build directory exists and move expression after docstring 2020-07-21 13:18:50 +02:00
Sergei Silnov
140c5800dd idf.py: Add command to list build system targets 2020-07-15 16:43:17 +02:00
Marius Vikhammer
30f075f0bb idf monitor: fix crash when monitor baudrate argument set
Closes IDF-1902
2020-07-10 10:29:48 +08:00
Sergei Silnov
85de9d4f16 idf.py: Add help for options with envvar defaults 2020-06-30 12:04:35 +02:00
Ivan Grokhotkov
0f3aa8f520 Merge branch 'feature/idfpy_serial_ext_formatting' into 'master'
Tools: Update formatting at serial_ext.py

See merge request espressif/esp-idf!8954
2020-06-25 17:40:06 +08:00
Roland Dobai
995676010e Tools: Mention ESPPORT and ESPBAUD in idf.py --help
Closes https://github.com/espressif/esp-idf/issues/5461
2020-06-23 13:40:19 +02:00
Ivan Grokhotkov
5aae08e6b4 Merge branch 'feature/pyc_clean' into 'master'
tools/idf.py: Clean Python bytecode files

Closes IDFGH-3368

See merge request espressif/esp-idf!8907
2020-06-22 15:53:41 +08:00
morris
067b1b91c2 global: add new target name: esp32-s3
add target name, chip ID, toochain descriptions for ESP32-S3
2020-06-11 21:40:08 +08:00
Roland Dobai
9930060ea8 tools/idf.py: Clean Python bytecode files 2020-06-03 12:29:25 +02:00
Roland Dobai
0ff8ec66e4 Add ability to select a device for DFU flashing 2020-05-28 09:31:35 +02:00
sio13
76b9b3a11d
Update serial_ext.py
- replaced with oneliner
- removed default arguments
2020-05-22 12:00:00 +02:00
Scott Shawcroft
8c4dc88d27 tool: Fix spelling in core_ext.py
Closes: https://github.com/espressif/esp-idf/pull/5145
2020-05-13 14:50:43 +08:00
Angus Gratton
f9552baf97 Merge branch 'feature/dfu_build_flash_s2' into 'master'
Add build system support for programming ESP32-S2 using DFU utils

Closes IDF-579

See merge request espressif/esp-idf!8294
2020-05-04 14:57:51 +08:00
Ivan Grokhotkov
1ddfe0d465 Merge branch 'feature/gdbgui_gdbinit_arg' into 'master'
tools/idf.py: add --gdbinit argument to gdb, gdbgui, gdbtui

See merge request espressif/esp-idf!8370
2020-05-04 13:23:27 +08:00
Roland Dobai
ab9f714248 Add build system support for programming ESP32-S2 using DFU utils 2020-04-30 07:59:18 +02:00
Ivan Grokhotkov
7dad294061 tools/idf.py: add --gdbinit argument to gdb, gdbgui, gdbtui
Allows starting a debugging session with a custom set of init commands
2020-04-29 23:43:38 +02:00
Ivan Grokhotkov
7b79b52062 tools: allow alternative spellings of target name (ESP32-S2, ESP32S2)
by ignoring character case and hyphens in target name.
2020-04-29 23:42:18 +02:00
David Cermak
2c2f909133 idf.py: debug ext prints detailed info/hint on common openocd issues 2020-04-15 09:07:17 +02:00
David Cermak
ec391ddfa1 idf.py: fix debug extenstion to work with unit tests 2020-04-09 14:54:10 +02:00
David Cermak
3b5c3d6521 idf.py: debug targets for easier execution of openocd, gdb, gdbui
Support for execution of asynchronous target, such as openocd, which
by default runs in the background, but if it's the only target idf.py
outputs the openocd in the console waiting for termination by user.

Supports also blocking commands gdb and gdbtui to start a debugging
session in an active console.

Supports running gdbgui running a UI debugging session in a browser
window, using the active console for other commands, such as openocd
or monitor.

Supports combining the debug targets in one action list, such as
idf.py openocd gdbgui monitor
2020-04-07 17:37:48 +02:00
Roland Dobai
9b16594444 tools: Fix flashing encrypted binaries from IDF Monitor 2020-03-26 07:51:59 +01:00
Roland Dobai
c35538ecee tools: fix idf.py to be able to select a generator for build 2020-03-06 10:41:09 +01:00
Angus Gratton
2f1815f74e Merge branch 'bugfix/cmake_issues' into 'master'
CMake bugfixes

See merge request espressif/esp-idf!7605
2020-03-06 14:36:59 +08:00
Roland Dobai
2d97209475 tools: Force the order of cmake generators 2020-03-02 16:15:30 +01:00
Renz Christian Bagaporo
a5d49d4db5 tools: fix double builds with idf.py 2020-03-02 07:18:22 +05:00
Ivan Grokhotkov
25041ba583 tools/idf_monitor: automatically decode UART core dumps
This adds detection of UART core dumps to IDF monitor. By default,
core dumps are not printed to the console, but are processed by
espcoredump.py using 'info_corefile' command. The result is printed
to stdout.

This feature can be disabled in menuconfig.

In the future this can be extended to allow running espcoredump.py
with 'dbg_corefile' argument, which is similar to the current GDB Stub
behavior.

Related to IDF-52.
2020-02-13 18:46:26 +01:00
Angus Gratton
64654c0444 Merge branch 'fix/tools_py_environ_str' into 'master'
idf_py: fix the ESPPORT environ variable type issue

See merge request espressif/esp-idf!7433
2020-02-10 14:28:35 +08:00
Ivan Grokhotkov
9bff344ef5 idf.py: fail and show instructions on IDF_TARGET mismatch
Closes IDF-869
2020-01-31 11:08:22 +01:00
Ivan Grokhotkov
a1c1af72bf idf.py: guess IDF_TARGET from sdkconfig if CMakeCache doesn't exist
This solves the issue that target is changed to the default one after
idf.py fullclean.

Also allow setting the default target using sdkconfig.defaults, e.g.
CONFIG_IDF_TARGET="esp32s2"

Closes IDF-1040
2020-01-30 19:09:37 +01:00
Angus Gratton
f8e7285591 Merge branch 'feature/idfpy_add_baud_parameter_to_monitor' into 'master'
idf.py: add monitor-baud option to monitor command

Closes IDF-978

See merge request espressif/esp-idf!6613
2020-01-30 13:38:29 +08:00
morris
e30cd361a8 global: rename esp32s2beta to esp32s2 2020-01-22 12:14:38 +08:00
Michael (XIAO Xufeng)
cff1815177 idf_py: fix the ESPPORT environ variable type issue
Python 2 expect the environ variables are all of type 'str', but
sometimes wrong 'unicode' type is given.

Here we force all variables that are not str to become str.
2020-01-22 12:05:08 +08:00