Commit Graph

65 Commits

Author SHA1 Message Date
Martin Gaňo
252036567c Moved filters out of idf_monitor.py 2021-06-17 21:38:38 +02:00
Roland Dobai
483f51cdd0 tools: Some additions to IDF Monitor's timestamps
Additions to https://github.com/espressif/esp-idf/pull/7021
2021-06-13 12:13:39 +02:00
Andrey Starodubtsev
f91bde97c1 Add timestamps for idf_monitor.py
Closes https://github.com/espressif/esp-idf/pull/7021
2021-06-11 16:46:52 +02:00
Dmitry
00a7ecb5a3 Code cleanup. Bugfix after rebase with master. Formating. 2021-05-13 15:03:40 +03:00
Dmitry
a16ae6c737 IDF monitor update 2021-05-11 16:08:44 +03:00
Roland Dobai
0dc3da6dce tools: Fix ANSI color converter on Windows
Fix a regression of b77addea2f: The ANSI
color converter returns a class on Windows instead of an object so its
methods won't be callable and will result in a not so helpful error
message: "idf_monitor failed with exit code 120"
2021-04-15 19:56:39 +02:00
Martin Gaňo
b77addea2f Decompose idf_monitor.py 2021-04-12 10:47:33 +02:00
Juraj Michálek
181a2389dc tools: handle exception in case of logging Unicode characters 2021-03-25 13:09:34 +01:00
Fu Hanxi
0146f258d7 style: format python files with isort and double-quote-string-fixer 2021-01-26 10:49:01 +08:00
Martin Gaňo
8c0a3aa006 Add ability to disable address decoding using evironment variable
Closes https://github.com/espressif/esp-idf/issues/1679
2021-01-08 15:13:50 +01: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
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
Ivan Grokhotkov
dd8cef9f01 Merge branch 'bugfix/dev_tty_cu_darwin_only_pr5462' into 'master'
idf_monitor: only mangle /dev/tty.* on Darwin

Closes IDFGH-3507

See merge request espressif/esp-idf!10169
2020-08-28 17:39:57 +08:00
Roland Dobai
b9eb7cb7f0 tools: Fix IDF Monitor so it will wait for the device to reconnect 2020-06-29 09:18:05 +02:00
Ivan Grokhotkov
c140a66d3d Merge branch 'feature/coredump_pygdbmi' into 'master'
espcoredump: use pygdbmi for interaction with GDB

Closes IDF-48

See merge request espressif/esp-idf!8841
2020-06-23 01:44:45 +08:00
Ivan Grokhotkov
23a679a7c5 tools: idf_monitor.py: show espcoredump.py error output on failure 2020-06-18 19:08:00 +02:00
Kiril Zyapkov
e64bc76495 idf_monitor: only mangle /dev/tty.* on Darwin 2020-06-17 11:52:30 +03:00
Roland Dobai
e67314f646 tools/idf_monitor: add WebSocket client for IDE integration 2020-06-10 10:56:20 +00:00
michael
8aafb6b513 idf_monitor: support to re-flash with the using port
This commit make idf_monitor overwrite the ESPPORT environment variable
with the port it's using, and re-run make with the modified environment
variable. In this way, the make invoked will inherit the idf_monitor's
port.

Closes https://github.com/espressif/esp-idf/issues/4591
2020-04-07 01:44:26 +08:00
Roland Dobai
9b16594444 tools: Fix flashing encrypted binaries from IDF Monitor 2020-03-26 07:51:59 +01:00
Michael (XIAO Xufeng)
b00cea250f idf_monitor: fix gdb issue opening large COM port on Windows
The GDB uses CreateFile to open COM port on Windows. However this
function requires COM path to be `\\.\COMx` to open COM port whose
number is larger than 10.

Replace the port name from `COM` to `\\.\COM` when on Windows to fix
this.
2020-02-17 07:39:21 +00: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
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
Rosa Elena Veiga Otero
af6541e773 tools: work around usbser.sys bug in idf_monitor
implemented workaround in idf_monitor for known usbser.sys bug which
causes changes in RTS signal to only be sent if DTR signal also changes.
Works by forcing a dummy change in DTR signal (re-assigning its current
value, as it has previously been done in the flashing tool)

Closes https://github.com/espressif/esp-idf/pull/4676
2020-01-28 11:47:45 +01:00
Angus Gratton
2e43d107b4 idf_monitor: Ignore OS-level errors writing to Windows Console
Windows Console write or flush may fail (throwing WindowsError, a subclass of OSError) if the data
written can't be displayed. This may be the case if the serial port is producing garbage bytes.

Ignore the error, in the hope that the serial port may "come good" and write non-garbage later.
2019-12-18 23:35:35 +00:00
Sergei Silnov
767cde7b1c idf.py: add monitor-baud option to monitor command 2019-12-13 21:40:21 +01:00
Roland Dobai
72040f2c44 idf_monitor: Autodetect port
Closes https://github.com/espressif/esp-idf/issues/4191
2019-10-14 08:06:43 +02:00
Per-Olov Jernberg
6435c9f3d5 idf_monitor: Exit with CTRL+X in menu
Currently, the only way of exiting the idf_monitor program is to hit the CTRL+] button, if your keyboard doesn't have that key unless you hit another modifier key, it's not super trivial to exit.

This change adds the option to exit with CTRL+T (for menu) then hitting X (or CTRL+X) for exiting.

Closes https://github.com/espressif/esp-idf/pull/4167
Closes https://github.com/espressif/esp-idf/issues/4129
2019-10-08 08:15:51 +00:00
Michael (XIAO Xufeng)
24f91617d7 idf_monitor: fix the bug that idf_monitor not blocked when no log printed
Inspired by @no1seman, @negativekelvin and @pglen on Github. (In post oder)

Resolves https://github.com/espressif/esp-idf/issues/3884
2019-08-16 17:56:51 +08:00
Michael (XIAO Xufeng)
a2155ff52d idf_monitor: improve the responding of console commands 2019-08-01 11:55:42 +08:00
Angus Gratton
47bbb107a8 build system: Use CMake-based build system as default when describing commands 2019-07-08 17:31:27 +10:00
Roland Dobai
f56b7d4a1d tools: Accept CTRL-T + A for app-flash in idf_monitor
"CTRL-A" cannot be captured in Windows command line, so "A" can be used
instead.
2019-06-27 12:21:09 +02:00
Roland Dobai
2a419fa599 tools: Create log files from IDF Monitor 2019-03-18 19:33:20 +01:00
Roland Dobai
b0a43f07d9 tools: Print useful error message from idf_monitor when toolchain isn't available 2018-12-12 08:22:45 +01:00
Roland Dobai
1b464d23a9 tools: Correct coding style of idf_monitor 2018-11-26 15:02:39 +01:00
Roland Dobai
608fc23278 tools: Fix idf_monitor test case occasional hangup or failure
Closes idf/esp-idf#39
2018-11-23 13:33:17 +01:00
Angus Gratton
b355854d4d Merge branch 'master' into feature/cmake 2018-09-05 10:35:04 +08:00
Roland Dobai
276cba1103 idf_monitor: Fix Unicode decoding on Windows
Closes https://github.com/espressif/esp-idf/issues/2348
2018-08-31 12:20:55 +02:00
Angus Gratton
a9c4ed7139 Merge branch 'master' into feature/cmake 2018-08-30 18:51:01 +08:00
Roland Dobai
7118f4734b tools: Support Python3 in idf_monitor
Closes https://github.com/espressif/esp-idf/pull/1284
2018-08-24 08:12:19 +02:00
Angus Gratton
ff2404a272 Merge branch 'master' into feature/cmake 2018-08-16 17:14:17 +10:00
Roland Dobai
c1ae49dda1 Test the IDF Monitor through sockets
Creates a socket by socat and sends tests to the idf_monitor through it.
2018-07-09 08:37:40 +02:00
Roland Dobai
797340f7f8 idf_monitor: Fix console performance
51e42d8e92
introduced filtering options which handles the last (unterminated) line
with a delay. This introduced poor performance for console applications
when the user interacts with the ESP32 device in the same line because
there is an artificial delay for each key-press.

bb152030a0
decreased the delay but there are still delays for each key-presses.

The current fix makes only one delay per line instead of each
key-presses. When an unterminated line is detected then no more
"delayed" print is used for the given line.

Fixes https://github.com/espressif/esp-idf/issues/2054
2018-06-19 13:29:57 +02:00
Roland Dobai
bb152030a0 Fix the console performance issue
The IDF monitor waits for one second before printing the last
unterminated line. This is necessary for the correct filtering.
However, this causes poor performance, for example, in the case of the
system/console example.

This fix reduces the waiting time which improves the response time of
the console example and doesn't seem to influence the monitor filter.

Closes https://github.com/espressif/esp-idf/issues/2054
2018-06-13 08:05:31 +02:00
Roland Dobai
51e42d8e92 idf_monitor: add support for filtering options 2018-06-05 12:23:27 +02:00
Angus Gratton
be4956fe7c docs: Add some tips about setting the Python interpreter, and a specific check in idf.py
Don't show the "Python 2 interpreter" option in menuconfig when using CMake.

This is a stop-gap until we support Python 2 & 3 together in ESP-IDF (soon).

Closes https://github.com/espressif/esp-idf/issues/1924
2018-05-29 16:34:45 +10:00
Angus Gratton
8453806a8c idf.py: Fix 'idf.py monitor' build & flash targets 2018-05-04 16:05:25 +10:00
Angus Gratton
3e83cfd77c idf_monitor: Fix bug with Windows 10 sometimes printing a character twice
Turns out when IOError is thrown by the console, the character is
also successfully displayed.

Revisits fix from https://github.com/espressif/esp-idf/issues/1136

As reported https://esp32.com/viewtopic.php?f=14&t=4766&p=20637
2018-02-21 08:35:43 +11:00
Angus Gratton
4eab275a51 idf_monitor: Fix remaining case of Windows "console write fails" bug
Closes https://github.com/espressif/esp-idf/pull/1567
2018-02-01 14:05:56 +08:00