From 510b1c2f0f407116f70b556e6b52adb8c1e2c135 Mon Sep 17 00:00:00 2001 From: Samuel Dai Date: Wed, 19 Mar 2025 21:58:07 +0800 Subject: [PATCH] feat(ide): disable empty debug terminal, add qemu output to file (#5) --- .vscode/launch.json | 2 ++ oscomp/ci-start-riscv64.sh | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index f0061980..b1894f7c 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -17,6 +17,8 @@ ], "args": [], "cwd": "${workspaceFolder}", + "sourceLanguages": ["c", "cpp", "rust"], + "console": "internalConsole" } ] } \ No newline at end of file diff --git a/oscomp/ci-start-riscv64.sh b/oscomp/ci-start-riscv64.sh index f5aecc39..00b64618 100644 --- a/oscomp/ci-start-riscv64.sh +++ b/oscomp/ci-start-riscv64.sh @@ -1,3 +1,4 @@ +LOG_FILE="../serial_opt.txt" # uboot版本 UBOOT_VERSION="v2023.10" RISCV64_UBOOT_PATH="../tools/arch/riscv64/u-boot-${UBOOT_VERSION}-riscv64" @@ -25,4 +26,6 @@ qemu-system-riscv64 -machine virt -kernel ../tools/arch/riscv64/u-boot-v2023.10- -no-reboot -device virtio-net-device,netdev=net -netdev user,id=net \ -rtc base=utc \ -drive file=../bin/riscv64/disk.img,if=none,format=raw,id=x1 \ - -device virtio-blk-device,drive=x1,bus=virtio-mmio-bus.1 -s \ No newline at end of file + -device virtio-blk-device,drive=x1,bus=virtio-mmio-bus.1 -s \ + -serial chardev:mux -monitor chardev:mux \ + -chardev stdio,id=mux,mux=on,signal=off,logfile=${LOG_FILE} \ No newline at end of file