Where does official SPIN2 store the CLKFREQ these days?
I have a PASM2 video driver that gets a delay value passed in units of microseconds and needs to be converted into clock ticks for a waitx instruction. For this I need to read the current P2 clock frequency and do some calculations.
Do Flexspin and official Parallax SPIN2 now both store the clock frequency in HUBRAM at address $14 or is there some difference here?
If there is a difference what is a good way to detect and handle this in PASM2 so the code can run on both platforms?
Update: just found it, looks like it is still at a different location. So the question becomes what's the best way to differentiate the two platforms so the same code can be used..?
"The current clock frequency, located at LONG[$44]. Initialized with the 'clkfreq_' value."