GithubHelp home page GithubHelp logo

beta215 / picogb Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sonosoos/picogb

0.0 0.0 0.0 97 KB

Game Boy emulator library for embedded devices

License: GNU Lesser General Public License v2.1

C 99.94% Batchfile 0.06%

picogb's Introduction

PicoGB

A small emulator libraray, which is capable to play Game Boy games, and a limited amount of Game Boy Color games.

PicoGB is designed to be easy to embed, and run as fast as possible, with the least amount of resource usage as possible.

Embedding

See pgb_main.h for all the available functions to use.

The rest of the code has no dependencies, as it's the job of the embedder to implement callback functions not implemented in fabric.c.

Source code layout

Core:

  • microcode.c - actual CPU implementation, dispatches reads and writes (using a cache where possible)
  • mi.c - Memory Interface, currently only contains cache invalidation functions
  • ppu.c - Picture Processing Unit, contains all code regarding graphics, including scanline rendering, interrupts, and IO register handling
  • apu.c - Audio Processing Unit, contains all code regarding sound rendering, including IO register processing
  • fabric.c - IO register processing, and certain callback functions pre-implemented for Game Boy system

Extensions:

  • profi.c - gcc call stack profiler, used to find and optimize away function calls where inlining makes sense
  • lru.c - Last Recently Used cache, used to implement fast ROM bank cache on low-RAM systems (like the RP2040 port)
  • popcounter.h - line drawing algorithm implemented using a shift register

Executable:

  • test/winmain.c - Windows executable, sound doesn't work in wine (causes a hang due to unsupported sample rate)

Ports

  • Windows - see test/winmain.c
  • RP2040 - not publically released yet (available using VGA or SPI display output, broken audio)
  • Playdate - not publically released yet (available using upscaling or not, audio is inaccurate and crashes sometimes)
  • Game Boy Advanced - under construction

License

PicoGB is licensed under the GNU Lesser GPL v2.1, see LICENSE.txt

picogb's People

Contributors

sonosoos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.