Browse Source

Basic support for the rev 2023c board

The device selection dip switch properly detects each setting.
The ST32430N HDD setting only switches the device to disk drive mode.
It doesn't set the vendor or device strings yet.
Morio 2 years ago
parent
commit
167e1277c3

+ 5 - 4
lib/ZuluSCSI_platform_GD32F205/ZuluSCSI_v1_1_gpio.h

@@ -261,10 +261,11 @@
 #define DIPSW_SCSI_ID_BIT_SHIFT 13
 // Rotary DIP switch
 #define DIPROT_DEVICE_SEL_BIT_PORT  GPIOE
-#define DIPROT_DEVICE_SEL_BIT1_PIN  GPIO_PIN_5
-#define DIPROT_DEVICE_SEL_BIT2_PIN  GPIO_PIN_6
-#define DIPROT_DEVICE_SEL_BIT_PINS  (DIPROT_DEVICE_SEL_BIT1_PIN | DIPROT_DEVICE_SEL_BIT2_PIN)
-#define DIPROT_DEVICE_SEL_BIT_SHIFT 5
+#define DIPROT_DEVICE_SEL_BIT1_PIN  GPIO_PIN_4
+#define DIPROT_DEVICE_SEL_BIT2_PIN  GPIO_PIN_5
+#define DIPROT_DEVICE_SEL_BIT3_PIN  GPIO_PIN_6
+#define DIPROT_DEVICE_SEL_BIT_PINS  (DIPROT_DEVICE_SEL_BIT1_PIN | DIPROT_DEVICE_SEL_BIT2_PIN |  DIPROT_DEVICE_SEL_BIT3_PIN)
+#define DIPROT_DEVICE_SEL_BIT_SHIFT 4
 
 // ODE I2S Audio
 #define ODE_I2S_CK_PORT GPIOD

+ 11 - 3
lib/ZuluSCSI_platform_GD32F205/platform_hw_config.cpp

@@ -72,15 +72,23 @@ void HardwareConfig::init_state(bool is_active)
         m_device_type = S2S_CFG_FIXED;
     break;
     case 1:
-        m_device_type = S2S_CFG_SEQUENTIAL;
+        m_device_type = S2S_CFG_OPTICAL;
     break;
     case 2:
-        m_device_type = S2S_CFG_OPTICAL;
+        m_device_type = S2S_CFG_FLOPPY_14MB;
     break;
     case 3:
         m_device_type = S2S_CFG_REMOVABLE;
     break;
-
+    case 4:
+        m_device_type = S2S_CFG_MO;
+    break;
+    case 5:
+        m_device_type = S2S_CFG_FIXED;
+    break;
+    case 6:
+        m_device_type = S2S_CFG_SEQUENTIAL;
+    break;
     default:
         m_device_type = S2S_CFG_FIXED;
     }