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

Apple II DeskTop's triggering DHR Mono mode fails #153

Open
inexorabletash opened this issue Aug 22, 2022 · 2 comments
Open

Apple II DeskTop's triggering DHR Mono mode fails #153

inexorabletash opened this issue Aug 22, 2022 · 2 comments

Comments

@inexorabletash
Copy link

Per https://github.com/whscullin/apple2js/#updates-2017-08-31 and looking at the monoDHRMode flag in the code, DHR mono should be supported. But Apple II DeskTop fails to trigger it in apple2js, although it works on real hardware, MAME, and AppleWin.

Repro:

(1) Use an Incognito/Private Browsing window to ensure you don't have saved mono color settings
(2) Launch: https://www.scullinsteel.com/apple//e?accelerator_toggle=true#https://a2desktop.s3.amazonaws.com/lkg.2mg

Expected:

  • Desktop appears in 560BW / Mono-DHR mode

Actual:

  • Ugly colors :(

Additional repro:

  • Once Desktop is loaded, open the Sample.Media folder and double-click on the Monarch image. If the AppleColor RGB modes are handled correctly, this should appear in color. Tap space to toggle color/B&W - this might be the easiest place to debug the transitions. Hitting Esc to return to Desktop should return to B&W mode again.

If it helps, the triggering sequence used to enter DHR mono is:

    sta $C00C ; CLR80VID - set register to 0
    sta $C05E ; AN3 off
    sta $C05F ; AN3 on - shift 0 in as first bit
    sta $C05E ; AN3 off
    sta $C05F ; AN3 on - shift 0 in as second bit
    sta $C00D ; SET80VID - enable 80-column hardware
    sta $C05E ; AN3 off - enable DHIRES

And the toggle to DHR color is:

    sta $C00D ; SET80VID - set register to 1
    sta $C05E ; AN3 off
    sta $C05F ; AN3 on - shift 1 in as first bit
    sta $C05E ; AN3 off
    sta $C05F ; AN3 on - shift 1 in as second bit
    sta $C05E ; AN3 off - enable DHIRES

I see the code handling an3 toggles and shifting in the mode bit, but I didn't debug.

@whscullin
Copy link
Owner

So... this is complicated. There are two renderers - the original, currently not default renderer, handles modes supported by the AppleColor 100 card, like 560x192 B&W mode and the whacky 160x192 16 color mode. The current default is the GL NTSC shader from Open Emulator, which replicates what comes out of the back of the machine's RCA video connector, which did not support DHGR B&W mode. You can switch between the two with the gl_canvas=true|false URL parameter.

I could make the NTSC shader replicate the DHR mono mode, emulating manually clicking the mono button on an Apple NTSC monitor and probably nobody would cry foul.

@inexorabletash
Copy link
Author

Ah, thanks. Well, as you note I can tweak the URL I'm using (and have done so). The "real fix" would probably be to allow the user to select the monitor type (RGB or NTSC), but that's feature creep and incredibly niche - and also basically what turning off the GL renderer does; just rebrand the feature? I kinda like the "mono button" idea as that's how I experienced B&W mode back-in-the-day or today with my Laser 128, but I don't want you do do it on my account, as long as the alternate renderer sticks around. I'm fine with you closing this issue out - or at least renaming something more specific if you want it as a tracking bug.

Thanks again!

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