From 09104524ed468442bb4957d24e65395955b59ddd Mon Sep 17 00:00:00 2001 From: Astatin Date: Thu, 29 Aug 2024 22:32:10 +0900 Subject: I FINALLY COMMITTED IT ! AND YOU WILL HAVE NO GIT HISTORY BC IT'S TO HARD NOT TO DOX MYSELF --- src/consts.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/consts.rs (limited to 'src/consts.rs') diff --git a/src/consts.rs b/src/consts.rs new file mode 100644 index 0000000..dd06796 --- /dev/null +++ b/src/consts.rs @@ -0,0 +1,12 @@ +pub const PROGRAM_START_ADDRESS: u16 = 0x0; +pub const STACK_START_ADDRESS: u16 = 0x0; + +pub const SPEEDUP_FACTOR: f64 = 1.0; + +pub const DISPLAY_UPDATE_RATE: u64 = 60; // Hertz +pub const DISPLAY_UPDATE_SLEEP_TIME_MICROS: u64 = + ((1000000 / DISPLAY_UPDATE_RATE) as f64 / SPEEDUP_FACTOR) as u64; + +pub const CPU_CLOCK_SPEED: u64 = 4_194_304; +pub const CPU_CYCLE_LENGTH_NANOS: u64 = + ((1_000_000_000 / CPU_CLOCK_SPEED) as f64 / SPEEDUP_FACTOR) as u64; -- cgit v1.2.3-70-g09d2