Skip to content

Use VBlank interrupt in unbricked examples#191

Open
zhangsan1890 wants to merge 1 commit into
gbdev:masterfrom
zhangsan1890:fix-unbricked-vblank-interrupt
Open

Use VBlank interrupt in unbricked examples#191
zhangsan1890 wants to merge 1 commit into
gbdev:masterfrom
zhangsan1890:fix-unbricked-vblank-interrupt

Conversation

@zhangsan1890
Copy link
Copy Markdown

Fixes #157.

This updates the unbricked examples to use the VBlank interrupt for frame timing instead of polling rLY in the main loop.

Changes:

  • add a VBlank interrupt handler and WaitForVBlank helper to the affected examples
  • enable VBlank interrupts during initialization
  • keep serial interrupt handling working in the serial-link examples by enabling both Serial and VBlank interrupts

Verification:

  • git diff --check
  • checked there are no remaining WaitVBlank2 / .wait_vblank_* main-loop polling patterns in unbricked examples
  • bash unbricked/build_all.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unbricked doesn't use the VBlank interrupt

1 participant