Skip to content

fix: Pass --platform param to set default Switch (Ounce) targets#41

Draft
tustanivsky wants to merge 7 commits intomainfrom
fix/switch-target-platform
Draft

fix: Pass --platform param to set default Switch (Ounce) targets#41
tustanivsky wants to merge 7 commits intomainfrom
fix/switch-target-platform

Conversation

@tustanivsky
Copy link
Collaborator

@tustanivsky tustanivsky commented Feb 24, 2026

Summary

Target Manager 2 maintains separate default targets per platform (NX vs Ounce). Without --platform arg, ControlTarget commands default to NX, which fails for Ounce (Switch 2) devices.

Key Changes

  • set-default-target / getstatus: Add --platform parameter to command templates, inferred from target serial prefix (HAL* = Ounce, else NX)
  • DetectAndSetDefaultTarget(): Skip auto-detection when target was explicitly set in Connect([string]$target), since set-default was already called with the correct platform
  • GetDeviceStatus() / TestConnection(): Override to pass --platform so status queries return the correct device info

@tustanivsky tustanivsky force-pushed the fix/switch-target-platform branch 2 times, most recently from b31b033 to 7852403 Compare February 24, 2026 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant