Skip to content

Commit

Permalink
sigmab98: fix regression with hopper motor
Browse files Browse the repository at this point in the history
  • Loading branch information
happppp committed Oct 24, 2024
1 parent 68008cf commit 2021a6e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions src/mame/ausnz/excali64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -629,6 +629,7 @@ void excali64_state::excali64(machine_config &config)
/* Devices */
CASSETTE(config, m_cass);
m_cass->add_route(ALL_OUTPUTS, "mono", 0.05);
m_cass->set_default_state(CASSETTE_STOPPED | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED);

WD2793(config, m_fdc, 16_MHz_XTAL / 8);
m_fdc->drq_wr_callback().set(m_dma, FUNC(z80dma_device::rdy_w));
Expand Down
10 changes: 5 additions & 5 deletions src/mame/sigma/sigmab98.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -786,7 +786,7 @@ void sigmab98_state::c6_w(uint8_t data)
// 02 hopper motor on (active low)?
void sigmab98_state::c8_w(uint8_t data)
{
m_hopper->motor_w(~data >> 1 & data & 1);
m_hopper->motor_w((!(data & 0x02) && (data & 0x01)) ? 1 : 0);

m_c8 = data;
show_outputs();
Expand Down Expand Up @@ -877,7 +877,7 @@ void lufykzku_state::lufykzku_c8_w(uint8_t data)
{
// bit 0? on payout button
// bit 1? when ending payment
m_hopper->motor_w(( (data & 0x01) && !(data & 0x02)) ? 0 : 1);
m_hopper->motor_w(((data & 0x01) && !(data & 0x02)) ? 1 : 0);

m_dsw_shifter[0]->shift_load_w(BIT(data, 4));
m_dsw_shifter[1]->shift_load_w(BIT(data, 4));
Expand Down Expand Up @@ -998,7 +998,7 @@ void sammymdl_state::leds_w(uint8_t data)
// 01 hopper motor on (active low)?
void sammymdl_state::hopper_w(uint8_t data)
{
m_hopper->motor_w((!(data & 0x01) && (data & 0x02)) ? 0 : 1);
m_hopper->motor_w((!(data & 0x01) && (data & 0x02)) ? 1 : 0);

m_out[2] = data;
show_3_outputs();
Expand Down Expand Up @@ -1062,8 +1062,8 @@ void sammymdl_state::gocowboy_leds_w(uint8_t data)

// 10 hopper enable?
// 20 hopper motor on (active low)?
m_hopper_small->motor_w((!(data & 0x20) && (data & 0x10)) ? 0 : 1);
m_hopper_large->motor_w((!(data & 0x80) && (data & 0x40)) ? 0 : 1);
m_hopper_small->motor_w((!(data & 0x20) && (data & 0x10)) ? 1 : 0);
m_hopper_large->motor_w((!(data & 0x80) && (data & 0x40)) ? 1 : 0);

m_out[1] = data;
show_3_outputs();
Expand Down

0 comments on commit 2021a6e

Please sign in to comment.