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
Documentation needs updated for "memory" lua module #1675
Comments
Pretty sure you have to call |
I'm not sure how it was supposed to work before the changes in #538, but currently the documentation here says in multiple places (for the If this is the intended behavior and not a bug, then the documentation seems pretty misleading. |
The default is in fact the system bus (when it exists, which it does for Mupen): |
Well, that partly explains it. This is probably a stupid question, but what exactly is the system bus? Is it basically the unified address space seen by the console's memory mapper (with ROM, RAM, and special addresses all lumped together)? If so, why would a read to a main RAM address fail? Is it because that same block of memory would have a different address when accessed from that mode? |
I took the liberty of adjusting the title to reflect what you determined the real issue here to be. |
memory.read_u32_be(0x0F7450)
kept yielding a value of 4294967296 (the max 32-bit integer?) andmemory.readbyte(0x0F7450)
kept giving 255, which didn't line up with what memory watch was saying.Essentially it appears it's just returning integers of the given size with all bits set to 1.
When I switched from the
memory
to themainmemory
versions of the function, it started behaving normally.In a sense I suppose I was just using the wrong function for the job, using
memory
instead ofmainmemory
on accident.However the documentation for
memory
states thatSo without including the argument to specify a memory domain, the versions should (according to the docs) behave identically. But that's not what's happening, so either the documentation is leaving out something important or else there's some sort of bug here.
Possibly related tickets: #538 #1672
NOTE: I only tested this on N64
The text was updated successfully, but these errors were encountered: