mirror of
https://github.com/arduino/arduino-ide.git
synced 2025-07-13 22:36:32 +00:00
Fix monitor service id creation (#1025)
This commit is contained in:
parent
585a82b51a
commit
726628e20c
@ -76,7 +76,7 @@ export class ArduinoFirmwareUploaderImpl implements ArduinoFirmwareUploader {
|
||||
fqbn: firmware.board_fqbn,
|
||||
};
|
||||
try {
|
||||
this.monitorManager.notifyUploadStarted(board, port);
|
||||
await this.monitorManager.notifyUploadStarted(board, port);
|
||||
output = await this.runCommand([
|
||||
'firmware',
|
||||
'flash',
|
||||
|
@ -215,6 +215,8 @@ export class MonitorManager extends CoreClientAware {
|
||||
* @returns a unique monitor ID
|
||||
*/
|
||||
private monitorID(board: Board, port: Port): MonitorID {
|
||||
return `${board.fqbn}-${port.address}-${port.protocol}`;
|
||||
const splitFqbn = board?.fqbn?.split(':') || [];
|
||||
const shortenedFqbn = splitFqbn.slice(0, 3).join(':') || '';
|
||||
return `${shortenedFqbn}-${port.address}-${port.protocol}`;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user