On Monday 22 January 2001 18:02, you wrote:
> > But then no comment could include an "=" character.
>
> Why not? Let's suppose someone writes a line like that:
>
> -- I thought Machine=MSX2 but actually it is MSX2+
>
> The parser would read the line and extract two strings:
>
> Tag="-- I thought Machine"
> Value="MSX2 but actually it is MSX2+"
>
> It will then search for "-- I thought Machine" in the list of
> valid tags. When it does not find it, it will just ignore the entire line.
> As you can see, equal signs can be safely used inside comments, as long as
> you place some identifier in the beginning of line, such as ";" , "//" ,
> "--" or any other one.
You are right, it is possible. But we would still have to document which
characters can and cannot be at the start of a keyword. I think a single
comment style would be simpler.
> > We would limit the choice of characters to lower case latin and digits.
> > Note that we're talking about the game ID here, the name field can have
> > SJIS characters, that's no problem because it's never used as a filename
> > or in a URL.
>
> That's ok to me, but the database manager will need a japanese
> translator from time to time, to help design the six-letter acronym
> for the game. In the case I mentioned earlier, it could be "yumeta",
> but "jpgame" would not be acceptable.
That's also the case for the file names, so it is not a problem specific to
using a string for the game ID.
> I think every ROM cartridge should have generic mapper
> description. For instance,
>
> Name="Antartic Adventure"
> Banksize=16
> Initial[4000]=0
Agreed.
> > Super Lode Runner writes to #0000
> > in slot 0, not in the cartridge slot. But the cartridge does switch banks
> > on such a write, because it ignores the slot select signal. So writing to
> > #0000 in any slot is a write to the mapper register.
>
> We could add a flag in the register field:
>
> Register[*0000]=8000
>
> A "*" next to a register address means this particular address
> does not process the slot select signal.
OK.
> What about defining three levels of optionals?
>
> We could make three tags, "Required", "Optional" and "Extra".
> Required means the game will not run without it. Optional means
> new features are enabled with this hardware. Extra means no new features
> are enabled, but game improves performance. This syntax also makes
> the tag "Machine" obsolete:
>
> Name="Nemesis 3"
> Required=MSX
> Optional=SCC
> Optional=MSX2
And also 'Optional=GM2' for Game Master 2. However, I do feel that SCC is
more needed than the other two, so it seems wrong to have them in the same
level. For one, SCC is part of the Nemesis 3 cartridge, so the real thing
cannot be run without SCC.
> > (about Register[8000-87FF])
> > Should we allow any range, or just ranges that can be formed using a
> > bitmask?
>
> Since we allowed Banksize=1, then we should allow any possible
> range too. The reason is the same: we never know which strange cartridges
> are out there.
We allowed Banksize=1 mainly because there was no cost involved. We're not
allowing Banksize=3 because powers of two are easier to handle than arbitrary
bank sizes.
There is always the theoretical possibility of a cartridge that cannot be
described using the generalized mapper. The only way to avoid that, is to
make the mapper description as powerful as a programming language (more
exact: as a Turing machine). We don't want that, we want a simple and fast
algorithm. So we have limit our attention to a certain class of possible
mappers.
> > I think those are the only ones used in hardware and they're probably
> > faster to implement. We could even modify the syntax accordingly:
> > Register[5000/07FF]=XX
>
> I think the syntax Register[5000-57FF] is easier to read.
> The emulator should be able to get the bitmask from the range assigned,
> an easy task, since all it need to do is (57FF)-(5000)=07FF.
> Human readness is key here, we should make syntax easier for the human,
> and not for the machine.
The "5000-57FF" notation is easier to read, but it's not equivalent to the
"5000/07FF" notation. For example, what if I want to express "1234-5678".
That cannot be solved using a single "addr/mask" pair. It can be decomposed
into multiple "addr/mask" pairs, but that would be a rather long list:
"1234/0003" | "1238/0007" | "1240/003F" | "1280/007F" | "1300/00FF" etc.
> > And should we allow that a single mapper register is accessed through two
> > separate ranges? For example:
> > Register[7000]=7000
> > Register[8000]=7000
>
> I see no problem with that. An alternate syntax could be:
>
> Register[7000,8000]=7000
>
> And we could even allow trickier syntax...
>
> Register[7000,8000-87FF,*9000]=7000
>
> ... which means there is a register in 7000, lots
> of registers in the range 8000-87FF, and a register at 9000 who
> does not process slot select.
Multiple access methods to a single mapper register is a rare thing, I don't
think we have to create special syntax to make its notation shorter.
Bye,
Maarten
--
For info, see http://www.stack.nl/~wynke/MSX/listinfo.html