1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
use super::*;

/// "Background 0 Offset" (Text mode only).
///
/// Given in `[x, y]`.
///
/// Only the lowest 9 bits of each coordinate are used (`0..=511`).
#[cfg(feature = "unsafe_addresses")]
pub const BG0OFS: WriteOnlyVolAddr<[u16; 2]> =
  unsafe { WriteOnlyVolAddr::new(0x0400_0010) };

/// "Background 1 Offset" (Text mode only).
///
/// Given in `[x, y]`.
///
/// Only the lowest 9 bits of each coordinate are used (`0..=511`).
#[cfg(feature = "unsafe_addresses")]
pub const BG1OFS: WriteOnlyVolAddr<[u16; 2]> =
  unsafe { WriteOnlyVolAddr::new(0x0400_0014) };

/// "Background 0 Offset" (Text mode only).
///
/// Given in `[x, y]`.
///
/// Only the lowest 9 bits of each coordinate are used (`0..=511`).
#[cfg(feature = "unsafe_addresses")]
pub const BG2OFS: WriteOnlyVolAddr<[u16; 2]> =
  unsafe { WriteOnlyVolAddr::new(0x0400_0018) };

/// "Background 0 Offset" (Text mode only).
///
/// Given in `[x, y]`.
///
/// Only the lowest 9 bits of each coordinate are used (`0..=511`).
#[cfg(feature = "unsafe_addresses")]
pub const BG3OFS: WriteOnlyVolAddr<[u16; 2]> =
  unsafe { WriteOnlyVolAddr::new(0x0400_001C) };

//