BurritOS/src/main.rs

16 lines
341 B
Rust
Raw Normal View History

2022-10-19 16:39:38 +02:00
mod decode;
mod print;
2022-11-09 15:59:05 +01:00
mod machine;
2022-11-09 17:35:16 +01:00
use machine::Machine;
2022-10-19 16:39:38 +02:00
2022-10-05 16:30:21 +02:00
fn main() {
2022-11-09 17:35:16 +01:00
let mut m = Machine::_init_machine();
2022-11-23 18:04:35 +01:00
m.main_memory[4] = 43;
m.main_memory[5] = 150;
let a : u8 = 128;
let b : i8 = a as i8;
let c : u8 = b as u8;
println!("aaa {}", c);
println!("read_memory : {}", Machine::read_memory(&mut m, 2, 4));
2022-10-05 16:30:21 +02:00
}