Metadata-Version: 2.4
Name: cartridge-sdk
Version: 1.1.0
Summary: GBA SDK — build tool for Game Boy Advance
Author-email: Lukas Soigneux <lukas.soigneux@epitech.eu>
License-Expression: MIT
Keywords: GBA,Game Boy,GameBoy Advance,Cartridge
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: click
Requires-Dist: Pillow
Requires-Dist: pipx
Dynamic: license-file

<div align="center">
  <a href="https://github.com/lukas-sgx/">
    <img src="https://github.com/lukas-sgx/GBA-sdk/blob/main/assets/gba-logo.png?raw=true" alt="Logo" height="180" style="border-radius: 10px">
  </a>

  <h3 align="center">GameBoy Advance - SDK</h3>

  [![PyPI version](https://img.shields.io/pypi/v/cartridge-sdk?style=for-the-badge)](https://pypi.org/project/cartridge-sdk/)
  [![Build Status](https://img.shields.io/github/actions/workflow/status/lukas-sgx/GBA-sdk/ci.yml?style=for-the-badge)](https://github.com/lukas-sgx/GBA-sdk/actions)

  <p align="center">
    A Software Development Kit for developers who want to build GameBoy Advance games.
    <br />
    <a href="https://github.com/lukas-sgx/GBA-sdk/tree/main/docs"><strong>Explore the docs »</strong></a>
    <br />
    <br />
    <a href="https://github.com/lukas-sgx/GBA-sdk">View Demo</a>
    &middot;
    <a href="https://github.com/lukas-sgx/GBA-sdk/issues/new?template=bug-report.yml">Report Bug</a>
    &middot;
    <a href="https://github.com/lukas-sgx/GBA-sdk/issues/new?template=feature-request.yml">Request Feature</a>
  </p>
</div>

<details>
  <summary>Table of Contents</summary>
  <ol>
    <li>
      <a href="#about-the-project">About The Project</a>
      <ul>
        <li><a href="#built-with">Built With</a></li>
      </ul>
    </li>
    <li>
      <a href="#getting-started">Getting Started</a>
      <ul>
        <li><a href="#prerequisites">Prerequisites</a></li>
        <li><a href="#installation">Installation</a></li>
      </ul>
    </li>
    <li><a href="#usage">Usage</a></li>
    <li><a href="#roadmap">Roadmap</a></li>
    <li><a href="#contributing">Contributing</a></li>
    <li><a href="#license">License</a></li>
    <li><a href="#contact">Contact</a></li>
    <li><a href="#acknowledgments">Acknowledgments</a></li>
  </ol>
</details>

## About The Project

This SDK aims to simplify GameBoy Advance homebrew development by allowing developers to write game logic in Python. It handles the underlying compilation, asset conversion, and bindings to interface efficiently with the GBA hardware.

### Built With

[![Python][Python-shield]][Python-url]
[![C][C-shield]][C-url]
[![Assembly][ASM-shield]][ASM-url]
[![CMake][CMake-shield]][CMake-url]
[![Linker Script][LinkerScript-shield]][LinkerScript-url]

## Getting Started

To get a local copy up and running, follow these simple steps.

### Prerequisites

You need Python 3.x installed on your system

### Installation

#### Development mode (clone the repo, with local changes)
1. Clone the repo
```sh
git clone https://github.com/lukas-sgx/GBA-sdk.git
cd GBA-sdk
```
2. Install the SDK in development mode
```sh
pip install -e .
```

#### Release mode (stable version from PyPI)
```sh
pip install cartridge-sdk
```
## Usage

Here is a quick example of how to dump header of ROM:
```sh
$ cartridge-sdk hdr dump bin/ExampleGBA.gba
bin/ExampleGBA.gba:
|-- entry
|   |-- valid: True
|   |-- raw: 0xea00002e
|   `-- opcode: b 0xc0
|-- nintendo logo:
|   |-- status: True
|   `-- debugging: True
|-- game title: EXAMPLEGBA
|-- game code:
|   |-- code: BXXE
|   |-- date: 2003.. (new)
|   `-- language: USA/English
|-- marker code:
|   |-- id: 01
|   `-- developer: Nintendo
|-- fixed value: valid (96h)
|-- unit code: 00h
|-- device type: 00h
|-- reserved: valid
|-- software_ver: 00h
`-- checksum:
    |-- valid: True
    |-- rom: e3
    `-- our: e3
```

*For more advanced examples, please refer to the [Documentation](https://github.com/lukas-sgx/GBA-sdk/tree/main/docs).*


## Roadmap

- [x] Automated header checker `.gba` ROM
- [x] Automated compilation to `.gba` ROM
- [x] Font asset pipeline (PNG to C file converter)
- [ ] Core GBA bindings (Video, Audio, Inputs)
- [ ] Asset pipeline (PNG to GBA sprite palette converter)

See the [open issues](https://github.com/lukas-sgx/GBA-sdk/issues) for a full list of proposed features (and known issues), and [CHANGELOG.md](./CHANGELOG.md) for release history.

## Contributing

Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.

See [CONTRIBUTING.md](./CONTRIBUTING.md) for setup instructions, commit conventions, and the PR process.

### Top contributors:

<a href="https://github.com/lukas-sgx/GBA-sdk/graphs/contributors">
  <img src="https://contrib.rocks/image?repo=lukas-sgx/GBA-sdk" alt="contrib.rocks image" />
</a>

## License

Distributed under the MIT License. See [LICENSE](./LICENSE) for more information.

## Contact

Lukas Soigneux - lukas.soigneux@epitech.eu

## Acknowledgments

* [GBATEK](https://mgba-emu.github.io/gbatek/) - GameBoy Advance Technical Info
* [Ayyboy-Advance](https://github.com/YannMagnin/ayyboy-advance) - Great emulator for testing

[Python-shield]: https://img.shields.io/badge/Python-3776AB?style=for-the-badge&logo=python&logoColor=white
[Python-url]: https://www.python.org/
[C-shield]: https://img.shields.io/badge/C-005895?style=for-the-badge&logo=c&logoColor=white
[C-url]: https://www.c-language.org/
[ASM-shield]: https://img.shields.io/badge/-Assembly-bf7805?style=for-the-badge&logo=arm&logoColor=white
[ASM-url]: https://developer.arm.com/
[CMake-shield]: https://img.shields.io/badge/-CMake-064F8C?style=for-the-badge&logo=cmake&logoColor=white
[CMake-url]: https://cmake.org/
[LinkerScript-shield]: https://img.shields.io/badge/-Linker%20Script-A42E2B?style=for-the-badge&logo=gnu&logoColor=white
[LinkerScript-url]: https://sourceware.org/binutils/docs/ld/Scripts.html
