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

Possible issue in Apple ][ system monitor mini-assembler #19

Open
svhum opened this issue Feb 8, 2023 · 1 comment
Open

Possible issue in Apple ][ system monitor mini-assembler #19

svhum opened this issue Feb 8, 2023 · 1 comment

Comments

@svhum
Copy link

svhum commented Feb 8, 2023

In the Apple ][ system monitor port, there are numerous conditional assembly sections for porting to the Apple I, mostly to handle the different hardware. However, I noticed that some of these conditionals may not be working properly (at least, on the hardware I have running the port of the monitor) in the mini-assembler. The first is at at line 136. Here, L6 is called instead of INSDS2, and I am unsure why a different subroutine is needed on Apple I hardware vs. any other 6502 hardware with regards to processing the mnemonic entered from the console. L0 is also called in INSDS1 if APPLE is defined and it's unclear why. In fact, with APPLE1 defined, I'm unable to get the mini-assembler to function properly with some mnemonics compared to the unmodified (Apple II) mini-assembler code, which works fine on my hardware. For example, if APPLE1 is defined, LDA and STA do not get mapped correctly to opcodes by the mini-assembler:

* F666G
!300: LDA #8A
0300-   A7          ???
! STA 88
0301-   17          ???

A7 and 17 are not the correct opcodes for LDA immediate nor STA zero-page, and the mini-assembler is thus confused by the operands. Again the official code (without APPLE1 defined) correctly assembles these commands. Was there something special on the Apple I replica that needed different INSDS1 and INSDS2 routines?

Unless I am missing something, there is also some extraneous code in the mini-assembler conditionally assembled with APPLE1 defined on lines 266-261, which occur before MINIASM, which I do not think ever gets called.

I gather the Apple I port of the monitor was originally done by someone else, so I understand you may not have direct rationale for these changes. Thanks!

@jefftranter
Copy link
Owner

There could certainly be bugs in the code and extraneous code at the end. As I did not write it (and there is no original source code for the port), I can't answer the reasons for these changes. When I get a chance I will fire up my Apple 1 replica and look into it further.
I did notice that the link to the original files had moved so I have corrected it in the README.txt file.

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

No branches or pull requests

2 participants