Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GCMemcard: Rename unknown field to m_dtv_status #8895

Merged
merged 1 commit into from Oct 21, 2020

Conversation

sepalani
Copy link
Contributor

@sepalani sepalani commented Jun 24, 2020

This PR renames an unknown field based on the register value it uses (see YAGCD).

This value is set in the __CARDFormatRegionAsync function. I don't know if the old comments still apply.

Ready to reviewed.

@@ -1568,11 +1568,9 @@ void InitializeHeaderData(HeaderData* data, const CardFlashId& flash_id, u16 siz
}
data->m_sram_bias = rtc_bias;
data->m_sram_language = sram_language;
// TODO: determine the purpose of m_unknown_2
// TODO: determine the purpose of m_dtv_status
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this comment still necessary (or rather; something we could/should address here?) with the revalation that it appears to be the dtv status (guessing: component cable attached?)

Although it seems a bit odd that it would store that in the memory card; especially with the comment below that setting this flag only works for slot A.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I said I don't know if this old comment still apply. I'm almost certain that at least two of my GC games store the u16 value (promoted into u32) from 0xCC00206E (which happens to be VI DTV status register aka _viReg[55]). I can provide screenshots of the disassembled __CARDFormatRegionAsync function if needed.

The real question is rather how the testing was done, against which game/region. There is also a big chance that other region related settings might interfere with this one and is the cause of this misunderstanding.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then we should probably still keep that comment :)

@@ -1568,11 +1568,9 @@ void InitializeHeaderData(HeaderData* data, const CardFlashId& flash_id, u16 siz
}
data->m_sram_bias = rtc_bias;
data->m_sram_language = sram_language;
// TODO: determine the purpose of m_unknown_2
// TODO: determine the purpose of m_dtv_status
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then we should probably still keep that comment :)

@leoetlino leoetlino merged commit 7b9a464 into dolphin-emu:master Oct 21, 2020
@sepalani sepalani deleted the card branch October 24, 2020 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants