basic emu skeleton and loop, CALL instruction & rel16 addr mode

This commit is contained in:
2021-02-11 06:29:57 -08:00
parent 1c15695c4b
commit 639e05edac
6 changed files with 260 additions and 1 deletions

14
src/bin/run88.rs Normal file
View File

@@ -0,0 +1,14 @@
use std::io::Read;
extern crate vrtue;
use vrtue::emu::pc::PC;
fn main() -> Result<(), std::io::Error> {
let filename = std::env::args().nth(1).expect("Need filename argument");
let mut file = Vec::new();
std::fs::File::open(filename)?.read_to_end(&mut file)?;
let mut pc = PC::new_with_com_file(&file);
pc.run();
println!("{:?}", pc);
Ok(())
}