Skip to content

Commit

Permalink
Read that ROM
Browse files Browse the repository at this point in the history
  • Loading branch information
IsaacMarovitz committed Nov 13, 2023
1 parent 9a79332 commit 5fe7cfe
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
use std::fs::File;
use std::io::Read;
use winit::{event_loop::EventLoop, window::WindowBuilder};
use clap::{Parser};

Expand All @@ -10,6 +12,12 @@ struct Args {

fn main() -> Result<(), impl std::error::Error> {
let args = Args::parse();
let mut file = File::open(args.rom_path).expect("No ROM found!");
let mut buffer = Vec::new();

file.read_to_end(&mut buffer).expect("Failed to read ROM!");

println!("{:#04X?}", buffer);

let event_loop = EventLoop::new().unwrap();

Expand Down

0 comments on commit 5fe7cfe

Please sign in to comment.