{"id":15482295,"url":"https://github.com/yushiomote/rgy","last_synced_at":"2025-07-13T07:06:30.226Z","repository":{"id":36504702,"uuid":"158923779","full_name":"YushiOMOTE/rgy","owner":"YushiOMOTE","description":"No-std cross-platform Rust GameBoy emulator library","archived":false,"fork":false,"pushed_at":"2024-10-28T17:24:50.000Z","size":715,"stargazers_count":51,"open_issues_count":10,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-29T21:07:07.369Z","etag":null,"topics":["gameboy-emulator","nostd","rust"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/YushiOMOTE.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-11-24T10:04:35.000Z","updated_at":"2025-03-13T21:07:37.000Z","dependencies_parsed_at":"2024-10-30T19:03:59.383Z","dependency_job_id":"dad41507-ea01-4b83-9a61-9e3028f7458d","html_url":"https://github.com/YushiOMOTE/rgy","commit_stats":{"total_commits":191,"total_committers":3,"mean_commits":"63.666666666666664","dds":"0.015706806282722474","last_synced_commit":"e6a62fbbb8c9f79363f750117ed31aae074479c2"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YushiOMOTE%2Frgy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YushiOMOTE%2Frgy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YushiOMOTE%2Frgy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YushiOMOTE%2Frgy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/YushiOMOTE","download_url":"https://codeload.github.com/YushiOMOTE/rgy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247411239,"owners_count":20934653,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gameboy-emulator","nostd","rust"],"created_at":"2024-10-02T05:08:42.632Z","updated_at":"2025-04-05T23:12:12.838Z","avatar_url":"https://github.com/YushiOMOTE.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rgy\n\nNo-std cross-platform Rust GameBoy emulator library. Rust GameboY (RGY, or Real GaY).\n\n[![Latest version](https://img.shields.io/crates/v/rgy.svg)](https://crates.io/crates/rgy)\n[![Documentation](https://docs.rs/rgy/badge.svg)](https://docs.rs/rgy)\n[![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n[![Actions Status](https://github.com/YushiOMOTE/rgy/workflows/main/badge.svg?branch=master)](https://github.com/YushiOMOTE/rgy/actions)\n\n\u003cimg src=\"https://raw.github.com/wiki/YushiOMOTE/gbr/media/demo.gif\" width=\"450\" /\u003e\n\u003cimg src=\"https://raw.github.com/wiki/YushiOMOTE/gbr/media/demo_screens_2.jpg\" width=\"450\" /\u003e\n\n## Try it on your PC\n\n```\n$ cargo run --example pc \u003ca ROM file\u003e\n```\n\nThe example runs the GameBoy emulator in Mac/Linux/Windows.\n\n### Dependencies\n\nOn Ubuntu, you need to install these packages:\n\n```\n$ sudo apt install libasound2-dev libxcursor-dev libudev-dev\n```\n\n### Key bindings\n\n| Keyboard  | Gamepad      | GameBoy |\n|-----------|--------------|---------|\n| Up / W    | DPad Up      | Up      |\n| Left / A  | DPad Left    | Left    |\n| Down / S  | DPad Down    | Down    |\n| Right / D | DPad Right   | Right   |\n| K / X     | South / East | A       |\n| J / Z     | West / North | B       |\n| Space     | Select       | Select  |\n| Enter     | Start        | Start   |\n| Escape    | -            | Close   |\n\n## Port it to a new environment\n\nThe library itself is environment independent. It can be even ported onto bare-metal. Once you implement environment-specific part, i.e. `Hardware` trait, you will get a GameBoy emulator for your environment.\n\n```rust\nstruct Hardware;\n\n// 1. Implement `rgy::Hardware`.\nimpl rgy::Hardware for Hardware {\n    ...\n}\n\n// 2. Call `rgy::run`.\nfn main() {\n    let cfg = Config::new();\n    let rom = include_bytes!(\"path_to_rom_file.gb\");\n    rgy::run(cfg, \u0026rom, Hardware);\n}\n```\n\n## Emulation Status\n\n* CPU\n    * Supports all the documented instructions.\n    * Emulates accurate read/write timing.\n* Interrupts\n    * Supports all the interrupts.\n    * Emulates halt bug.\n* Graphics\n    * The most features are functioning.\n    * OAM bug is not yet supported.\n* Sound\n    * The most features are functioning.\n    * PCM registers are always emulated for sound tests.\n* Joypad\n* Timer\n* Serial\n* Cartridge (MBC 1,2,3,5, HuC 1)\n* Gameboy Color feature is under development.\n\n## Test Status\n\nTest status of [Blargg's Gameboy hardware test ROMs](https://github.com/retrio/gb-test-roms/tree/c240dd7d700e5c0b00a7bbba52b53e4ee67b5f15)\n\n* [x] `cpu_instrs`\n* [x] `instr_timing`\n* [x] `mem_timing`\n* [x] `mem_timing-2`\n* [ ] `oam_bug`\n* [x] `interrupt_time`\n* [x] `dmg_sound`\n    * [x] `01-registers`\n    * [x] `02-len ctr`\n    * [x] `03-trigger`\n    * [x] `04-sweep`\n    * [x] `05-sweep-details`\n    * [x] `06-overflow on trigger`\n    * [x] `07-len sweep period sync`\n    * [x] `08-len ctr during power`\n    * [x] `09-wave read while on`\n    * [x] `10-wave trigger while on`\n    * [x] `11-regs after power`\n    * [x] `12-wave write while on`\n* [ ] `cgb_sound`\n\nTest status of [Same Suite](https://github.com/YushiOMOTE/SameSuite/tree/430ab7f68fc612e005ed5586990dfec0ea7a9ce5)\n\n* APU\n    * [x] `apu/div_write_trigger.gb`\n    * [x] `apu/div_write_trigger_10.gb`\n    * [x] `apu/div_write_trigger_volume.gb`\n    * [x] `apu/div_write_trigger_volume_10.gb`\n    * [x] `apu/div_trigger_volume_10.gb`\n    * Channel 1\n        * [x] `apu/channel_1/channel_1_delay.gb`\n        * [x] `apu/channel_1/channel_1_duty_delay.gb`\n        * [x] `apu/channel_1/channel_1_freq_change.gb`\n        * [ ] `apu/channel_1/channel_1_align.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_align_cpu.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_duty.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_extra_length_clocking-cgb0B.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_freq_change_timing-A.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_freq_change_timing-cgb0BC.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_freq_change_timing-cgbDE.gb` (CGB double speed)\n        * [ ] `apu/channel_1/channel_1_nrx2_glitch.gb`\n        * [x] `apu/channel_1/channel_1_nrx2_speed_change.gb`\n        * [x] `apu/channel_1/channel_1_restart.gb`\n        * [x] `apu/channel_1/channel_1_restart_nrx2_glitch.gb`\n        * [ ] `apu/channel_1/channel_1_stop_div.gb`\n        * [ ] `apu/channel_1/channel_1_stop_restart.gb`\n        * [ ] `apu/channel_1/channel_1_sweep.gb`\n        * [ ] `apu/channel_1/channel_1_sweep_restart.gb`\n        * [ ] `apu/channel_1/channel_1_sweep_restart_2.gb`\n        * [ ] `apu/channel_1/channel_1_volume.gb`\n        * [ ] `apu/channel_1/channel_1_volume_div.gb`\n    * Channel 4\n        * [x] `apu/channel_4/channel_4_lfsr.gb`\n        * [x] `apu/channel_4/channel_4_lfsr15.gb`\n        * [x] `apu/channel_4/channel_4_lfsr_7_15.gb`\n        * [x] `apu/channel_4/channel_4_lfsr_15_7.gb`\n\n## Projects\n\nThe following projects use this library to run a GameBoy emulator.\n\n* [stickboy](https://github.com/yushiomote/stickboy) runs a GameBoy emulator on Macbook Pro (UEFI).\n* [biboy](https://github.com/yushiomote/biboy) runs a GameBoy emulator on BIOS PC.\n* [waboy](https://github.com/yushiomote/waboy) runs a GameBoy emulator on web browsers (wasm).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyushiomote%2Frgy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyushiomote%2Frgy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyushiomote%2Frgy/lists"}