Skip to content

Commit aa695ad

Browse files
authored
Merge branch 'master' into mock/donthave
2 parents 5ff2d07 + 685f2c9 commit aa695ad

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

libraries/ESP8266WiFi/src/enable_wifi_at_boot_time.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ extern "C" void __disableWiFiAtBootTime()
2121
// Does (almost) nothing: WiFi is enabled by default in nonos-sdk
2222

2323
// ... but restores legacy WiFi credentials persistence to true at boot time
24-
// (can be still overrisden by user before setting up WiFi, like before)
24+
// (can be still overridden by user before setting up WiFi, like before)
2525

2626
// (note: c++ ctors not called yet at this point)
2727
ESP8266WiFiClass::persistent(true);

tools/decoder.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import sys
1111
import re
1212
import subprocess
13+
import shutil
1314

1415
# https://github.com/me-no-dev/EspExceptionDecoder/blob/349d17e4c9896306e2c00b4932be3ba510cad208/src/EspExceptionDecoder.java#L59-L90
1516
EXCEPTION_CODES = (
@@ -104,7 +105,10 @@ def decode_lines(format_addresses, elf, lines):
104105

105106
STACK_LINE_RE = re.compile(r"^[0-9a-f]{8}:\s\s+")
106107

108+
IGNORE_FIRMWARE_RE = re.compile(r"^(epc1=0x........, |Fatal exception )")
109+
107110
CUT_HERE_STRING = "CUT HERE FOR EXCEPTION DECODER"
111+
DECODE_IT = "DECODE IT"
108112
EXCEPTION_STRING = "Exception ("
109113
EPC_STRING = "epc1="
110114

@@ -132,6 +136,8 @@ def format_address(address):
132136
stack_addresses = print_all_addresses(stack_addresses)
133137
last_stack = line.strip()
134138
# 3fffffb0: feefeffe feefeffe 3ffe85d8 401004ed
139+
elif IGNORE_FIRMWARE_RE.match(line):
140+
continue
135141
elif in_stack and STACK_LINE_RE.match(line):
136142
_, addrs = line.split(":")
137143
addrs = ANY_ADDR_RE.findall(addrs)
@@ -163,8 +169,10 @@ def format_address(address):
163169
in_stack = True
164170
# ignore
165171
elif "<<<stack<<<" in line:
172+
in_stack = False
173+
stack_addresses = print_all_addresses(stack_addresses)
166174
continue
167-
elif CUT_HERE_STRING in line:
175+
elif CUT_HERE_STRING in line or DECODE_IT in line:
168176
continue
169177
else:
170178
line = line.strip()
@@ -181,6 +189,9 @@ def select_tool(toolchain_path, tool, func):
181189
path = f"xtensa-lx106-elf-{tool}"
182190
if toolchain_path:
183191
path = os.path.join(toolchain_path, path)
192+
193+
if not shutil.which(path):
194+
raise FileNotFoundError(path)
184195

185196
def formatter(func, path):
186197
def wrapper(elf, addresses):

0 commit comments

Comments
 (0)