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

Implement Cartridge Loading #16

Merged
merged 10 commits into from Apr 22, 2018
Merged

Implement Cartridge Loading #16

merged 10 commits into from Apr 22, 2018

Conversation

sajattack
Copy link
Contributor

It's only working with 8K cartridges right now. I'm starting to wonder if there's a problem with the bank switching code. I've tried setting memory.basic_on to false and writing 54 to memory location $0001 and in both cases basic still starts up.

@kondrak
Copy link
Owner

kondrak commented Apr 16, 2018

It's possible there's a bug, though I remember testing the emulator with some prgs that specifically disabled Basic and it worked fine. Have you tried running the emulator with the debugger window? Are all the flag statuses reported correctly?

@sajattack
Copy link
Contributor Author

sajattack commented Apr 16, 2018

The other possibility is that something in the boot rom that runs after I'm loading the cartridge is re-enabling basic.

Edit: This appears to be the case. I suppose I have to model exrom and game in memory and change the update_memory_latch() function to read them.

@sajattack
Copy link
Contributor Author

sajattack commented Apr 17, 2018

Ultimax carts (which are included in the "normal" category of the cartridge header but are far from normal), are halting in the 0xf000-0xffff range

@sajattack
Copy link
Contributor Author

Should I just error if I detect an Ultimax cart and call it a day?

@kondrak
Copy link
Owner

kondrak commented Apr 22, 2018

I'm not familiar with Ultimax carts but since they are "abnormal" I'd just leave it for now. If it halts (ie. you get a HLT instruction) chances are it's a bug in the CPU emulation somewhere.

Copy link
Owner

@kondrak kondrak left a comment

Choose a reason for hiding this comment

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

Thanks for your work!

@kondrak kondrak merged commit 4922d3b into kondrak:master Apr 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants