Skip to content

Commit

Permalink
Merge pull request #329 from ZuluSCSI/zs-v1.2-update
Browse files Browse the repository at this point in the history
ZuluSCSI v1.2 rev 2023c update
  • Loading branch information
aperezbios authored Nov 3, 2023
2 parents b701296 + a90b110 commit 5eadcdf
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 10 deletions.
19 changes: 12 additions & 7 deletions lib/ZuluSCSI_platform_GD32F205/ZuluSCSI_v1_1_gpio.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,10 @@
#define ADC_VERSION_DETECT_V1_2_LIMIT_LOW 0
#define ADC_VERSION_DETECT_V1_2_LIMIT_HIGH 4096*1

// I2C and SPI Interrupt Pin
#define INTR_PORT GPIOE
#define INTR_PIN GPIO_PIN_1

// SPI Pins: v1.2
#define SPI_CS_PORT GPIOB
#define SPI_CS_PIN GPIO_PIN_9
Expand Down Expand Up @@ -261,10 +265,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
Expand Down Expand Up @@ -302,8 +307,8 @@
#define EJECT_2_PORT GPIOE
#define EJECT_2_PIN GPIO_PIN_6

// Ejection button is on GPIO PA3 and USER button is on GPIO PA2
// Ejection button is on GPIO PA2 and USER button is on GPIO PA3
#define EJECT_BTN_PORT GPIOA
#define EJECT_BTN_PIN GPIO_PIN_3
#define EJECT_BTN_PIN GPIO_PIN_2
#define USER_BTN_PORT GPIOA
#define USER_BTN_PIN GPIO_PIN_2
#define USER_BTN_PIN GPIO_PIN_3
14 changes: 11 additions & 3 deletions lib/ZuluSCSI_platform_GD32F205/platform_hw_config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}
Expand Down

0 comments on commit 5eadcdf

Please sign in to comment.