mirror of
https://github.com/CharaChorder/DeviceManager.git
synced 2025-12-11 13:26:16 +00:00
feat: add suspense logs in serial console
This commit is contained in:
@@ -117,6 +117,13 @@ export class CharaDevice {
|
||||
})
|
||||
this.reader.releaseLock()
|
||||
await this.port.close()
|
||||
serialLog.update(it => {
|
||||
it.push({
|
||||
type: "system",
|
||||
value: "Connection suspended",
|
||||
})
|
||||
return it
|
||||
})
|
||||
}
|
||||
|
||||
private async wake() {
|
||||
@@ -131,6 +138,13 @@ export class CharaDevice {
|
||||
signal: this.abortController2.signal,
|
||||
})
|
||||
.getReader()
|
||||
serialLog.update(it => {
|
||||
it.push({
|
||||
type: "system",
|
||||
value: "Connection resumed",
|
||||
})
|
||||
return it
|
||||
})
|
||||
}
|
||||
|
||||
private async internalRead() {
|
||||
|
||||
Reference in New Issue
Block a user