From 7915412fc7e86e39fc5dbafa508d6eefd5d8fd69 Mon Sep 17 00:00:00 2001 From: toxieainc Date: Mon, 13 Jan 2025 17:21:13 +0100 Subject: [PATCH] leftovers,NFC --- src/wpc/core.c | 4 ++-- src/wpc/dedmd.c | 1 + src/wpc/sam.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/wpc/core.c b/src/wpc/core.c index 46d808408..b59b3b3c4 100644 --- a/src/wpc/core.c +++ b/src/wpc/core.c @@ -2827,7 +2827,7 @@ void core_update_pwm_outputs(const int startIndex, const int count) UINT8 col = 0; for (int j = 0; j < 8; j++) if (coreGlobals.physicOutputState[CORE_MODOUT_LAMP0 + i * 8 + j].value >= 0.1f) - col |= 1 << j; + col |= (UINT8)1 << j; coreGlobals.lampMatrix[i] = col; } } @@ -2836,7 +2836,7 @@ void core_update_pwm_outputs(const int startIndex, const int count) UINT32 sols = 0; for (int i = 0; i < 32; i++) if (coreGlobals.physicOutputState[CORE_MODOUT_SOL0 + i].value >= 0.5f) - sols |= 1 << i; + sols |= 1u << i; coreGlobals.solenoids = sols; } } diff --git a/src/wpc/dedmd.c b/src/wpc/dedmd.c index 422eadaf3..2fcdf2c47 100644 --- a/src/wpc/dedmd.c +++ b/src/wpc/dedmd.c @@ -562,6 +562,7 @@ static WRITE_HANDLER(dmd16_ctrl_w) { } static void dmd16_updbusy(int evt) { + //const int prev_busy = dmdlocals.busy; // TODO CLR_PULSE will reset the flip flop to 0 even while PRESET is pulled down. This does not match the datasheet which states // that in this situation both output would be high (so keep BUSY at 1, but also trigger INT1). if (evt == BUSY_CLR_PULSE) diff --git a/src/wpc/sam.c b/src/wpc/sam.c index 8a1a5a0bf..542d38f82 100644 --- a/src/wpc/sam.c +++ b/src/wpc/sam.c @@ -1413,7 +1413,7 @@ static MACHINE_INIT(sam) { core_set_pwm_output_type(CORE_MODOUT_LAMP0 + 100, 6, CORE_MODOUT_LED); // Ramp RGB LEDs core_set_pwm_output_type(CORE_MODOUT_SOL0 + 17 - 1, 5, CORE_MODOUT_BULB_89_20V_DC_WPC); core_set_pwm_output_type(CORE_MODOUT_SOL0 + 25 - 1, 8, CORE_MODOUT_BULB_89_20V_DC_WPC); - if (rootDrv->name[strlen(rootDrv->name)-1] == 'h') + if (gn[strlen(gn)-1] == 'h') core_set_pwm_output_type(CORE_MODOUT_LAMP0, 80, CORE_MODOUT_LED_STROBE_1_10MS); // Limited Edition: All LED else core_set_pwm_output_type(CORE_MODOUT_LAMP0 + 60 - 1, 3, CORE_MODOUT_LED_STROBE_1_10MS); // Pro: #555 except for bumper LEDs