Hacking New Theme for EZ-Flash Omega!

PolarisVoid

Member
Newcomer
Joined
Jul 28, 2021
Messages
5
Trophies
0
Age
24
XP
59
Country
United States
I'm not sure if this is where I should be asking about it, so forgive me if what I'm looking for is somewhat tangential. So I've had my omega cart for about a year now, love it, and the coder in me is very impressed by the pogoshell plugins' ability to handle so many filetypes! That said, I'm not a very experienced developer, I've mostly been spending time on the Arduboy forum. However, no one over there is experienced with GBA development, let alone pogoshell, which is why I posit this question here.

Dream of dreams would be being able to play pre-compiled arduboy games (which are arduino code compiled as a .hex file, the arduboy equivalent of a .gba more or less) on the GBA using the omega cart. With how many systems pogoshell plugins are able to handle already, I was wondering if anyone was savvy to how one might go about writing a plugin of their own. In this case, specifically, a plugin that could handle the .hex files and emulate an ATMEGA32u4 accordingly. If anyone thinks they could crack this themselves, though, please be my guest! I have very little (absolutely none) experience in coding emulators, so you're much more likely to succeed if this sounds appealing to you!
 

Sterophonick

Stupid Retro Tech Cat
OP
Member
Joined
Jul 17, 2018
Messages
560
Trophies
0
Location
Spamton's Keygen Dungeon
Website
sterophonick.github.io
XP
2,216
Country
United States
I'm not sure if this is where I should be asking about it, so forgive me if what I'm looking for is somewhat tangential. So I've had my omega cart for about a year now, love it, and the coder in me is very impressed by the pogoshell plugins' ability to handle so many filetypes! That said, I'm not a very experienced developer, I've mostly been spending time on the Arduboy forum. However, no one over there is experienced with GBA development, let alone pogoshell, which is why I posit this question here.

Dream of dreams would be being able to play pre-compiled arduboy games (which are arduino code compiled as a .hex file, the arduboy equivalent of a .gba more or less) on the GBA using the omega cart. With how many systems pogoshell plugins are able to handle already, I was wondering if anyone was savvy to how one might go about writing a plugin of their own. In this case, specifically, a plugin that could handle the .hex files and emulate an ATMEGA32u4 accordingly. If anyone thinks they could crack this themselves, though, please be my guest! I have very little (absolutely none) experience in coding emulators, so you're much more likely to succeed if this sounds appealing to you!

I know nothing about the ATMEGA32u4, but I can say that there is a pointer to the loaded file data located at 0x203FBFC, towards the end of EWRAM.
 
  • Like
Reactions: PolarisVoid

PolarisVoid

Member
Newcomer
Joined
Jul 28, 2021
Messages
5
Trophies
0
Age
24
XP
59
Country
United States
So the way the arduboy controls its interfaces (screen, speaker, led) is through PWM, as the 32u4 has a number of pins and timers available for this. The screen for the arduboy is just a 128x64 monochrome oled, most games run at a preset 60 fps, with a lot of games much slower as the framerate doesn't need to be very high for them. I was able to find a decent datasheet listing all it's features:

• High Performance, Low Power AVR® 8-Bit Microcontroller
• Advanced RISC Architecture
– 135 Powerful Instructions – Most Single Clock Cycle Execution
– 32 x 8 General Purpose Working Registers
– Fully Static Operation
– Up to 16 MIPS Throughput at 16MHz
– On-Chip 2-cycle Multiplier
• Non-volatile Program and Data Memories
– 16/32KB of In-System Self-Programmable Flash
– 1.25/2.5KB Internal SRAM
– 512Bytes/1KB Internal EEPROM
– Write/Erase Cycles: 10,000 Flash/100,000 EEPROM
– Data retention: 20 years at 85C/ 100 years at 25C(1)
– Optional Boot Code Section with Independent Lock Bits
In-System Programming by On-chip Boot Program
True Read-While-Write Operation
Parts using external XTAL clock are pre-programed with a default USB bootloader
– Programming Lock for Software Security
• JTAG (IEEE® std. 1149.1 compliant) Interface
– Boundary-scan Capabilities According to the JTAG Standard
– Extensive On-chip Debug Support
– Programming of Flash, EEPROM, Fuses, and Lock Bits through the JTAG Interface
• USB 2.0 Full-speed/Low Speed Device Module with Interrupt on Transfer Completion
– Complies fully with Universal Serial Bus Specification Rev 2.0
– Supports data transfer rates up to 12Mbit/s and 1.5Mbit/s
– Endpoint 0 for Control Transfers: up to 64-bytes
– Six Programmable Endpoints with IN or Out Directions and with Bulk, Interrupt or
Isochronous Transfers
– Configurable Endpoints size up to 256 bytes in double bank mode
– Fully independent 832 bytes USB DPRAM for endpoint memory allocation
– Suspend/Resume Interrupts
– CPU Reset possible on USB Bus Reset detection
– 48MHz from PLL for Full-speed Bus Operation
– USB Bus Connection/Disconnection on Microcontroller Request
– Crystal-less operation for Low Speed mode
• Peripheral Features
– On-chip PLL for USB and High Speed Timer: 32 up to 96MHz operation
– One 8-bit Timer/Counter with Separate Prescaler and Compare Mode
ATmega16U4/ATmega32U4
8-bit Microcontroller with 16/32K bytes of ISP Flash and
USB Controller
DATASHEET SUMMARY
ATmega16U4/32U4 [DATASHEET]
Atmel-7766JS-USB-ATmega16U4/32U4-Datasheet_04/2016
2
– Two 16-bit Timer/Counter with Separate Prescaler, Compare- and Capture Mode
– One 10-bit High-Speed Timer/Counter with PLL (64MHz) and Compare Mode
– Four 8-bit PWM Channels
– Four PWM Channels with Programmable Resolution from 2 to 16 Bits
– Six PWM Channels for High Speed Operation, with Programmable Resolution from 2 to 11 Bits
– Output Compare Modulator
– 12-channels, 10-bit ADC (features Differential Channels with Programmable Gain)
– Programmable Serial USART with Hardware Flow Control
– Master/Slave SPI Serial Interface
– Byte Oriented 2-wire Serial Interface
– Programmable Watchdog Timer with Separate On-chip Oscillator
– On-chip Analog Comparator
– Interrupt and Wake-up on Pin Change
– On-chip Temperature Sensor
• Special Microcontroller Features
– Power-on Reset and Programmable Brown-out Detection
– Internal 8MHz Calibrated Oscillator
– Internal clock prescaler and On-the-fly Clock Switching (Int RC / Ext Osc)
– External and Internal Interrupt Sources
– Six Sleep Modes: Idle, ADC Noise Reduction, Power-save, Power-down, Standby, and Extended Standby
• I/O and Packages
– All I/O combine CMOS outputs and LVTTL inputs
– 26 Programmable I/O Lines
– 44-lead TQFP Package, 10x10mm
– 44-lead QFN Package, 7x7mm
• Operating Voltages
– 2.7 - 5.5V
• Operating temperature
– Industrial (-40°C to +85°C)
• Maximum Frequency
– 8MHz at 2.7V - Industrial range
– 16MHz at 4.5V - Industrial rang


I'm not sure writing an entire ATMEGA32u4 emulator would be possible on the gba, and if not, I'm confident the arduboy API could be ported over, so that games could be compiled from source code. I'd say a good 98% of arduboy games are open-source and available on github. The code is all arduino C/C++ code, and the API isn't all too complicated either, it's been ported to a few other systems already.
 

Androxilogin

New Member
Newbie
Joined
Aug 20, 2021
Messages
4
Trophies
0
Age
37
XP
49
Country
United States
Is there any possibility of allowing the GB/GBC emulators to use a stretched display or even scaled/borderless like the Game Gear emulator can do? It drives me nuts! For a screen this small, stretched out sprites and things wouldn't bother me whatsoever, I'd much rather have a full screen.
 

Shadow#1

Wii, 3DS Softmod & Dumpster Diving Expert
Member
Joined
Nov 21, 2005
Messages
12,354
Trophies
2
XP
8,016
Country
United States
Is there any possibility of allowing the GB/GBC emulators to use a stretched display or even scaled/borderless like the Game Gear emulator can do? It drives me nuts! For a screen this small, stretched out sprites and things wouldn't bother me whatsoever, I'd much rather have a full screen.
NOPE NOT AT ALL
 

Sterophonick

Stupid Retro Tech Cat
OP
Member
Joined
Jul 17, 2018
Messages
560
Trophies
0
Location
Spamton's Keygen Dungeon
Website
sterophonick.github.io
XP
2,216
Country
United States
NOPE NOT AT ALL

Shadow, seriously, enough with the attitude. The dude was asking a question. If the only answer you can think of is a rude one then just pipe down.

Is there any possibility of allowing the GB/GBC emulators to use a stretched display or even scaled/borderless like the Game Gear emulator can do? It drives me nuts! For a screen this small, stretched out sprites and things wouldn't bother me whatsoever, I'd much rather have a full screen.

Unfortunately that doesn't seem like much of a possibility. It was done in GBC mode because there was integrated scaling hardware, it's why it looks a little fuzzy. GBC game compatibility in this flashcart is done in software emulation, and as such, there are limitations, especially on more embedded systems such as the GBA. Perhaps a borderless mode is possible but I don't see much demand for it (and I'm bad at coding).
 

eikichi09

Member
Newcomer
Joined
Aug 2, 2018
Messages
11
Trophies
0
Age
30
XP
258
Country
Belgium
Hi all, is there a way to implement a pixel grid option on gba games for people like me who're playing with ips screen but miss the pixel filter like original screen.

Thanks !
 

Localhorst86

Robert'); DROP TABLE members;--
Member
Joined
Jul 17, 2014
Messages
2,741
Trophies
1
Location
Nintendo works for my dad
XP
5,367
Country
Germany
Hi all, is there a way to implement a pixel grid option on gba games for people like me who're playing with ips screen but miss the pixel filter like original screen.

Thanks !
Probably not on the flashcard. The pixel grid on the original GBA comes from the physical distance between the pixels on the screen.

As far as I understand (I am using AGS-101 screens in my GBAs so I could be wrong) the IPS ktis do not have the native GBA resolution (240x160) but an integer multiple of that or if they have the native resolution, their pixels are probably larger and therefore the physical spacing is less/not visible.

If it's the later (native resolution with larger pixels), there is probably nothing one can do at all. If it's the first (the screen being higher resolution) the screen manufacturers could - potentially - include such a feature in their screen controller by blanking certain rows and columns of pixels, but the screen would need to be considerably higher resolution for the blanked pixels to be "fine enough" to mimic the original pixel spacing.
 
Last edited by Localhorst86,

hippy dave

BBMB
Member
Joined
Apr 30, 2012
Messages
9,889
Trophies
2
XP
29,417
Country
United Kingdom
I think I've seen newer IPS screen versions on AliExpress with options for scan lines etc. (Edit: I just looked, couldn't see it easily actually, but there's screens for GBC with "retro pixel grid" option which must be what I was thinking of. Maybe they'd need a higher resolution screen to do it for GBA.) Definitely can't be done by software on the GBA/flash cart tho, the console can only produce pixels at the original resolution, with no room for details in between.
 
Last edited by hippy dave,

eikichi09

Member
Newcomer
Joined
Aug 2, 2018
Messages
11
Trophies
0
Age
30
XP
258
Country
Belgium
Too bad that this is not possible.
I really like my ips screen but everything has a too "smooth" look that the pixel grid corrected on the original screen.

In any case, thank's for the answers and clarifications!
 

Androxilogin

New Member
Newbie
Joined
Aug 20, 2021
Messages
4
Trophies
0
Age
37
XP
49
Country
United States
Shadow, seriously, enough with the attitude. The dude was asking a question. If the only answer you can think of is a rude one then just pipe down.



Unfortunately that doesn't seem like much of a possibility. It was done in GBC mode because there was integrated scaling hardware, it's why it looks a little fuzzy. GBC game compatibility in this flashcart is done in software emulation, and as such, there are limitations, especially on more embedded systems such as the GBA. Perhaps a borderless mode is possible but I don't see much demand for it (and I'm bad at coding).

Hey, thanks for the response. I wasn't notified so I was unaware. As for the other guy- frig off. I'm new to this console but well integrated in many other communities.

I was looking for the original Omega source code so I assume you're waiting on the same to update from their kernel 1.09 update. Props to you! Your firmware is awesome.
 
  • Like
Reactions: Sterophonick

Levine91

Well-Known Member
Member
Joined
Oct 8, 2011
Messages
183
Trophies
1
XP
1,036
Country
United States
I apologize for sounding stupid but I'm also new to this particular scene.
I have an Omega DE in route, so I'm trying to plan ahead here.

If I am wanting to use SimpleDE, what exactly will I be missing out on?
I ask that as it sounds like SimpleDE won't ever be updated in comparison to the stock firmware & kernel, correct?
 

WeeFlats

New Member
Newbie
Joined
Oct 8, 2017
Messages
3
Trophies
0
Age
42
XP
75
Country
United Kingdom
I just got my EZ Flash Omega and I love Simple, but I can't get any ZX Spectrum games to load at all, I just get a white screen. I have tried dozens of different Z80 files but nothing works at all, any ideas? SMS, GG, MS, GB & GBC games all work fine.
 
  • Like
Reactions: AceyBwoi

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Xdqwerty @ Xdqwerty: @BakerMan, hi