home .. forth .. misc mail list archive ..

MuP21 programming manual


Dear MISC readers:

I would like to thank Christophe for his nice explanation of the
inner workings of the hardware as well as his advice to our readers.

I dug out a copy of the MuP21 programmers manual to look it over
and see how Greg could have gotten so many things wrong.  I 
wanted to see what it said about such things as control
registers to see if I could figure out why Greg found it so
confusing.

I had forgotten how much good information there is in there.  I
had forgotten how well most of it is documented.  Sure for
every 1000 pieces of information there is one that could
certainly have used another sentance of explanations but
in most cases it would be redundant because in places like
that the answer can usually be found in several other places
in the docuement.  And yes out of the 20,000 or so facts
there there are few that might confuse some folks and
cause them to want to ask questions.  That is easy to do,
ask questions that is.

I think that it covers the hardware very well with beautiful
diagrams and explanations in more detail than a programmer
really needs.  But it is useful to a more complete understanding
as long as it doesn't distract a programmer from dealing 
with what programmers deal with.

There are hundreds of latches, counters, shifter, and things
that could be called hardware registers if you examine the
chip at the transistor level.  This is true of all chips
but when programmers talk about chips they reserve terms
like "registers" to those that are visible to a programmer.

In the past six years I recall two people who got very
confused by this and did not feel that the documentation
told them how to program every "register."  They missed
the point that in the 200 pages of documentation in the
MuP21 programmers manual that there are some pages that
try to give an overview of the hardware.  I thought it
was well serarated to make it easy for a programmer
to understand what they need to know to program the
chip and to understand a little of what goes on on the
inside.

Christophe has had experience with both programming and
with the inner workings of the chips and has worked on
documentation.  It is nice to know that there still are
people who have experience and knowledge about these
chips who are still providing some valid information for
our readers.

I checked the section on control registers visible to
the programmer.  It sure seemed very simple and very
clear.  One control register is visible to a programmer.
It has one bit that turns on video and two bits to select 
the active page in ROM.  Very simple on P21.

One more time I will state that it is as simple as that
and that questions about the interrupt driven circuits
that adjust the values in the memory timing registers
on the fly are questions about things that don't
exist and I could not find anything in the documenation
that anyone could possible read to interpret things
that way.  When someone says that the bug in that circuit
is the fatal flaw on P21 and all other misc chips and
that they proved this by blowing on their chip I 
wonder where they could that idea.  I explained to them
a dozen times that they were talking about stuff that
didn't exist and certainly confusing people who didn't
know anything about the circuitry in these chips.  I
offered other suggestions as to the cause.  They
ignored me and broght there complaint to c.l.f where
of course no one knew anything about the internals of
P21 least along him.  But Greg was the only person
to understand his point of view and insists that I
was just lying back then and that I hadn' sent him
dozens of email patiently trying to explain it to him
before I just had to give up.

Greg has brought this one up again and called me a liar
for trying to explain it to him once again.  Of course
he has also called almost every other person who has
given him any information a liar.  Ting, Soeren,
myself, the dozens of people with actual experience
with these chips are all telling nothing but lies to
Greg in his mind.  I don't like seening sincere 
people trying to help that unruly child called names.

All in all I feel the MuP21 programmers manual third
edition is quite complete and quite accurate.  There
are a few slightly ambigous things on the first
reading but they are all resolved very clearly if
you go through the whole document.  It isn't perfect
but it is far better than 99% of the documentation I
have seen from IBM over the years.

If someone was going to limit themselves to only one
document on MuP21 this would be the one to get.  And
if someone needs generic info on P21 hardware or
software it is the best document.  Of course I had
to ask a few questions of Chuck and Ting that were
not clear, but for the most part that was the
prerelease, release 1 and release 2.  The third
release did include lots of proofreading that I
had donated to Ting on the document.  

The quality is quite high unless someone needs
introductory tutorials to hardware and programming
in the first place.  It never was intended as 
P21 for dummies as others have said and would
not be readable to someone who didn't have some
basic knowledge of hardware and software.  But I
maintain it is quite good and at worst a fraction
of 1% of the info there that might be ambiguous
on first reading.  If you make a few notes on your
first or second reading to your own copy you can
make those ambiguities clear.  The main problem is
that some address are listed as patterns in some
sections and as address in others.  It is pretty
easy to figure out which is which but it would have
made the document more clear if it had been more
consistent on this as well as stating explicitly
where the number or pattern (hardware) perspecting
was the source of certain numbers.  If you find
the same quantity documented twice and the
two things are just the same number with one of
them xored with AAAAAh it really isn't that hard
to figure out which one is the number and which
one is the pattern.  That is about the only
complaint I can really give to the document.

I know we have heard that it is all excrement and all
lies and all worthless recently.  But we have had many
people who found it quite sufficient and very
informative.   It is 10,000 times better and 10,000
times easier with it than with nothing like we had
for the first few years.

But we must remember that even for dummies books are aimed
at a smalll portion of the population.  There are technical
documents, programmer level technical documents, user level
documentation and introductory (for dummies) types of
documentation.  The P21 programmer's manual has a technical
section on the hardware and mostly is a programmer level
technical document.  It is ten time better for those things
than the documentation we all had to deal with from IBM
for twenty years.  It did improve a bit with PCs but
it took people like Peter Norton to translate those documents
so tha more than 1% of PC programmers could read it.  The
original docs from IBM were really really bad and they
were a vast improvement over the way the documented their
mainframes in the old days.

I agree that the ascii diagrams of the timing signals are not
as clear as the ones we normally see in graphic format that
have ten times more detail.  I advised Greg that if they
were not clear to him that he should line them up next to
the diagrams for the memory parts.  He did this and I was
quite supprised that it did make the information much more
clear.  It just so happened that when looking at the
two diagrams he setup next to one another I could toggle
between the two diagrams being superimposed on the same
lines with pageup and pagedown keys in my browser. See
the two diagrams on top of one another did make the info
much clearer I thought.  

It was interesting to see where they overlapped and that
P21's timing matches the memory chips from the edges
that mark the transitions between states and the
places where data is exchanced between the chips.  The
P21 generally had some setup timing phases that
were longer by a few ns than the memories so it would
have to have a complentary part that was a few ns
faster to get the timing diagrams to line up.  I thought
that Greg's expanded documentation of the timing
diagram from the one the manual was very nice and
easier to read than some conventional timing diagrams
that contain so much detail that it is hard to find.

I will also repeat the statement I made to Greg that
the cycle time to fast SRAM and to DRAM are not the same
even if one of the phases of the timing is.  The througput
in DRAM is signifgantly less than with SRAM.  I know
Greg said I was lying as he does for anything that I say
but until he builds a board and shows everyone how
he can cycle the slow chips as fast as the fast chip
I think people need to take it with a grain of salt.
I would be happy to be proven wrong.  If Greg can
demonstrate this it will be of benefit to other people.
But until it is proven I don't think we need to call
the people who have done these experiments and reported
the results names.

I see a document with about 200 pages and about 100 facts on 
each page.  I could not find any information that was 
explicity wrong.  I am sure there are some problems but this
document is one of Ting's most proofread documents and I
think the quality is actually quite high.

Now if someone knows what they want to do with the chip
there may be other useful information in the other 25
related documents.  I suggest that anyone interested in
that level of detail should as Offete for the whole
product list and review the contents of all those
different docuements.  Even if one doesn't buy a $15 
document (the MuP21 programmers manual is one of the
bigger and more expensive Offete documents) one could
find out who has published what and ask the people
who have already worked on the things that one is
interested in about the details.  It is a good source
of contacts for the dozens (as Greg calls them) of
people who have actual experience and knowledge about
this stuff and who have been helpful in answering
other people's questions.

Christophe Lavarenne wrote:
> 
> Greg,
> please, cool: short questions will have more chance to get answers than
> long flames.
> 
> Jeff, to help misc newcomers, who keep asking this question, you may publish
> this mail on UT site, as is or revised if you wish.  I admire your patience.

Well thank you Christophe.  I was told many times over my fourty
years of zen and martial arts that I was one of the most patient
teachers people had seen.  I find it pretty easy to be patient
with people who are sincere and are trying even when their
progress seems unlikely to other people.  People often get
stuck at certain stages of development and they need patience and
understanding to work through their problems. 

Of course these people are sincere and respectful.  I have
something to give them, they have something to give me and
courtesy and respect are a requirement.  In fourty years
I never say anyone so foolish as to begin by spewing insults
and then ask for help in martial arts or spiritual training.
Sincerety, honesty, and respect are all prerequisits to that 
kind of learning.  

I have little patience for hate, obscenity, profanity, lies,
and sociopathic behavior.  I don't think I should.

Jeff Fox