Closed GXTX closed 2 years ago
Looks pretty good, tested on my 1.6 with stock clocks and didnt break anything. Got this output:
input freq : 233338Hz
num : 58334
den : 7812
timer freq : 31248Hz
Output matches the original hardcoded value of ~31.25Mhz
Thanks for the review. ^
Closing due to lack of MIT consent.
The code is taken directly from Linux, I cannot re-license Linux.
Could be rewritten to simplify fractions using a GCD, or you can find a source for fraction simplification using this algorithm to ensure it's factual / non-copyrightable (while also providing a second source).
I think it is already factual, although I don't fully understand the choice of the constant 32 and 5.
Fixes #536
With the release of software based overclocks, and hardware modding becoming more popular I think pbkit should support any given frequency just as XDK does. A stock Xbox will run fine at ~250MHz and as low as ~25MHz.