Skip to content

Commit 30c3181

Browse files
committed
Fix mirrored mode from not locking out other settings
1 parent ef8f7fb commit 30c3181

2 files changed

Lines changed: 9 additions & 5 deletions

File tree

src/config_bus.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ void apply_bus_config(bool quiet) // ISSUE: FINISH
222222
}
223223

224224
/* Mirrored is easy */
225-
if (cfg.mirrored) { /* mirrored (act-as-one) enabled overrules all other socket settings */
225+
if (cfg.mirrored) { /* Mirrored (act-as-one) overrules everything at runtime :) */
226226

227227
cfg.one = cfg.two = cfg.three = cfg.four = 0; /* CS1 & CS2 low */
228228
cfg.one_mask = cfg.two_mask = cfg.three_mask = cfg.four_mask = 0x1F; /* Map everything to SID1 */

src/config_socket.c

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -410,10 +410,14 @@ void apply_socket_config(bool quiet)
410410
cfg.sock_two_dual = usbsid_config.socketTwo.dualsid;
411411
cfg.chip_two = usbsid_config.socketTwo.chiptype; /* Chiptype must be clone for dualsid to work! */
412412

413-
cfg.sids_one = (cfg.sock_one == true) ? (cfg.sock_one_dual == true) ? 2 : 1 : 0;
414-
cfg.sids_two = (cfg.sock_two == true) ? (cfg.sock_two_dual == true) ? 2 : 1 : 0;
415-
cfg.numsids = (cfg.sids_one + cfg.sids_two);
416-
413+
if (!cfg.mirrored) {
414+
cfg.sids_one = (cfg.sock_one == true) ? (cfg.sock_one_dual == true) ? 2 : 1 : 0;
415+
cfg.sids_two = (cfg.sock_two == true) ? (cfg.sock_two_dual == true) ? 2 : 1 : 0;
416+
cfg.numsids = (cfg.sids_one + cfg.sids_two);
417+
} else {
418+
/* Mirrored (act-as-one) overrules everything at runtime :) */
419+
cfg.sids_one = cfg.sids_two = cfg.numsids = 1;
420+
}
417421
return;
418422
}
419423

0 commit comments

Comments
 (0)