Skip to main content
← PSoXide SDK guides and examples · SDK f2fec1c301f1 · All Cargo features enabled; check feature gates before use.

require_analog_on

Function require_analog_on 

Source
pub fn require_analog_on<T: Transport>(
    port: &mut T,
    socket: Port,
) -> AnalogRequirement
Expand description

Put the controller in socket in analog mode, lock it there, and report what it settled on. For programs that need sticks and must not let the Analog button flip the pad back to digital mid-session. Call it at boot (a chain-loaded program starts from whatever the previous one left) and again while the answer is not AnalogRequirement::Analog, so a pad plugged in later is picked up.