Skip to content

Commit 602ef30

Browse files
authored
Fix parsing of detection data for ESP32-S2 (#121)
***NO_CI***
1 parent 9aa44cb commit 602ef30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

nanoFirmwareFlasher/EspTool.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ internal Esp32DeviceInfo GetDeviceDetails(
200200
}
201201
}
202202

203-
var match = Regex.Match(messages, $"(Detecting chip type... )(?<type>[ESP32-ICOCH]+)(.*?[\r\n]*)*(Chip is )(?<name>.*)(.*?[\r\n]*)*(Features: )(?<features>.*)(.*?[\r\n]*)*(Crystal is )(?<crystal>.*)(.*?[\r\n]*)*(MAC: )(?<mac>.*)(.*?[\r\n]*)*(Manufacturer: )(?<manufacturer>.*)(.*?[\r\n]*)*(Device: )(?<device>.*)(.*?[\r\n]*)*(Detected flash size: )(?<size>.*)");
203+
var match = Regex.Match(messages, $"(Detecting chip type... )(?<type>[ESP32\\-ICOCH]+)(.*?[\r\n]*)*(Chip is )(?<name>.*)(.*?[\r\n]*)*(Features: )(?<features>.*)(.*?[\r\n]*)*(Crystal is )(?<crystal>.*)(.*?[\r\n]*)*(MAC: )(?<mac>.*)(.*?[\r\n]*)*(Manufacturer: )(?<manufacturer>.*)(.*?[\r\n]*)*(Device: )(?<device>.*)(.*?[\r\n]*)*(Detected flash size: )(?<size>.*)");
204204
if (!match.Success)
205205
{
206206
throw new EspToolExecutionException(messages);

0 commit comments

Comments
 (0)