I've had a request to display the current song BPM in NTRQ and was wondering if anyone had a clever way of doing it.
I can't do a simple calculation based on the tick speed (number of frames per tick) because with the Speed Table it's possible to get those "in between" speeds by quickly alternating between two different tick speeds.
I was thinking of something along the lines of keeping two counters, one that's updated every frame (screen refresh rate) and another that gets updated every "tick". Then performing a calculation using the ration of one counter vs the other, which should give me something to work with.
Sounds like a bit of a nightmare in 6502 assembly though
Any thoughts?
I can't do a simple calculation based on the tick speed (number of frames per tick) because with the Speed Table it's possible to get those "in between" speeds by quickly alternating between two different tick speeds.
I was thinking of something along the lines of keeping two counters, one that's updated every frame (screen refresh rate) and another that gets updated every "tick". Then performing a calculation using the ration of one counter vs the other, which should give me something to work with.
Sounds like a bit of a nightmare in 6502 assembly though
Any thoughts?