Commit Graph

346 Commits

Author SHA1 Message Date
GearsProgress
0577a450da Formatting (again) 2026-10-22 15:04:58 -04:00
GearsProgress
1738b2ebdd Moving libraries into their own folders 2026-10-18 11:27:01 -04:00
GearsProgress
f1e2b62e4a Applying formatting and moving libraries into specific folders 2026-10-18 11:07:35 -04:00
GearsProgress
f1cf11f2cf Final set of bug fixes before release 2026-10-02 12:20:03 -04:00
GearsProgress
99bf032751 Fixing a few more bugs for release 2026-10-01 22:41:04 -04:00
Philippe Symons
8d81cd4758 Fix some compiler warnings in vertical_menu 2026-09-30 17:19:28 +02:00
GearsProgress
4d39ce30d0 Adding entrypoint values 2026-09-29 15:40:06 -04:00
Philippe Symons
11a581061f Fix first_time text entries in payload (untested)
first_time entries would be longer, therefore the reference pointers inside the payload would shift.

To avoid that, we now reserve space for the longest entry, knowing that the texts will get stripped after
the payloads have been generated.

Doing so ensures that the text offsets remain constant, no matter if we're dealing with the first_time or othertimes payload.

This also means we need to take that reservation into account on the PTGB rom side of things of course.
To do so, I created a pair array indicating the first time entries and there non-first_time counterparts.

We'll determine which entry is the longest and ensure we use that length for the offset of the next entry.
2026-09-22 17:10:20 +02:00
Philippe Symons
0e5cf21010 Merge remote-tracking branch 'upstream/release-candidate' into isolate_mystery_gift_builder 2026-09-22 14:15:58 +02:00
GearsProgress
b16f9d9f6e Tightening mystery gift event detection 2026-09-14 16:29:36 -04:00
GearsProgress
4196ede675 Fixing flag palettes 2026-09-14 12:10:06 -04:00
Philippe Symons
afe0b5cc68 Merge remote-tracking branch 'upstream/gameboy-payload-update' into isolate_mystery_gift_builder 2026-09-02 15:06:32 +02:00
GearsProgress
9cd6dc30c3 Updating box graphics and adding Crystal revisions 2026-09-01 18:19:29 -04:00
TimoVM
72355fa4cf include/link_handler.h added version definitions and checksums for English versions of Crystal (v0, v1, vA) 2026-09-01 05:10:53 +02:00
Philippe Symons
db1b83a29b Merge remote-tracking branch 'upstream/gameboy-payload-update' into gears-merge 2026-08-31 13:21:29 +02:00
GearsProgress
608022a80e Improving the link cable connection initialization 2026-08-29 13:23:33 -04:00
GearsProgress
1afb528c73 Re-enabling Dream Dex 2026-08-27 17:51:37 -04:00
GearsProgress
c454b2a6e2 Adding in support for all latin languages and versions 2026-08-22 16:28:29 -04:00
Philippe Symons
75a0028cd2 Merge branch 'bugfix/gb-payload-lockup-on-transfer' into isolate_mystery_gift_builder
and convert PokeBox BEFORE injection (to separate IWRAM consumption)
2026-08-20 13:58:44 +02:00
Philippe Symons
577bb69726 Merge remote-tracking branch 'upstream/gameboy-payload-update' into isolate_mystery_gift_builder 2026-08-11 14:13:06 +02:00
Philippe Symons
7cb96a7215 Eliminate unused fields on rom_data
We may also want to remove them from the ROM_DATA structs that actually get published into tables for PTGB (from within PCCS) later.
2026-08-11 13:58:25 +02:00
Philippe Symons
b8b0dd25e4 Integrate the pregenerated payload into mystery_gift_injector (WIP, untested)
This commit integrates the pregenerated payload into mystery_gift_injector.

It currently hardcodes the English Ruby v1.2 payload for testing purposes though.

The next test I'll have to do is to see if the transfer process works with this specific rom.

If it works, I can start integrating Pi's work in regards to delta patching using BPS.
2026-08-11 13:40:07 +02:00
GearsProgress
91a0acfd4e Updating dummy packet system 2026-08-06 15:06:28 -04:00
GearsProgress
6e69252b42 Fixing secondary payloads 2026-08-04 16:54:20 -04:00
GearsProgress
56b0c5d6ec Adding in debug info for packet talking 2026-08-03 16:52:07 -04:00
GearsProgress
1c946449b5 Adding back in the debug Pokemon data 2026-07-30 10:32:45 -04:00
GearsProgress
927c0b7b7c Merge branch 'release-candidate' into gameboy-payload-update 2026-07-27 17:30:03 -04:00
GearsProgress
f3e63d0c98 Fixing the transferPokemon command 2026-07-03 21:08:52 -04:00
GearsProgress
275120d852 Adding in the GameBoy packet commands 2026-07-03 21:05:00 -04:00
GearsProgress
50b0cdab72 Merge branch 'release-candidate' into gameboy-payload-update 2026-07-02 23:15:18 -04:00
easyaspi314
f3a164076d Cut VRAM usage roughly in half
Memory manufacturers and AAA game studios hate her!

With some clever rearranging, PTGB now uses only 36 KiB of the 64 KiB
BG VRAM. This means the remaining 28 KiB is free to use in the future.

Caveats: The flex tileset must not use more that 6 KiB. There is a check
for it added.

VRAM Map
  06000000 - 06000800 ( 2K): Eternal backdrop and textbox tileset
  06000800 - 06002000 ( 6K): Flex BG tileset
  06002000 - 06002400 ( 2K): BG0: Backdrop tilemap
  06002800 - 06003000 ( 2K): BG1: Flex BG tilemap
  06003000 - 06003800 ( 2K): BG2: Textbox tilemap
  06003800 - 06004000 ( 2K): BG3: Text tilemap
  06004000 -~06009000 (20K): Text rendering bitmap
  06009000 - 06010000 (28K): Free work RAM
  06010000 - 06018000 (32K): Sprite tileset

Additionally:
- Explicitly clear VRAM on boot
- Dirty workaround to fix box drawing buffer overflow.
- Flex backgrounds use a table instead of a huge switch statement
- Textbox tile IDs are now const u16[] instead of int[]
2026-07-02 16:20:19 -04:00
GearsProgress
a0d2d593ed Removing Pokemon_Party 2026-07-02 16:05:47 -04:00
GearsProgress
150a87c59c Working on transfer Pokemon commands 2026-06-29 21:02:59 -04:00
Adri1
141a079111 Adjustments 2026-06-25 04:03:21 +02:00
GearsProgress
84a29e38cc Cleaning up some logic 2026-06-23 15:31:53 -04:00
GearsProgress
c3e30d1313 Continuing to add secondary packets 2026-06-22 00:03:05 -04:00
GearsProgress
3227df35f7 Fixing multi packet talk 2026-06-19 23:27:59 -04:00
GearsProgress
c773b6e9fc Doing some cleanup 2026-06-19 11:13:29 -04:00
GearsProgress
0df1f7203f Adding the soft reset(?) and other commands 2026-06-18 21:18:16 -04:00
GearsProgress
9244fc4082 Adding GBA flag 2026-06-16 20:31:59 -04:00
GearsProgress
f22776f250 Adding in readMemorySection command 2026-06-15 14:22:39 -04:00
TimoVM
3c8ba3c1f1 Merge pull request #147 from TimoVM/gameboy-payload-update
Gameboy payload This update merges CMD_OpenSRAM and CMD_CloseSRAM into the single CMD_ModifySRAMAccess. It also fixes an issue caused by calling CMD_ReloadCurrentBox in gen 2 while the vblank interrupt was still disabled.update
2026-06-12 09:42:59 +02:00
TimoVM
725a7a09c8 Merge branch 'gameboy-payload-update' of https://github.com/TimoVM/Poke_Transporter_GB into gameboy-payload-update 2026-06-12 06:08:19 +02:00
TimoVM
f23e0225bf Merge Open/CloseSRAM into ModifySRAMAccess. 2026-06-12 06:07:14 +02:00
GearsProgress
6118a985d7 Adding automatic payload loading (kinda) 2026-06-11 18:50:23 -04:00
GearsProgress
261d2d8c55 Cleaning up the link handling and preparing for full read chunks (for real this time) 2026-06-10 22:43:16 -04:00
Philippe Symons
0177374f00 Fix broken Write Cbl Data - CART bug.
For some reason, the merge broke the Write Cbl Data - CART functionality in the dbg menu.

The main problem is that writing a whole sector of data and erasing a sector is too slow to do in an IRQ handler.

Fix: Move the actual flash writing process to the main loop by creating a function called handleCartIO().
The IRQ handler writes to global_memory_buffer, and the handleCartIO() copies that
data to a local write buffer while the IRQ may still add more to global_memory_buffer.

Then it modifies the IRQ handlers' offset and moves the data that was appended in between to the start of the buffer all while
the IRQ handler is still appending new bytes.

If we end up at a sector boundary, we also do the erase_sector() call.

This was tested with and without the print link and print packets debug options.
Without the print options enabled, we end up occupying about 20KB on the cartridge save. (for 1st stage only!)

Man, this bug sucked. I rate it 1 star!
2026-06-08 23:01:31 +02:00
GearsProgress
075dbfd162 Merge branch 'gameboy-payload-update' into pr/risingPhil/141 2026-06-04 23:23:45 -04:00
GearsProgress
e268ccccf5 Basic link packet implementation 2026-06-04 23:12:09 -04:00
Philippe Symons
c9ed32e3a1 Debug option: Write/Load Cable data to/from SRAM
This commit allows you to use the Write Cbl Data debug option and new Load Cbl Data debug option to dump a link's data to SRAM
or load it from SRAM and pretend like you got it over the link cable.

This is useful for capturing the link process on gameboy and replay + debug it later in an emulator.
2026-06-04 15:22:46 +02:00