[][src]Enum xc2bit::XC2BitstreamBits

pub enum XC2BitstreamBits {
    XC2C32 {
        fb: [XC2BitstreamFB; 2],
        iobs: [XC2MCSmallIOB; 32],
        inpin: XC2ExtraIBuf,
        global_nets: XC2GlobalNets,
        ivoltage: bool,
        ovoltage: bool,
    },
    XC2C32A {
        fb: [XC2BitstreamFB; 2],
        iobs: [XC2MCSmallIOB; 32],
        inpin: XC2ExtraIBuf,
        global_nets: XC2GlobalNets,
        legacy_ivoltage: bool,
        legacy_ovoltage: bool,
        ivoltage: [bool; 2],
        ovoltage: [bool; 2],
    },
    XC2C64 {
        fb: [XC2BitstreamFB; 4],
        iobs: [[XC2MCSmallIOB; 32]; 2],
        global_nets: XC2GlobalNets,
        ivoltage: bool,
        ovoltage: bool,
    },
    XC2C64A {
        fb: [XC2BitstreamFB; 4],
        iobs: [[XC2MCSmallIOB; 32]; 2],
        global_nets: XC2GlobalNets,
        legacy_ivoltage: bool,
        legacy_ovoltage: bool,
        ivoltage: [bool; 2],
        ovoltage: [bool; 2],
    },
    XC2C128 {
        fb: [XC2BitstreamFB; 8],
        iobs: [[XC2MCLargeIOB; 25]; 4],
        global_nets: XC2GlobalNets,
        clock_div: XC2ClockDiv,
        data_gate: bool,
        use_vref: bool,
        ivoltage: [bool; 2],
        ovoltage: [bool; 2],
    },
    XC2C256 {
        fb: [XC2BitstreamFB; 16],
        iobs: [[XC2MCLargeIOB; 23]; 8],
        global_nets: XC2GlobalNets,
        clock_div: XC2ClockDiv,
        data_gate: bool,
        use_vref: bool,
        ivoltage: [bool; 2],
        ovoltage: [bool; 2],
    },
    XC2C384 {
        fb: [XC2BitstreamFB; 24],
        iobs: [[XC2MCLargeIOB; 24]; 10],
        global_nets: XC2GlobalNets,
        clock_div: XC2ClockDiv,
        data_gate: bool,
        use_vref: bool,
        ivoltage: [bool; 4],
        ovoltage: [bool; 4],
    },
    XC2C512 {
        fb: [XC2BitstreamFB; 32],
        iobs: [[XC2MCLargeIOB; 27]; 10],
        global_nets: XC2GlobalNets,
        clock_div: XC2ClockDiv,
        data_gate: bool,
        use_vref: bool,
        ivoltage: [bool; 4],
        ovoltage: [bool; 4],
    },
}

The actual bitstream bits for each possible Coolrunner-II part

Variants

XC2C32

Fields of XC2C32

fb: [XC2BitstreamFB; 2]iobs: [XC2MCSmallIOB; 32]inpin: XC2ExtraIBufglobal_nets: XC2GlobalNetsivoltage: bool

Voltage level control

false = low, true = high

ovoltage: bool

Voltage level control

false = low, true = high

XC2C32A

Fields of XC2C32A

fb: [XC2BitstreamFB; 2]iobs: [XC2MCSmallIOB; 32]inpin: XC2ExtraIBufglobal_nets: XC2GlobalNetslegacy_ivoltage: bool

Legacy voltage level control, should almost always be set to false

false = low, true = high

legacy_ovoltage: bool

Legacy voltage level control, should almost always be set to false

false = low, true = high

ivoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

ovoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

XC2C64

Fields of XC2C64

fb: [XC2BitstreamFB; 4]iobs: [[XC2MCSmallIOB; 32]; 2]global_nets: XC2GlobalNetsivoltage: bool

Voltage level control

false = low, true = high

ovoltage: bool

Voltage level control

false = low, true = high

XC2C64A

Fields of XC2C64A

fb: [XC2BitstreamFB; 4]iobs: [[XC2MCSmallIOB; 32]; 2]global_nets: XC2GlobalNetslegacy_ivoltage: bool

Legacy voltage level control, should almost always be set to false

false = low, true = high

legacy_ovoltage: bool

Legacy voltage level control, should almost always be set to false

false = low, true = high

ivoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

ovoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

XC2C128

Fields of XC2C128

fb: [XC2BitstreamFB; 8]iobs: [[XC2MCLargeIOB; 25]; 4]global_nets: XC2GlobalNetsclock_div: XC2ClockDivdata_gate: bool

Whether the DataGate feature is used

use_vref: bool

Whether I/O standards with VREF are used

ivoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

ovoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

XC2C256

Fields of XC2C256

fb: [XC2BitstreamFB; 16]iobs: [[XC2MCLargeIOB; 23]; 8]global_nets: XC2GlobalNetsclock_div: XC2ClockDivdata_gate: bool

Whether the DataGate feature is used

use_vref: bool

Whether I/O standards with VREF are used

ivoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

ovoltage: [bool; 2]

Voltage level control for each I/O bank

false = low, true = high

XC2C384

Fields of XC2C384

fb: [XC2BitstreamFB; 24]iobs: [[XC2MCLargeIOB; 24]; 10]global_nets: XC2GlobalNetsclock_div: XC2ClockDivdata_gate: bool

Whether the DataGate feature is used

use_vref: bool

Whether I/O standards with VREF are used

ivoltage: [bool; 4]

Voltage level control for each I/O bank

false = low, true = high

ovoltage: [bool; 4]

Voltage level control for each I/O bank

false = low, true = high

XC2C512

Fields of XC2C512

fb: [XC2BitstreamFB; 32]iobs: [[XC2MCLargeIOB; 27]; 10]global_nets: XC2GlobalNetsclock_div: XC2ClockDivdata_gate: bool

Whether the DataGate feature is used

use_vref: bool

Whether I/O standards with VREF are used

ivoltage: [bool; 4]

Voltage level control for each I/O bank

false = low, true = high

ovoltage: [bool; 4]

Voltage level control for each I/O bank

false = low, true = high

Methods

impl XC2BitstreamBits[src]

pub fn device_type(&self) -> XC2Device[src]

Helper to convert ourself into a XC2Device enum because an XC2Device enum has various useful methods

pub fn get_fb(&self) -> &[XC2BitstreamFB][src]

Helper to extract only the function block data without having to perform an explicit match

pub fn get_fb_mut(&mut self) -> &mut [XC2BitstreamFB][src]

Helper to extract only the function block data without having to perform an explicit match

pub fn get_small_iob(&self, i: usize) -> Option<&XC2MCSmallIOB>[src]

Helper to extract only the I/O data without having to perform an explicit match

pub fn get_mut_small_iob(&mut self, i: usize) -> Option<&mut XC2MCSmallIOB>[src]

Helper to extract only the I/O data without having to perform an explicit match

pub fn get_large_iob(&self, i: usize) -> Option<&XC2MCLargeIOB>[src]

Helper to extract only the I/O data without having to perform an explicit match

pub fn get_mut_large_iob(&mut self, i: usize) -> Option<&mut XC2MCLargeIOB>[src]

Helper to extract only the I/O data without having to perform an explicit match

pub fn get_global_nets(&self) -> &XC2GlobalNets[src]

Helper to extract only the global net data without having to perform an explicit match

pub fn get_global_nets_mut(&mut self) -> &mut XC2GlobalNets[src]

Helper to extract only the global net data without having to perform an explicit match

pub fn get_clock_div(&self) -> Option<&XC2ClockDiv>[src]

pub fn to_crbit(&self, fuse_array: &mut FuseArray)[src]

Convert the actual bitstream bits to crbit format

pub fn dump_human_readable<W: Write>(&self, writer: W) -> Result<(), Error>[src]

Dump a human-readable explanation of the bitstream to the given writer object.

pub fn to_jed(&self, jed: &mut JEDECFile, linebreaks: &mut LinebreakSet)[src]

Write a .jed representation of the bitstream to the given jed object.

Trait Implementations

impl Clone for XC2BitstreamBits[src]

impl Copy for XC2BitstreamBits[src]

impl Debug for XC2BitstreamBits[src]

impl<'de> Deserialize<'de> for XC2BitstreamBits[src]

impl Eq for XC2BitstreamBits[src]

impl Hash for XC2BitstreamBits[src]

impl PartialEq<XC2BitstreamBits> for XC2BitstreamBits[src]

impl Serialize for XC2BitstreamBits[src]

impl StructuralEq for XC2BitstreamBits[src]

impl StructuralPartialEq for XC2BitstreamBits[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.