----------------------------------
K4 16-bit Digital Synthesizer [DBWBP]
New clones marked as NOT_WORKING
--------------------------------
K4r 16-bit Digital Synthesizer Module [DBWBP]
* gcm394 / paccon - use screen resolution to determine tilemap limits nstead of hardcoding it (nw)
* debugging (nw)
* tweaks to video (nw)
* new NOT WORKING
----
Super Game 36-in-1 (TimeTop SuperGame) [JP_Ronny, TeamEurope]
(actually seems playable, but there are some details I want to verify / figure out before promoting it)
* map 'X' for timetp36 (nw)
* extra io notes (nw)
* confirm difficulty mapping (nw)
* set to PAL timings (nw)
* new NOT WORKING
----
Digi Makeover (Girl Tech) [Sean Riddle, Clawgrip]
* move digimakeover to its own driver (nw)
* hack to force IRQ on (nw)
* alt mode for rad_digi (nw)
* some buton notes (nw)
* flips for rallyx (nw)
* make some IRQ code closer to spg2xx (nw)
* improve raster for Xevious (nw)
* no macro (nw)
* new NOT WORKING
----
Gormiti Game Arena (Spain) [Sean Riddle, Clawgrip]
* new NOT WORKING
----
MobiGo (Spain) [Sean Riddle, Clawgrip]
* don't use smartfp inputs (nw)
- com8116: Delete SY2661-1/-2 tables (these are just second sources of SCN2661A/B)
- mc2661: Remove obsolete device
- rs232: Remove 7200 baud setting formerly required by one driver to work around incorrect table
visualiser device and WDL FFT libarary).
I changed the VGM visualiser to use single-precision float which is the
default for WDL FFT. GCC's loop vectoriser can make better use of SSE
with single-precision maths, and the extra precision shouldn't be needed
for the visualisation. If this is a problem, let me know and I'll
revert this and flip the WDL FFT library over the other way.
(nw) The pcap.h header itself has the problematic original BSD license,
including the obnoxious advertising clause. Using tap/tun networking on
Windows provides a much better experience, so the extra setup is worth
it. This patch also allows you to enable pcap on platforms where it's
disabled by default with USE_PCAP=1 if you really want to use it.
* Removed empty nl_examples from dist.mak
* Added copyright acknowledgements and full text of licenses to binary distribution
* Fixed up the list of third-party libraries
* Moved WDL fft.c to 3rdparty
* hp80: added HP82939 serial I/O module.
Fixed a small bug in INS8250 that prevented module self-test to pass.
Improved the interrupt handling of hp80 systems.
* hp80: changed scheduling to use "set_perfect_quantum"
* set discpal to correct machine type (nw)
* moew skannerz tv to its own driver and add notes from Tahg [Tahg]
* buzztime IO notes from Tahg [Tahg]
* new NOT WORKING
----
Pac-Man Connect & Play (Feb 14 2012 10:46:23) [Sean Riddle, David Haywood]
boots and you can select things from the menu but this is the newer SP SoC and needs a LOT of work on the graphics.
This tool was previously used to generate HTML-formatted source for
the website from releases. It hasn't been used in years, since we
rely on the repository browsing features of GitHub/GitLab/SourceForge.
It also hasn't been updated to handle C++14, Lua, and other changes to
the source. If we do want to publish source code on our own web site
in the future, we'd be better off using an off-the-shelf library to
handle parsing the source.
----------------------------------
Korg M1 Music Workstation (Rev 19) [DBWBP]
New clones marked as NOT_WORKING
--------------------------------
M1 EX Music Workstation (v1.29) [DBWBP]
M1R Music Workstation (v1.06) [DBWBP]
M1R EX Music Workstation (v1.12) [DBWBP]
M1 Plus+1 Music Workstation [DBWBP]
-spg2xx_io: Converted from magic register indices to enumerated values. Added SPI logging. [Ryan Holtz]
-spg2xx_jakks: Split into separate game-key, plain, and touch drivers. [Ryan Holtz]
-jak_batm: Hooked up I2C EEPROM to enable saving. [Ryan Holtz]
* new WORKING machine
-----
Retro Dance Mat (110 song Super StepMania + 9-in-1 games) (PAL) [TeamEurope, David Haywood]
* new NOT WORKING
---
Lexibook Retro TV Game Console - 300 Games [TeamEurope, David Haywood]
My Arcade Retro Arcade Machine - 300 Handheld Video Games (DGUN-2593) [TeamEurope, David Haywood]
* swap painball powered up dump for a better one, previous reads weren't 100% consistent, they are now, changes verified to be correct (nw)
* notes from Sean (nw)
* rename these bits, they're not system specific (nw)
----------------------------------
Roland D-50 (Ver. 2.xx) [DBWBP, depblue]
New NOT_WORKING clones
----------------------
Roland D-50 (Ver. 1.xx) [DBWBP]
Roland D-550 [DBWBP]
Add disassembler for NEC 78K/III architecture [AJR]
* new WORKING machines
----
Guitar Super Star (Fender Stratocaster style) [Sean Riddle, David Haywood]
* better filename (nw)
* new NOT WORKING
----
Excite Sports Tennis x Fitness (Japan) [Sean Riddle, Peter Wilhelmsen, ShouTime]
* shuffle (nw)
* new NOT WORKING
----
Wikid Joystick [TeamEurope, David Haywood]
* new Software List entries (Mobigo.xml) [TeamEurope]
Rapunzel - Neu Verfohnt (Germany) (80-251704)
Cars 2 (Germany) (80-251904)
Die Pinguine aus Madagascar - Operation Krone (Germany) (80-250304)
Micky Maus - Wunderhaus (Germany) (80-250504)
Ben 10 - UltimateAlien - Mine der Gedanken (Germany) (80-250604)
Dora - Tag des Zwillings (Germany) (80-250804)
Disney Princess (Germany) (80-251104)
Cars Toon - Hooks unglaubliche Geschichten (Germany) (80-251204)
* new Software List entries (telestory_cart.xml) [TeamEurope, David Haywood]
Power Rangers - Mystic Force
Dora the Explorer (Spanish)
* new NOT WORKING
---
TV Touch Games: Star Wars Original Trilogy [Sean Riddle, David Haywood]
* srcclean some of my stuff (nw)
* shuffle (nw)
* shuffle (nw)
* new NOT WORKING
---
Big Buck Hunter Safari (JAKKS Pacific TV Game) [Sean Riddle, David Haywood]
* (nw)
* (nw)
* (nw)
* mc6844.cpp: WIP NEW DEVICE Motorola mc6844 DMA controller (devicified from swtpc09.cpp)
* 6821pia.cpp: improved LOG messages a bit
* mc6854: Added support for external clocks, DMA, improved LOG messages and fine tuning of IRQ handling
* mc6846: Removed nonexistant CP1 output callback and added a CP1 input interface call
* 6850acia.cpp: Updated use of logmacro.h
* alfaskop4110: WIP added keyboard and fixed build errors
* new WORKING machine
---
MGT 20-in-1 TV-Spielekonsole (Germany) [TeamEurope, David Haywood]
* text to follow later (nw)
* (nw)
* (nw)
* (nw)
* (nw)
* new WORKING machines
----
My Sports Challenge (6-in-1 version, QVC license) [Sean Riddle, David Haywood, Ryan Holtz]
Decathlon [Sean Riddle, ClawGrip]
new NOT WORKING
---
Karao Kids Songs 2 (Spain) [Sean Riddle, ClawGrip]
Club Jenna Presents: Jenna Jameson's Strip Poker [Sean Riddle, David Haywood, Ryan Holtz]
Mini Arcade Machine (Red5) [TeamEurope, David Haywood]
Lexibook Compact Cyber Arcade - Disney Princess [TeamEurope, David Haywood]
* added a placeholder for Sean's Casio ROM pack dumps (nw)
* promote the poker game (nw)
* (nw)
* (nw)
* Casio ROM pack details from Clawgrip
* new NOT WORKING
---
Duck Commander (JAKKS Pacific TV Game) [Sean Riddle, David Haywood]
Star Wars Clone Trooper (JAKKS Pacific TV Game) [Sean Riddle, David Haywood]
The Walking Dead: Zombie Hunter (JAKKS Pacific TV Game) [Sean Riddle, David Haywood]
The Walking Dead: Battleground (JAKKS Pacific TV Game) [Sean Riddle]
Toy Story - Toys on the Move (JAKKS Pacific TV Motion Game) [Sean Riddle, Clawgrip]
* new NOT WORKING
----
Teenage Mutant Ninja Turtles: Mutant and Monster Mayhem [Sean Riddle]
* new WORKING machines
----
Plug & Play Game Controller with 200 Games (Supreme 200) [TeamEurope]
healthy dose of obvious unlicensed NES hacks here.. including 1st party Nindendo and Namco games.
* new NOT WORKING
----
MobiGo 2 (Germany) [TeamEurope]
+ start of Sofwtare List [TeamEurope]
* (nw)
* new NOT WORKING
----
Guitar Fever (2007.07.03 Ver 2.7) [TeamEurope, Peter Wilhelmsen, David Haywood]
has timer issues making the music way too slow
* move these (nw)
* new NOT WORKING
----
Atari Flashback Mini 7800 [Sean Riddle, GameHistory.org]
City Patrolman [unknown]
* do fit here (nw)
* new WORKING machine
---
Magic Ranger Battle (Japan) [Sean Riddle, Peter Wilhelmsen, David Haywood, ShouTime]
(at least I think it works, might end up demoted if I discover more issues, as it's a SuperXaviX but only appears to be using the basic IO features and bitmap mode on the XaviX splash screen)
* correct title (nw)
* new NOT WORKING
---
Gamepad (Bandai) [Sean Riddle, GameHistory.org]
* new NOT WORKING
---
Tour around Japan. I'm a Plarail Conductor (Japan) [Sean Riddle, Peter Wilhemsen, David Haywood, ShouTime]
SmarTV Adventures / Funtastic TV Adventures [Sean Riddle, David Haywood]
* new NOT WORKING
---
Super Roller (v7.0) [Hammy]
* inputs are the same (nw)
* document boot password (nw)
* another password (nw)
* new NOT WORKING
----
Fitness Konsole (NC1470) [TeamEurope]
* (nw)
* new NOT WORKING
---
Mega Duck Lerncomputer (Germany) [Sean Riddle]
* new WORKING machines
----
Sports Trivia Professional Edition (Senario, Plug and Play) [Sean Riddle, David Haywood]
My Sports Challenge Plus / Wireless Sports Plus [Sean Riddle, David Haywood]
new NOT WORKING
---
Megapad 31-in-1 [Sean Riddle, GameHistory.org]
the 31-in-1 is playable, except for one game, need to look into that.
* (nw)
* new NOT WORKING Software List entry
-----
buzztime_cart.xml : Series 1 - Sports Trivia [Sean Riddle, David Haywood]
* new WORKING software list entry
jakks_gamekey_nm.xml : Pac-Man & Bosconian (01 APR 2005 A SKU G) [Sean Riddle, Ryan Holtz, David Haywood]
(that's all the known gamekeys covered now)
* sunplus_gcm394 changes from Tahg
(I'll tidy these up shortly to fit MAME standard better)
* refactor (nw)
* refactor (nw)
* (nw)
* (nw)
* some decryption refactor (nw)
- Make second 8355 into ROM expansion slot that can load custom 8755 programs
- Add software list for expansion ROMs, including Peter Naszvadi's version of Mastermind
- Add optional TTY interface
- Improve accuracy of button labels and change key bindings
- Add vectored interrupt and soft reset buttons
- add CD4006 and CD4070 devices
- add TL084 opamp model
- Clock now supports proxies, i.e. can be connected to
analog devices.
- Fixed netlists using CLOCK
- added some comments
- removed a forgotten header file.
* new WORKING machines
----
Vs Maxx Texas Hold'em TV Poker - 6 Player Edition (US) [Sean Riddle, David Haywood]
Deluxe TV Poker - Texas Hold'em, Blackjack & Video Poker (US) [Sean Riddle, David Haywood]
* (nw)
* (nw)
* new WORKING machines
---
TV Sports 10-in-1 / Decathlon Atlhetic Sport Games [TeamEurope, David Haywood]
new NOT WORKING machines
---
Lexibook Compact Cyber Arcade - Frozen [TeamEurope]
* (nw)
* new NOT WORKING
----
Sudoku (Elan type hardware) [Sean Riddle]
* new NOT WORKING
---
Lexibook Compact Cyber Arcade - 250-in-1 (JL2375) [TeamEurope, David Haywood]
* new NOT WORKING
----
Plug and Play Sudoku (VT based) [Sean Riddle, David Haywood]
* (nw)
* new clones
---
Excite Sports Wireless Interactive TV Game - 48-in-1 (set 2, PAL) [TeamEurope]
* (nw)
* (nw)
* new NOT WORKING
----
Who Wants to Be a Millionaire? (Senario, Plug and Play, US) [Sean Riddle, David Haywood]
Big Bonus Slots (Senario, Plug and Play) [Sean Riddle, David Haywood]
Wireless Tennis (WT2000, ABL TV Game) [Sean Riddle, David Haywood]
Millionaire and Big Bonus Slots might be working, just need more test time before I'm sure enough to promote them (nw)
* minor spelling fix
* new NOT_WORKING machine
Gigatron TTL Microcomputer [Sterophonick]
also add a skeleton cpu core
* Revert Minor Spelling Fix
* Make some fixes
thanks cuavas
* Fix resolution
* gigatron: update cpu device name
* update copyright
* fix part of gigatron disassembler
* Set screen refresh rate
* found a set of all the ROM files, update main ROM name
* Fix cpu.lua
* Whoops
* Update gigatron.cpp
* gigatron: clear execute_set_input
* Update gigatron.h
* Update gigatrondasm.cpp
* Update gigatrondasm.h
* clean up but doesnt compile ffs
* new NOT WORKING
---
Power Joy (PJ001, NES based plug & play) [Sean Riddle]
* some notes (nw)
* trying to research banking (nw)
* this code definitely sets the bank, but then it loses it later, needs more investigation, this hacks bank to be correct in all cases for zon32bit to at least verify dump is complete (nw)
* control notes (nw)
* still trying to figure out the banking properly (nw)
* enough banking hacks to at least make sure we always have the correct bank (nw)
* (nw)
* don't bank pdc100 unless upper bits are also set, as it writes 0000 during initialization code, while executing from bank 7, which causes issues with -nodrc and with the either drc or no drc on linux (nw)
* use dump of correct game for pockchalw.xml chukkesr (was previously using duplicate of a different set)
* new NOT WORKING
----
Generations (Retro-Bit) [Porchy]
* (nw)
* new NOT WORKING
---
Tomica Carnavi Drive (Japan) [Sean Riddle, Peter Wilhelmsen, ShouTime]
* fix bgpen (nw)
* new NOT WORKING
----
WiWi 18-in-1 Sports Game [TeamEurope, David Haywood]
TV Virtual Fighter / Free Fight Kung Fu (Conny / Big Ben) [TeamEurope, David Haywood]
* new NOT WORKING
----
Jara-Ja Land (Japan, home version) [Sean Riddle, Peter Wilhelmsen, ShouTime]
* (nw)
* new NOT WORKING machines
-----
Design Master Denshi Mangajuku [TeamEurope]
note, these use a H8/328 (24kbytes internal ROM, 1kbyte internal ROM) but at least when booting from cart it looks like they're using external mode, with internal ROM disabled, as the 'game' cart ROMs contain boot vectors (the 'design' carts don't, but those are data roms for the game carts)
likely needs a proper H8 type deriving tho.
* (nw)
* (nw)
* (nw)
* (nw)
* (nw)
* closer type (correctly has 1k internal RAM)
* banks are 0x8000 in size (nw)
* (notes)
* (nw)
* subclass (nw)
* (nw)
* (nw)
* ooops (nw)
* improve gcslottv mojuotv
* vt1682 work (nw)
* looking at stability (nw)
* new NOT WORKING machines
----
InterAct Complete Video Game - 111 Games & 42 Songs (G5410) [TeamEurope]
Let's Play! Game Machine 240 in 1 [TeamEurope]
new NOT WORKING Software List
----
iqunlim_cart.xml: Englisch für Anfänger [TeamEurope]
the vt1682 based InterAct Complete Video Game is basically playable, apart from the 'Shooting games' because I haven't mapped the guns, and some issues with player 2 / alt control schemes in some titles. want to address these (and maybe look for a better solution to some stability issues) before promoting it.
* (unrelated typo fix for clickstart software list) (nw)
* new WORKING machine
---
MiWi2 7-in-1 Sports [David Shah]
* don't printf (nw)
* new NOT WORKING
----
Lexibook Compact Cyber Arcade - Star Wars [Team Europe]
Unknown M&D Handheld [zhongtiao1]
- hooked up controls for shredmjr, now runs the ame as taikeegr [David Haywood]
* new NOT WORKING
----
BBL380 - 180 in 1 [zhongtiao1]
* (nw)
* unkmandd contains some unsp code (nw)
* same hardware these are not (nw)
* tidy unused (nw)
* comment (nw)
* (nw)
* stuff from Sean, will credit later (nw)
* (nw)
* (nw)
* some more SunPlus stuff with NAND type roms (gpnandnand strings in them, need bootstrap)
* possible hardware names (nw)
* some kind of ARM based GeneralPlus (nw)
* proper names (nw)
* (nw0
* this is some kind of enhanced chipset, not 100% sure it's VT tho (nw)
* new NOT WORKING machines
---
Lexibook JG7425 221-in-1 [TeamEurope]
* comments (nw)
* acknowledge that there is S+Core code in here at least (nw)
* mapping the code from ROM to RAM at 500000 after skipping the first 0x20 bytes means a lot of jumps go to the word after a 'br r3' so is probably where it gets copied to
ioport.cpp:
* better than 50% reduction in compile time, and better locality for static data
* better encapsulation, const correctness and noexcept usage
* vt1682 alu is now a device (nw)
* prepare to make times devices (nw)
* push timer logic into devices (nw)
* naming fixes (nw)
* useful trampoline (nw)
* (nw)
* hmm timer math, I'm not sure about timer math (nw)
* messing with rasters (nw)
* move zone40 to vt1682, while it definitely isn't plain 1682 I think it's more likely closer to it than it is to SunPlus
* When a switch-type input is selected, show feedback when it's pressed
* If an invalid code is entered (e.g. only negatives) abandon the change rather than cycling default/none
* If an invalid code is entered display a message until the user takes some other action
input.cpp updates:
* constexpr crusade on input_code and input_seq and some very slight optimisation to input_seq
* seq_poll* is a frontend function and had no business being in the core, so it's a utility class now
* seq_poll* now exposes a bit more detail, enabling improved interaction on the UI inputs menu
* global state is reduced a little, but the poll_* functions are still members of the input manager with global state
(nw) The Lua engine has been updated in a way that maintains source compatibility with existing Lua
scripts. This is less than ideal, but it minimises impact. Ideally someone (possibly me) will be
able to expose the input sequence poller helper properly. I tested the changes with the cheat and
autofire plugins and I was able to assign sequences. However I found two issues: it's seems
impossible to assign a more complex sequence than a single key/button in the autofire plugin (i.e.
no AND or NOT conditions, I confirmed this is pre-existing, not a regression), and in both the cheat
and autofire plugins I found it a bit unwieldy trying to enter a complex sequence without live
feedback of the sequence as it's built (this was also applicable to MAME's own input mapping menu
until I added the live display yesterday).
* reference table (nw)
* move some machine specific stuff into different class (nw)
* put things behind log macros (nw)
* add in some controls, that work for the 32-in-1 at least (nw)
* note (nw)
* hide excessive logging (nw)
* dma fix for tetris (nw)
* alu work (nw)
* clean up some palettes
* clean up some bitscanning and indentation in olibuchu
* rename machine/epos.cpp to machine/pacman.cpp as it's unrelated to drivers/epos.cpp
* move epos-on-pacman members from pacman_state to derived epospm_state
-sun4.cpp: Various changes: [Ryan Holtz]
* Split sun4 and sun4c hardware emulation into separate derived classes.
* Hooked up Sbus IRQs.
* Removed now-unnecessary duplicate MMU code.
-cgsix.cpp: Added VSync IRQ, cleaned up save state usage, and added THC MISC register. [Ryan Holtz]
-sparc.cpp: Renamed MB86901 to SPARCV7, and added a separate class for SPARCV8. [Ryan Holtz]
-bt45x.cpp: Made logmacro.h usage more consistent. [Ryan Holtz]
* Made DIP switch display scale with UI font and improved layout
* Improved analog control display giving an indication of neutral position
* Fixed menu heading sizes not being recalculated after font is changed
* elan sound stuff (nw)
* move more audio bits into audio file (nw)
* new NOT WORKING machines
-----
Texas Hold'em TV Poker - 6 Player Edition (UK) [David Haywood, Morten Kirkegaard, Peter Wilhelmsen]
need to emulate the controllers etc. (currently requires debug hack to boot past initial logo)
* start moving some more elan stuff around (nw)
* add (non-working) CM-32P driver
* CM-32P: make booting test mode sort of work (nw)
* CM-32P: fix initialization, working test mode (nw)
- test mode now boots properly and shows error report
- test mode can be enabled/disabled
- RCC-CPU check passes
- PCM ROM check passes, PCM card check fails (requires SN-U110-04 card)
* CM-32P: add research notes (nw)
* hp80: refactored optional ROM device as requested in issue #5839
* hp9825: refactored optional ROM device as requested in issue #5839
* hp9845: refactored optional ROM device as requested in issue #5839
- Added slot interface for internal expansion boards.
- Added BBC Master cartridge slot interface to allow implementation of more complex cartridges, including Electron cartridge devices.
- Removed Sideways RAM configuration option, to be re-implemented as internal boards.
- Empty BBC Master cartridge sockets return video data on data bus.
* elan eu3a05 / eu3a14 - identify some common bits (nw)
* some elan refactoring baed on current knowledge / standards (nw)
* elan refactoring (nw)
* elan splitting / refactoring (nw)
* validate (nw)
* note used areas (nw)
* register observations (nw)
* another observation (nw)
* add the sprite double feature (nw)
* rendering tweaks (nw)
* rendering improvements for air blaster 3d stages (nw)
* refactoring (nw)
* galaga: Implement accurate starfield based on reverse eng. 05xx
----------------------------------------------------------------
This commit implements an accurate starfield for Galaga and
Bosconian based on reverse engineering the Namco 05xx chip.
Documentation and notes have been added inline to the code
for the galaga video driver.
Changes in this commit:
1. Regenerates starfield colors based on LFSR state for every frame
2. Pixel accurate to Namco original 05xx
3. Restores one line horizontal starfield shift for every 256
vertical pixel shifts
4. Properly handles LFSR reset (_STARCLR)
5. Restores missing 4 stars from previous implementations
6. Fixes potential issue with the number of stars on screen at any
one time
7. Restores 4 pixel/line scrolling capability (not currently used
for any driver)
* galaga: inplement accurate starfield - change request 1
-------------------------------------------------------
1. Remove stdlib.h from src/mame/video/galaga.cpp
* galaga: inplement accurate starfield - change request 2
-------------------------------------------------------
1. Refactor starfield generator into stand-alone video
device
2. Simplify Bosconian and Galaga video drivers
3. Add in documentation about different LFSR form used
by Wolfgang Scherr and Jindřich Makovička.
* galaga: inplement accurate starfield - change request 3
---------------------------------------------------------
Minor changes from pull request review
--------------------
RS-232 DCE-DCE Bridge
(nw) This is a simple machine for wiring together two things that want
to plug into an RS-232 port. This means that for DCE-like things (e.g.
serial printers) there's no need to create an extra machine to allow
them to talk to the outside world with the null_modem device. (Also
added some asserts, removed a FIXME, and put the swtpc8212 terminal in
the default RS-232 devices.)
* Changed emu_fatalerror to use util::string_format semantics
* Fixed some incorrectly marked up stuff in build scripts
* Make internal layout compression type a scoped enum (only zlib is supported still, but at least the values aren't magic numbers now)
* Fixed memory leaks in Xbox USB
* There can only be one "perfect quantum" device - enforce that only the root machine can set it, as allowing subdevices to will cause weird issues with slot cards overiding it
* Allow multiple devices to set maximum quantum and use the most restrictive one (it's maximum quantum, it would be minimum interleave)
* Got rid of device_slot_card_interface as it wasn't providing value
* Added a helper template to reduce certain kinds of boilerplate in slots/buses
* Cleaned up some particularly bad slot code (plenty more of that to do), and made some slots more idiomatic
This patch gets it running, and splits it into two front ends, one
being a rs232 bus slot so that is can be used as a terminal option. It
adds the MCM66750 character generator, and implements the MC6845 row
update function. Most of the I/O has been worked out with help from
the CT-82 user manual. The various screen formats and the graphics
modes appear to be working and plausible. Printer support has been
added, and a beeper.
- Removed code no longer used
- Add noexcept where appropriate
- split pparser.[c|h] into ppreprocessor and ptokenizer
- smaller optimizations, e.g. use of std::size_t
- fix lint warnings
fundamental change to show device delegates are configured.
Device delegates are now aware of the current device during
configuration and will resolve string tags relative to it. This means
that device delegates need a device to be supplied on construction so
they can find the machine configuration object. There's a
one-dimensional array helper to make it easier to construct arrays of
device delegates with the same owner. (I didn't make an n-dimensional
one because I didn't hit a use case, but it would be a simple addition.)
There's no more bind_relative_to member - just call resolve() like you
would for a devcb. There's also no need to cast nullptr when creating a
late bind device delegate. The flip side is that for an overloaded or
non-capturing lambda you'll need to cast to the desired type.
There is one less conditional branch in the hot path for calls for
delegates bound to a function pointer of member function pointer. This
comes at the cost of one additional unconditional branch in the hot
path for calls to delegates bound to functoids (lambdas, functions that
don't take an object reference, other callable objects). This applies
to all delegates, not just device delegates.
Address spaces will now print an error message if a late bind error is
encountered while installing a handler. This will give the range and
address range, hopefully making it easier to guess which memory map is
faulty.
For the simple case of allowing a device_delegate member to be
configured, use a member like this:
template <typename... T> void set_foo(T &&...args) { m_foo_cb.set(std::forward<T>(args)...); }
For a case where different delegates need to be used depending on the
function signature, see src/emu/screen.h (the screen update function
setters).
Device delegates now take a target specification and function pointer.
The target may be:
* Target omitted, implying the current device being configured. This
can only be used during configuration. It will work as long as the
current device is not removed/replaced.
* A tag string relative to the current device being configured. This
can only be used during configuration. It will not be callable until
.resolve() is called. It will work as long as the current device is
not removed/replaced.
* A device finder (required_device/optional_device). The delegate will
late bind to the current target of the device finder. It will not
be callable until .resolve() is called. It will work properly if the
target device is replaced, as long as the device finder's base object
isn't removed/replaced.
* A reference to an object. It will be callable immediately. It will
work as long as the target object is not removed/replaced.
The target types and restrictions are pretty similar to what you already
have on object finders and devcb, so it shouldn't cause any surprises.
Note that dereferencing a device finder will changes the effect. To
illustrate this:
...
required_device<some_device> m_dev;
...
m_dev(*this, "dev")
...
// will late bind to "dev" relative to *this
// will work if "dev" hasn't been created yet or is replaced later
// won't work if *this is removed/replaced
// won't be callable until resolve() is called
cb1.set(m_dev, FUNC(some_device::w));
...
// will bind to current target of m_dev
// will not work if m_dev is not resolved
// will not work if "dev" is replaced later
// will be callable immediately
cb2.set(*m_dev, FUNC(some_device::w));
...
The order of the target and name has been reversed for functoids
(lambdas and other callable objects). This allows the NAME macro to
be used on lambdas and functoids. For example:
foo.set_something(NAME([this] (u8 data) { m_something = data; }));
I realise the diagnostic messages get ugly if you use NAME on a large
lambda. You can still give a literal name, you just have to place it
after the lambda rather than before. This is uglier, but it's
intentional. I'm trying to drive developers away from a certain style.
While it's nice that you can put half the driver code in the memory map,
it detracts from readability. It's hard to visualise the memory range
mappings if the memory map functions are punctuated by large lambdas.
There's also slightly higher overhead for calling a delegate bound to a
functoid.
If the code is prettier for trivial lambdas but uglier for non-trivial
lambdas in address maps, it will hopefully steer people away from
putting non-trivial lambdas in memory maps.
There were some devices that were converted from using plain delegates
without adding bind_relative_to calls. I fixed some of them (e.g.
LaserDisc) but I probably missed some. These will likely crash on
unresolved delegate calls.
There are some devices that reset delegates at configuration complete or
start time, preventing them from being set up during configuration (e.g.
src/devices/video/ppu2c0x.cpp and src/devices/machine/68307.cpp). This
goes against the design principles of how device delegates should be
used, but I didn't change them because I don't trust myself to find all
the places they're used.
I've definitely broken some stuff with this (I know about asterix), so
report issues and bear with me until I get it all fixed.
* hp9825: optional ROM cartridges added (9825b only, ATM)
* hp9825: optional ROMs added to 9825t, added support for banked ROMs
@5c00, separated RAM & ROM spaces in 9825t
* hp9885: added missing post-amble when writing sectors on disk
* hp9825: added acknowledgments to comments (nw)
* hp9825: changes requested by V.Crabb (nw)