From 8d01829fa7c09ea1d6a42041f0b80d838d48d7a4 Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Wed, 29 Nov 2023 11:35:21 -0500 Subject: [PATCH] Adopt PC-style naming, limit to one drive. --- Machines/PCCompatible/PCCompatible.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Machines/PCCompatible/PCCompatible.cpp b/Machines/PCCompatible/PCCompatible.cpp index 6a6372db7..17a96f10a 100644 --- a/Machines/PCCompatible/PCCompatible.cpp +++ b/Machines/PCCompatible/PCCompatible.cpp @@ -45,7 +45,13 @@ namespace PCCompatible { class FloppyController { public: - FloppyController(PIC &pic, DMA &dma) : pic_(pic), dma_(dma) {} + FloppyController(PIC &pic, DMA &dma) : pic_(pic), dma_(dma) { + // Default: one floppy drive only. + drives_[0].exists = true; + drives_[1].exists = false; + drives_[2].exists = false; + drives_[3].exists = false; + } void set_digital_output(uint8_t control) { // printf("FDC DOR: %02x\n", control); @@ -227,7 +233,9 @@ class FloppyController { } drives_[4]; std::string drive_name(int c) const { - return std::string("Drive ") + std::to_string(c + 1); + char name[3] = "A"; + name[0] += c; + return std::string("Drive ") + name; } Activity::Observer *observer_ = nullptr;