|
ForumsSega Master System / Mark III / Game GearSG-1000 / SC-3000 / SF-7000 / OMV |
Home - Forums - Games - Scans - Maps - Cheats - Credits Music - Videos - Development - Hacks - Translations - Homebrew |
Author | Message |
---|---|
|
Can the Everdrive mess up TV type detection?
Posted: Tue Feb 06, 2024 5:57 pm
|
I made a little program for the upcoming competition and I encountered a strange bug I don’t really know what to make of.
When I test it on real hardware via Master Everdrive X7, the TV type detection seems to fail. The program runs in 50 Hz mode even though the system runs at 60 Hz, so everything is going too fast. On the other hand, the same program works absolutely fine in Emulicious and also on the Mega SG hardware. I can’t rule out that it’s my Master System, as that was originally a PAL machine that’s now permanently stuck in 60 Hz mode after a botched attempt at installing a switch. However, I used the exact same detection routine in Flight of Pigarus and that have always the correct results. Any thoughts or ideas? |
|
|
Posted: Tue Feb 06, 2024 6:05 pm |
Hi,
I also have an everdrive X7 with a modded Master System 2 PALto switch from 50 to 60hz. Did you use the Master System region detection to perform your test ?[/url] If you have a code example, I might be able to take a look and test it on my own. |
|
|
Posted: Wed Feb 07, 2024 8:22 am |
No, in this case I use this code. I’ve also used the exact same code in the past, both in Flight of Pigarus and in my WIP Mermaid game, and it has never failed me in either. Hence my question if maybe the Everdrive writes something to System RAM. The byte that stores the TV type information is located at $C000, right at the beginning of RAM. In the other two games, it’s positioned somewhere else. |
|
|
Posted: Wed Feb 07, 2024 8:57 am |
I wouldn't expect it to disrupt your RAM, but... did you try moving that byte in some other place? | |
|
Posted: Wed Feb 07, 2024 3:07 pm |
I perform a test myself, with the everdrive X7 on a SMS 2, and I can confirm that the TVTypeDection code is working well.
I can switch from 50 to 60hz and the code detects the change. You can also try to use sverx's SMS Test Suite ROM too. |
|
|
Posted: Wed Feb 07, 2024 4:08 pm |
but the Test Suite uses a completely different approach to detecting if it's 50 or 60 Hz, not 'cycle count' based but detecting the vcount 'roll-back' count. |
|
|
Posted: Wed Feb 07, 2024 6:22 pm |
ah right, I admit I didn't look at how the test was carried out. For my part, here's what I used. I just draw a 0 or a 1 on the screen depending on the result. |
|
|
Posted: Thu Feb 08, 2024 6:27 am |
Problem solved, nothing to see here. It was human failure after all. Console, Everdrive and detection code are all working as they should. Turns out it was just me being stupid.
Apparently, I accidentally commented out a di, which in turn messed up the detection. It’s actually weird it even worked in Emulicious and on the Mega SG in the first place. |
|
|
Posted: Thu Feb 08, 2024 6:55 am |
Not saying that is the case, but....
The last time I was scratching my head why some ROM was working on emulicious and was not working on the everdrive, the root cause was....that I didn't copy it to the sd and I was testing the wrong one! |
|
|
Posted: Thu Feb 08, 2024 8:23 am |
Interesting! I suspect the difference could be that the Master EverDrive leaves the interrupts enabled before starting the ROM while the others might start that with interrupts disabled. In either case, never assume any previous status, always set some initial setting yourself. |
|