Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve emulation accuracy #22

Open
Amjad50 opened this issue Oct 22, 2024 · 0 comments
Open

Improve emulation accuracy #22

Amjad50 opened this issue Oct 22, 2024 · 0 comments
Labels
emulation-core Core emulation logic enhancement New feature or request

Comments

@Amjad50
Copy link
Owner

Amjad50 commented Oct 22, 2024

Currently, the emulation is done like this:

  • clock APU (audio)
  • clock CPU:
    • if its time to execute instruction, execute it and store how many cycles we should wait
    • if we are still waiting, don't do anything and decrement the wait counter (this is the issue here, as we are grouping several cycles into one and faking accurate cycle emulation
  • clock PPU (picture) 3 times (since its running 3 times cpu speed, it should not run like that and should be executed while cpu is executing

There are some tests to cover accurate emulation.

I have already done that in mizu, it has much more accurate emulation than this and the methods there could be applied here.

@Amjad50 Amjad50 added enhancement New feature or request emulation-core Core emulation logic labels Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
emulation-core Core emulation logic enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant