From 0c2fc7f5c5b5025d4d0c4d3f7b986934c85da13d Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Sun, 24 Mar 2024 15:32:16 +1100 Subject: [PATCH] DS: Increase thresholds for timer overflow detection --- src/Platform_NDS.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Platform_NDS.c b/src/Platform_NDS.c index 2cf346efb..c431943a6 100644 --- a/src/Platform_NDS.c +++ b/src/Platform_NDS.c @@ -50,7 +50,7 @@ cc_uint64 Stopwatch_ElapsedMicroseconds(cc_uint64 beg, cc_uint64 end) { cc_uint64 Stopwatch_Measure(void) { u32 raw = cpuGetTiming(); // Since counter is only a 32 bit integer, it overflows after a minute or two - if (raw < 0x00100000 && last_raw > 0xFFF00000) { + if (last_raw > 0xF0000000 && raw < 0x10000000) { base_time += 0x100000000ULL; }