[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: new Applicard



On Dec 17, 7:10 am, Steven Hirsch <snhir...@gmail.com> wrote:
>
> Alex, I'm a little confused as to why the end state of a non-booted Applicard
> is of concern.  I believe that the host Apple invokes a hardware reset by
> writing to a port, then proceeds to boot the operating system.

True. Access to $C0x5 resets the z80 and it loops waiting for input
from the 6502.
According to the OEM manual if no such input is detected in about 2
minutes, the
z80 proceeds to a self-test routine that is supposed to increment a
value written
to the output port a few times a second.

I know the basic functionality of my clone is correct: I can read/
write and execute
short programs on the z80 from the 6502's side. I also know something
is NOT right
as it doesn't boot CP/M. So I'm hoping that the diagnostics self-test
can tell me
what exactly is wrong. If I know how to interpret the results.


>  They don't
> operate in a vacuum waiting for something spontaneous to occur.  For a certain
> amount of time after boot, the Applicard is in a mode where the bootstrap can
> take place.

Yes. And this works at least to some extent. As I said I can execute a
simple test and
most if not all of the CP/M ends up in the z80 memory. I just need to
figure out some
subtle thing that my clone is not doing right.

>
> IIRC, it loads part of the CP/M image into the Z80 memory and writes to a port
> that banks out the ROM and replaces it with RAM before transferring control to
> the bootstrap code.

Yes. Both things do happen.

>
> > 1. Any idea what the diagnostic code stuck at $42 means?
>
> No, and I'm not sure why it matters.

Because diagnostic code is designed to detect problems and I have a
problem.

>
> The best advice I can offer (since I'm not a hardware guru) is to carefully
> review the Applicard schematic to ensure that you've actually modeled it
> completely and correctly.  Sounds like something fundamental is missing, but I
> do not know what off the cuff.

It may be something fundamental or something subtle. For example a
read from
C4xx (assuming slot  4) should read a byte from z80 but not reset the
flag. This
is not documented but appears to be so from the schematics. I did
duplicate this
even though I have no idea if it is ever used. There may be other
things like this.

The best way to find a problem is to trace the code execution and find
the place
where it doesn't do the expected thing. Unfortunately this is not easy
without
either the source or an operational board to compare with.

Thanks to you pieces of code are becoming available so I think I'll
find the problem
eventually.


>
> I used to know the entire flow like the back of my hand, but it's been over 20
> years and details are fuzzy.  Last week I unearthed a box of documentation and
> printouts and will try to make time over the holidays to refresh my memory.  I
> may be confusing the CardZ180 with the Applicard in some aspects and don't
> want to lead you down a wild goose chase.

Any information and any code fragments are very welcome.

>
> The cold boot code for the Applicard would probably help greatly if I can dig
> it up.

Oh, yeah!

-Alex.