jsph-tg-rcore-tutorial-user 0.4.14

User-space apps for rCore Tutorial chapters
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#![no_std]
#![no_main]

#[macro_use]
extern crate user_lib;

#[unsafe(no_mangle)]
extern "C" fn main() -> i32 {
    #[cfg(feature = "tangram")]
    {
        let idx: usize = 3;
        println!("[tangram] rendering piece {}: {}", idx, user_lib::tangram::PIECE_NAMES[idx]);
        user_lib::tangram::render_piece(idx);
        user_lib::tangram::spin_wait_ms(300);
    }
    0
}