c64 0.1.0-alpha.1

Driver for the Commodore 64 platform
Documentation
//! MOS 6510 core registers.

extern "C" {
    fn register_s_read() -> u8;
    fn register_p_read() -> u8;
}

/// Stack pointer.
pub mod s {
    /// Reads the stack pointer register.
    #[inline]
    pub fn read() -> u8 {
        unsafe { super::register_s_read() }
    }
}

/// Processor status register.
pub mod p {
    /// Reads the Processor Status register.
    ///
    /// Note that bit 5 is reserved and UNK (unknown).
    #[inline]
    pub fn read() -> u8 {
        unsafe { super::register_p_read() }
    }
}