2022-11-05 09:17:49 +11:00
|
|
|
#![no_std]
|
|
|
|
#![no_main]
|
|
|
|
|
|
|
|
use gba::prelude::*;
|
|
|
|
|
|
|
|
#[panic_handler]
|
|
|
|
fn panic_handler(_: &core::panic::PanicInfo) -> ! {
|
|
|
|
loop {}
|
|
|
|
}
|
|
|
|
|
2022-12-02 13:13:31 +11:00
|
|
|
//#[inline(always)]
|
2022-11-05 09:17:49 +11:00
|
|
|
#[instruction_set(arm::a32)]
|
|
|
|
fn make_3rd_bg_pal_entry_black() {
|
2022-12-02 13:13:31 +11:00
|
|
|
let x: u16;
|
|
|
|
unsafe { core::arch::asm!("movs {}, #0", out(reg) x) };
|
|
|
|
BG_PALETTE.index(3).write(Color(x));
|
2022-11-05 09:17:49 +11:00
|
|
|
}
|
|
|
|
|
|
|
|
#[no_mangle]
|
2022-12-02 13:13:31 +11:00
|
|
|
#[instruction_set(arm::t32)]
|
2022-11-05 09:17:49 +11:00
|
|
|
extern "C" fn main() -> ! {
|
|
|
|
make_3rd_bg_pal_entry_black();
|
|
|
|
loop {}
|
|
|
|
}
|