pub struct Channel {
pub dmap: u8,
pub target: u8,
pub source_addr: u16,
pub source_bank: u8,
pub count_or_indirect: u16,
pub indirect_bank: u8,
pub hdma_addr: u16,
pub line_counter: u8,
pub hdma_completed: bool,
pub hdma_do_transfer: bool,
}Expand description
One of the 8 DMA channels ($43n0-$43nA).
Fields§
§dmap: u8$43n0 DMAP — transfer params: bit7 direction (0 = A→B, 1 = B→A), bit6 indirect (HDMA),
bit4 reverse (GP-DMA addr decrement), bit3 fixed (GP-DMA addr no-change), bits2-0 mode.
target: u8$43n1 BBAD — B-bus target low byte (the $21xx register).
source_addr: u16$43n2-3 A1T — A-bus source address (GP) / table address (HDMA).
source_bank: u8$43n4 A1B — A-bus source bank.
count_or_indirect: u16$43n5-6 DAS — GP byte count / HDMA indirect address.
indirect_bank: u8$43n7 DASB — HDMA indirect bank.
hdma_addr: u16$43n8-9 A2A — HDMA table running address.
line_counter: u8$43nA NTRL — HDMA line counter (bit7 = repeat, bits0-6 = lines).
hdma_completed: boolHDMA: this channel has finished its table for the frame.
hdma_do_transfer: boolHDMA: perform a transfer on this line (vs. just decrement the counter).
Trait Implementations§
impl Copy for Channel
Auto Trait Implementations§
impl Freeze for Channel
impl RefUnwindSafe for Channel
impl Send for Channel
impl Sync for Channel
impl Unpin for Channel
impl UnsafeUnpin for Channel
impl UnwindSafe for Channel
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more