Turbosub had a ROM_COPY declaration with an expression ('ROM_COPY( "main_code", 0x18000 + 0x2000,...) and this simply did not work with the new model. This required changing ROM_* declarations to more resemble how they used to be and to perform the conversion on load.
Air Raid, Street Fight and Dark Mist all basically use very similar video systems (4 layers, 2 of them being ROM based tilemaps, a CLUT prom for each layer which controls colours and transparency handling)
this takes some steps towards allowing a common implementation of it.
This is a redo of the split first submitted in #137, with the following differences:
* The newly refactored rom_entry data structure is used
* I've kept the refactored softlist code in src/emu, in order to defer the mechanical process of moving it
* I've kept includes of softlist[_dev].h out of diimage.h, so that changes to either do not trigger an emu.h recompilation
* Obviously, this goes against the latest master
* Mark lots of things constexpr in attotime and turn macros into functions
* Add base classes for HLE matrix keyboard and buffered RS232 device
* Make generic keyboard/terminal more usable
* Keyboard has configurable typematic delay/rate
* Keyboard has selectable JIS/ANSI layout
* Keyboard handles simultaneous keypresses more intuitively
* Keyboard uses meta to set high bit
* Terminal has configurable auto LF on CR, auto CR on LF and local echo
* Terminal has audible bell
* Untangle Olivetti M20 keyboard from generic_keyboard
* Add notes to Olivetti M20 keyboard emulation
* Make Olivetti M20 keyboard match physical layout
* Untangle RM Nimbus keyboard from generic_keyboard
* Fix natural keyboard mode with RM Nimbus
* Untangle x68k keyboard from generic_keyboard
* Improve x68k key names and mapping
* Improve x68k typematic behaviour
* Untangle QX-10 keyboard from generic_keyboard
* Keep NGEN keyboard barely working
The keyboard should communicate at 1,200 Baud, but due to bugs in the SCC
it's set to 9,600 Baud. The sun4c machines program the Baud rate
generator dividers for the serial ports with 00:0e and the dividers for
the keyboard/mouse ports with 00:7e. Therefore the ratio of Baud rates
should be (0x7e + 2) / (0x0e + 2) = 128 / 16 = 8. However both the RS232
ports and the keyboard/mouse ports run at 9,600 Baud, when the
keyboard/mouse ports should run at 1,200 Baud (which is 1/8 of 9,600 which
matches the ratio of the divider values).
I've artificially limited the rate the keyboard can transmit at to be no
faster than it could at 1,200 Baud using a timer. I can remove this hack
once we get correct SCC divider behaviour.
I attempted to hook up the SCC interrupts to level 12 as specified in the
SPARCstation-1 Programmer's Model in the table on Page 19. No interrupts
seem to be generated, so either I've screwed this up somehow, the Sun
isn't enabling interrupts, or there's another bug in the SCC emulation.
Sorry if I've screwed it up - I won't be offended if someone replaces it
wholesale.
The keyboard receives the reset commands from the Sun and sends back the
self test pass response, but the SCC seems to get a buffer overrun error.
So it appears that the received data isn't being read out. I haven't been
able to work out why.
* .h -> .ipp for things that aren't really headers
* make more stuff in selmenu private
* move the remembered driver/software associated with the snap to the cache object
* start cleaning up constness in datfile manager - it's still a mess of non-const statics