pub struct DeviceMemory<RB: RegisterBacking> { /* private fields */ }
Expand description

Object containing all memory regions (we have available) of the device

Implementations

Creates a new instance of the device memory

Adds a memory region to the device memory

Adds a memory region to the device memory

Adds register data to the device memory

Adds register data to the device memory

Returns the slice of memory that can be found at the given address_range. If the given address range is not fully within one of the captured regions present in the device memory, then None is returned.

Reads a byte from the given address if it is present in one of the captured regions present in the device memory

Reads a u32 from the given address if it is present in one of the captured regions present in the device memory

Try to get the value of the given register. Returns an error if the register is not present in any of the register collections.

Try to get a reference to the given register. Returns an error if the register is not present in any of the register collections.

Try to get a mutable reference to the given register. Returns an error if the register is not present in any of the register collections.

Trait Implementations

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

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.