Skip to content
Snippets Groups Projects
Verified Commit 03844f5d authored by João Magalhães's avatar João Magalhães :rocket:
Browse files

feat: new loading of rom

parent e13d9bcc
No related branches found
No related tags found
1 merge request!2Support for diagnostics text
use chip_ahoyto::{chip8::Chip8, util::read_file};
use time::Instant;
const CYCLE_COUNT: u64 = 10_000_000_000;
const CYCLE_COUNT: u64 = 1_000_000_000;
fn main() {
let rom = read_file("./resources/pong.ch8");
let rom_path = "./resources/pong.ch8";
let rom = read_file(rom_path);
let mut chip8 = Chip8::new();
chip8.reset_hard();
......@@ -14,7 +15,7 @@ fn main() {
let cycles = CYCLE_COUNT;
println!("Running {} cycles", cycles);
println!("Running {} cycles for {}", cycles, rom_path);
for _ in 0..CYCLE_COUNT {
chip8.tick();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment