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

Config

Struct Config 

Source
pub struct Config {
    pub timeout_vblanks: u32,
    pub irq_mask_policy: IrqMaskPolicy,
    pub pause_after_audio: bool,
    pub time_handler: bool,
    pub double_speed: bool,
}
Expand description

How the engine behaves.

Fields§

§timeout_vblanks: u32

A transfer with no sector, response or phase change for this many VBlanks fails with FailureKind::Watchdog.

§irq_mask_policy: IrqMaskPolicy§pause_after_audio: bool

Start the first transfer after an audio lease with a recovery Pause, so a drive that was playing or parked at an audio position is stopped before the seek. Costs one command; skip it only if the audio code always ends with its own Pause.

§time_handler: bool

Measure how long each handler call takes, with Timer 2, which the transport then owns. The longest call is max_irq_ticks, in system-clock / 8 ticks that wrap after about 15.5 ms.

§double_speed: bool

Read at double speed (150 sectors per second, the default and the only rate a streamer wants). Clear it for single speed (75 sectors per second), which halves the CPU the sector pops cost per second of reading; it applies from the next transfer.

Implementations§

Source§

impl Config

Source

pub const DEFAULT: Config

The defaults: 600 VBlanks, interrupt source always on, recovery pause after audio, no handler timing, double speed.

Trait Implementations§

Source§

impl Clone for Config

Source§

fn clone(&self) -> Config

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Config

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Config

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl PartialEq for Config

Source§

fn eq(&self, other: &Config) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Copy for Config

Source§

impl Eq for Config

Source§

impl StructuralPartialEq for Config

Auto Trait Implementations§

§

impl Freeze for Config

§

impl RefUnwindSafe for Config

§

impl Send for Config

§

impl Sync for Config

§

impl Unpin for Config

§

impl UnsafeUnpin for Config

§

impl UnwindSafe for Config

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CloneToUninit for T
where T: Clone,

§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.