Commit Graph

157 Commits

Author SHA1 Message Date
profi200 a9fcf853bb
Forgot a newline while changing the default config in previous commit. Fixes #53. 2022-01-05 16:19:46 +01:00
profi200 9756e2eafc
Added configurable scaling. Very hacky implementation because no citro3d and DMA-330 JIT. 2022-01-05 00:01:03 +01:00
profi200 15cf1bffd5
Added per-game config support. Place "romName.ini" in "/3ds/open_agb_firm/saves" to change per-game settings. Currently only saveSlot is configurable.
Updated README.md.
2021-12-21 19:40:16 +01:00
profi200 247cb19cb5
Actually screw the useSaveFolder config. "/3ds/open_agb_firm/saves" is the new location for savegames and future per-game configs.
Added code for savegame slots. Currently not configurable.
2021-12-19 19:27:52 +01:00
profi200 37f3df4a52
Added autoboot. Place "autoboot.txt" in "/3ds/open_agb_firm".
Note: The autoboot path must be a single line starting with "sdmc:/".
2021-12-18 23:45:51 +01:00
profi200 d7baad122a
Renamed a few config options and added a savegame path one (currently non-functional).
Moved config parsing and backlight setup to an earlier location.
Misc changes.
2021-12-18 03:04:25 +01:00
profi200 b09e3a0eee
Bump file browser entry limit to 1000 files and folders. Please note that the real limit is dynamic and depends on file name lengths. Fixes #37. 2021-12-16 18:33:49 +01:00
profi200 2308e59c85 Begin separating oaf into lib and FIRM. Removed unnecessary config.ini file. 2021-11-07 13:55:59 +01:00
HTV04 67f42f764c Re-implement checkSaveOverride
Based on #40
2021-11-07 13:55:59 +01:00
HTV04 1375224a6e Post-review changes 2021-11-07 13:55:59 +01:00
Harrison 83fe7a9961 More finishing touches 2021-11-07 13:55:59 +01:00
Harrison 6899a7a892 Finishing touches 2021-11-07 13:55:59 +01:00
Harrison eee47c5de1 Full gba_db.bin integration and other changes 2021-11-07 13:55:59 +01:00
Harrison 1ad3dcc0ef Changed backlightRange to maxBacklight
See updated README for more details.
2021-11-07 13:55:59 +01:00
Harrison f5b40f1156 Added backlightRange option and changed how backlight limit works
Small commit, but a few big changes:
* Added an "Advanced" section to the config that contains options for advanced users, including a new option, "backlightRange."
  * The backlightRange option changes the backlight limits, and has three different modes (0-2): Recommended, Old 3DS, and New 3DS. The latter two are based on the min and max backlight limits for the normal 3DS mode. See the updated README for more information.
* Revamped how the backlight limit works, not only to work with the new backlightRange option, but also to improve how it works.
  * GFX_setBrightness no longer sets the limit for the backlight setting, completely removing its restrictions. The limit is now handled by open_agb_firm.c, and has a new "minimum" to prevent too low values. A fail-safe for the backlight option has also been implemented to prevent unintended side effects, such as the backlight being set to 0 when it's set to a value above the maximum limit.
* Updated README to reflect changes, among other changes.

Other changes:
* Replace 7Z files in gitignore with ZIP files.
2021-11-07 13:55:59 +01:00
Harrison 675db2942f A ton of changes
* Updated gba_db.bin Builder to v2.1, adding some important fail-safes and fixing some nasty bugs.
* Updated Makefile to create releases as ZIPs instead of 7Zs and include the gba_db.bin file in releases.
* Updated gitignore to allow necessary files for gba_db.bin Builder to be added to the repo, among other changes.
* Moved script and necessary files to a new "tools" folder. The resources folder is now used for files that facilitate releases, such as "safe" versions of gba_db.bin.
* Made a few changes to open_agb_firm.c to prepare for full gba_db.bin integration.
* Updated README to reflect the new changes, among other changes.
2021-11-07 13:55:59 +01:00
Harrison c4f6f3dabe open_agb_firm gba_db.bin Builder v2.0 and other changes
open_agb_firm gba_db.bin Builder:
* Updated to v2.0
* No-Intro DAT support
* Additional entry support
* Entries added/skipped are now output
* Other optimizations

Other changes:
* Remove most overrides in `open_agb_firm.c` to prepare for gba_db.bin
* Add `resources/gba.dat` entry to gitignore
2021-11-07 13:55:59 +01:00
Harrison 167db2f20d Add more exception entries 2021-11-07 13:55:59 +01:00
Harrison 7f3c6762c7 Change brightness limit
Based on GodMode9's brightness limit, 107.

The previous limit was way too dark, especially in sunlight. Even though brightness control hasn't been added yet, I still think it's better to give users the option.
2021-11-07 13:55:59 +01:00
Harrison b972f75adf Add more save type exception entries
Also remove "Confirmed" status from EEPROM types because they all vary between 4k/8k and 64k.
2021-11-07 13:55:59 +01:00
gecko caca936a66 Add homebrew save type overrides (#40) 2021-11-07 13:55:59 +01:00
profi200 a9881d3a32 Added CODEC headset detection/selction reg and bit defines. 2021-11-07 13:55:59 +01:00
profi200 3fe3f2cbba Use performance monitor bit defines in start.s. 2021-11-07 13:55:59 +01:00
profi200 ed91a742f1 Unorganized commit collecting many changes from the last months incoming. Yeah, i should have split this. 2021-11-07 13:55:59 +01:00
profi200 a6756d6115 Converted most I/O reg defines to structs for better optimization. 2021-11-07 13:55:59 +01:00
profi200 d5e3a08f99 Oops. 2021-11-07 13:55:59 +01:00
profi200 c3a1458541 Some cleanup and updates based on recent 3dbrew edits. 2021-11-07 13:55:59 +01:00
profi200 8e5562a9f7 Make scaling easier to configure at compile time. 2021-11-07 13:55:59 +01:00
profi200 f7785c67e8 Added 1:1 scaling support. 2021-11-07 13:55:59 +01:00
profi200 2224e23022 Use SELECT + Y for screenshots.
Bump copyright dates and add missing copyright notices.
2021-11-07 13:55:59 +01:00
profi200 c2a9cde160 SELECT + Y for screenshots to make it harder to accidentally make them.
Include fatfs and inih licenses in release archive.
2021-11-07 13:55:59 +01:00
profi200 bf47990240 Small fixes/cleanup. 2021-11-07 13:55:59 +01:00
profi200 07c489865c Moved lots of code out of main.c/cleanup. 2021-11-07 13:55:59 +01:00
profi200 d709c76b06 Fixed the oversaturation in the output by using a lower gamma. This is roughly tuned for launch day o3DS. If you want the previous colors back set inGamma to 2.2 and outGamma to 1.21.
Make path creation faster in case it already exists.
2021-11-07 13:55:59 +01:00
profi200 9553fcbbdb Use relative paths where possible. 2021-11-07 13:55:59 +01:00
profi200 57844df7fc Added some filter options to the config. 2021-11-07 13:55:59 +01:00
profi200 ac429d2e4b Added basic config file support (thanks to benhoyt for his inih lib). 2021-11-07 13:55:59 +01:00
profi200 f2fb5a62b3 Enabled more debugging techniques by default in debug builds.
Added more Arm intrinsics.
ARM7 stub now waits for REG_VCOUNT == 126 (same as after BIOS intro).
Enable ROM mirroring for all 8 Mbit games instead of just Classic NES Series.
Other misc. changes.
2021-11-07 13:55:59 +01:00
profi200 d5671a39d6 Avoid errors when the last ROM launch dir doesn't exist anymore.
Other small fixes.
2021-11-07 13:55:59 +01:00
profi200 ff8ebb9ff6 Added returning to the last dir a ROM was launched from on next boot. Fixes #21. 2021-11-07 13:55:59 +01:00
profi200 d22a248b40 Some small, unimportant changes. 2021-11-07 13:55:59 +01:00
profi200 b5ab37cb2c Made the file browser sorting a bit faster. 2021-11-07 13:55:59 +01:00
profi200 411aa70b0f Fixed file browser sorting. 2021-11-07 13:55:59 +01:00
profi200 92ddc5e61b Added a basic screenshot feature dumping the GPU input texture by pressing Y. Fixes #19. 2021-11-07 13:55:59 +01:00
profi200 d7cfb126ec Added game database search code (and a debug menu for it).
Mimic ROM "open bus" (not 100% accurate) and ROM mirroring. Fixes #20.
Implemented some useful ARM instruction intrinsics.
2021-11-07 13:55:59 +01:00
profi200 a5ae7762f7 Added a temporary workaround to prevent panics if booted from bootloaders with broken screen init. 2021-11-07 13:55:59 +01:00
profi200 e2c295d784 Use anonymous structs instead of void for public kernel API. 2021-11-07 13:55:59 +01:00
profi200 8a6e9cdac9 More cleanup and bug fixes. 2021-11-07 13:55:59 +01:00
profi200 529c9535f2 Refactor. Moved code outside of the hardware drivers that doesn't belong there. 2021-11-07 13:55:59 +01:00
profi200 794111d802 First public release of my tiny kernel. 2021-11-07 13:55:59 +01:00
profi200 4b7fe6adf0
Fixed MCU events (thanks to @SonoSooS). 2020-08-27 00:01:35 +02:00
profi200 e70f80d408
Changed MCU init code to match the one from mcu module more closely.
More documentation for the color range adjustment and small cleanup.
2020-08-09 23:12:19 +02:00
profi200 83f8a2d1e7
Changed layout for GBA save type db. 2020-08-04 17:00:33 +02:00
profi200 acbd4d0370
Better color conversion from 5 to 8 bit RGB.
Enable sharp interpolated scaling matrix by default. Looks slightly better than AGB_FIRM.
2020-08-04 16:56:33 +02:00
profi200 c510a2e4e4
Added a few more scaling matrices. 2020-07-27 19:24:43 +02:00
profi200 0479586790
Added original AGB_FIRM scaling for now. Bilinear can still be enabled with a few code changes. 2020-07-24 21:36:30 +02:00
profi200 63a3af0cf8
Added better color correction thanks to Extrems and Game Boy Interface Standard Edition.
Fixed the right side of the input texture being filled with garbage causing issues with bilinear scaling (garbage pixel line at the right side).
2020-07-24 01:15:35 +02:00
profi200 592a7f28b3
Moved I2C LCD stuff to its own file and added register docs and defines. 2020-07-23 20:52:58 +02:00
profi200 1882ba8f06
Started work on better save detection. This will take quite a while to get right. 2020-07-15 18:48:21 +02:00
profi200 c57e89fc49
[Filebrowser] Bug fixes. 2020-07-15 18:45:54 +02:00
profi200 309f80f2a7
[Filebrowser] Added basic sorting. 2020-07-11 23:34:00 +02:00
profi200 8f7f10c519
[Filebrowser] Added filtering. 2020-07-11 23:09:01 +02:00
profi200 7c3e572fc5
Don't turn the backlight off on 2DS. 2020-07-04 15:12:08 +02:00
profi200 e34c042abe
Don't ignore power button held events. 2020-07-02 23:28:09 +02:00
profi200 6c4eb107a6
File browser crash fixes. 2020-07-02 23:19:36 +02:00
profi200 7879ce1597
Added a extremely basic and buggy file browser.
More documentation and bug fixes.
2020-07-01 23:55:27 +02:00
profi200 83a4258bc0
Added GPU command lists without dark filter (looks washed out and too bright. Not recommended.). 2020-06-23 15:18:40 +02:00
profi200 fd0ee01abb
Added more registers and documentation.
Added currently unused GBA reset code.
Other small changes.
2020-06-19 17:17:21 +02:00
profi200 c9cd1c6eea
Added override for Goomba Color. 2020-06-18 22:28:49 +02:00
profi200 28756c24df
Fixed some EEPROM save types. 2020-06-17 14:37:43 +02:00
profi200 837d30465e
Properly detect Classic NES Series games save type. Fixes #3. 2020-06-16 16:56:09 +02:00
profi200 cd99d80e42
Detect homebrew and force SRAM save type.
Bug fixes.
2020-06-15 18:59:09 +02:00
profi200 a852083583
Fixed swi in ARM7 stub. Fixes #5. 2020-06-15 02:17:09 +02:00
profi200 4a2e8b0760
Whoops, why did i delete this? 2020-06-14 03:09:17 +02:00
profi200 bc03a06335
Save handling bug fixes. 2020-06-14 03:04:41 +02:00
profi200 ffee972238
Small bug fixes/improvements for previous commit. 2020-06-13 17:33:01 +02:00
profi200 9002291e8a
Basic save type detection based on code from GBARunner2 (thanks Gericom).
Note: Some EEPROM types are definitely broken right now.
2020-06-13 16:13:58 +02:00
profi200 aecbee03e7
Split CFG11 and PDN into separate headers. Also (nearly) completed them.
Reimplemented filesystem access for ARM11.
Moved ROM loading to ARM11.
2020-06-13 00:49:30 +02:00
profi200 4316ad5c85
Bump color quality. Also removes output dithering. 2020-06-08 13:58:14 +02:00
profi200 2e8f7d92a5
Automatically enumerate IPC cmds.
Actually power off bottom screen backlight instead of dimming it to basically off.
2020-06-07 19:50:26 +02:00
profi200 cdeec87351
Lots of small changes related to recent findings.
Some cleanup.
2020-06-06 00:25:10 +02:00
profi200 391bc4d05d
Moved lgy.h to include/hardware.
Define size symbols instead of calculating asm stub size at runtime.
Workaround poor optimization when passing GbaRtc struct by value.
2020-05-31 18:18:26 +02:00
profi200 efefa7b3db
Moved save type selection to ARM11. Save size is now auto calculated. 2020-05-30 15:20:29 +02:00
profi200 237fb25c19
Implemented basic error checking/error messages.
Use single buffering for the console.
Now turns off bottom screen backlight.
2020-05-29 15:54:19 +02:00
profi200 d0194dca50
Lots of small (functionality unrelated) improvements.
The GBA cart emu RTC is now set properly (with the exception of day of week).
2020-05-26 18:44:47 +02:00
profi200 206472e29f
Use Arm terminology for cache functions. 2020-05-22 01:54:29 +02:00
profi200 89a5688155
Assembly code cleanup. 2020-05-22 01:00:38 +02:00
profi200 f2168be00e
Lots of functionality unrelated code cleanup. 2020-05-20 23:25:40 +02:00
profi200 70f518b92f
Moved some GX/LCD regs to their own headers + more reg/bit definitions. 2020-05-17 20:15:43 +02:00
profi200 63f03cd824
Force LgyFb to insert 16 pixels of padding horizontally. Makes tiled output finally work. 2020-05-14 16:27:11 +02:00
profi200 d695e67a80
Small gfx code changes.
Added mGBA's "dark" filter.
2020-05-11 02:15:30 +02:00
profi200 51115a9785
Added Circle-Pad controls. Costs about 30 µs frame time.
Note: No calibration support yet. If your Circle-Pad is in bad shape or came out of the factory with drift this will certainly break.
2020-05-05 23:27:34 +02:00
profi200 dcc21c92ed
Move the timing window for frame rendering to reduze output lag. 2020-05-04 18:25:03 +02:00
profi200 7aeb539266
Added variable framerate code to sync GBA mode and LCD framerate. 2020-05-03 22:43:19 +02:00
profi200 bdcd068856
Added long overdue credits because without them i would still struggle to understand the GPU.
A few small changes. Nothing important.
2020-05-01 21:30:20 +02:00
profi200 9ff4bbf2fd
Get rid of GPU init cmd list. We only need a single write. 2020-04-30 09:16:48 +02:00
profi200 6232c36bce
GPU scaling hype. 2020-04-30 01:34:27 +02:00
profi200 165d9de32a
Restart the LgyFb DMA channel in time. 2020-04-30 00:21:22 +02:00
profi200 8d89bccb63
Display transfer only the screen area where the frame is stored. 2020-04-29 19:54:21 +02:00
profi200 01ec92240b
Finally renders using the GPU but LgyFb tiled output is broken. 2020-04-29 18:50:52 +02:00