Initial commit

This commit is contained in:
backuppc
2026-01-16 14:35:56 +09:00
commit 550b8263db
15 changed files with 1183 additions and 0 deletions

23
types.ts Normal file
View File

@@ -0,0 +1,23 @@
export enum ViewMode {
ASCII = 'ASCII',
HEX = 'HEX'
}
export interface SerialLogEntry {
id: string;
timestamp: Date;
direction: 'TX' | 'RX';
data: Uint8Array;
}
// Minimal Web Serial API type definitions since they aren't in all TS configs yet
export interface SerialPort {
open(options: { baudRate: number }): Promise<void>;
close(): Promise<void>;
readable: ReadableStream<Uint8Array> | null;
writable: WritableStream<Uint8Array> | null;
}
export interface NavigatorSerial {
requestPort(options?: { filters: any[] }): Promise<SerialPort>;
}