| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
| |
To fix this, I had to break old INP files. While I was in there,
I added corefile support for compressing/decompressing data on
the fly, and enabled it for INPs, meaning the newer format INPs
are output and processed compressed.
|
| |
|
|
|
|
|
|
|
|
| |
Readded UI_ON_SCREEN_DISPLAY to be changed again in the "Inputs" menu as per Aaron's request.
A clean build is required and cfg/default.cfg has to be deleted !
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
machine/device handlers. Unfortunately, the implementation relies on
sentinel values to distinguish a port tag versus a pointer to function
code. However, since this is a very common situation, it will hopefully
be worth the slight grossness. New macros are defined in inptport.h:
DEVICE8_PORT(name) - use this to specify the name of a port to read
wherever a read8_device_func would normally be used
MACHINE8_PORT(name) - same as DEVICE8_PORT except it can be used
wherever a read8_machine_func would normally be used
IS_HANDLER_PORT(ptr) - accepts a read8_device_func or read8_machine_func
and determines if it is an actual function or a reference to a port;
intended for use by devices that accept DEVICE8_PORT-style functions
CALL_DEVICE8_READ(ptr,device,offset) - either calls through the given
read8_device_func, or calls input_port_read with the appropriate
tag, depending on the result of IS_HANDLER_PORT; intended for use
by devices that accept DEVICE8_PORT-style functions
CALL_MACHINE8_READ(ptr,machine,offset) - same as CALL_DEVICE8_READ
except for read8_machine_func
Note that in order for these to be useful, the consumer of the function
pointer must be enhanced to use the CALL_* macros above instead of directly
calling through the function. So far, only the 8255 PPI is set up to do
this, as part of the cleanup below. Also note that the sentinel value is
currently 4 consecutive 0 bytes; this may need to change in the future, in
either length or value, so it is important to stick to the macros above.
8255 PPI interface cleanup:
- added MDRV_PPI8255_ADD, MDRV_PPI8255_RECONFIG and
MDRV_PPI8255_REMOVE macros; updated all drivers to use them
- changed callbacks to device read/write handlers intead of
machine read/write handlers; updated all drivers accordingly
- normalized function and variable names to be lower_under
- removed a number of redundant interfaces from the galaxian/
scamble line of games
LD-V1000: added some (compile-time removed) information about the
ROM and memory map
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
for this new support to work.
Clickable input support. Mostly by Nathan. A few changes from the
proposal:
* as far as the layout is concerned, states are 0 (off) or 1 (on) and
aren't impacted by the port's ACTIVE_HIGH or ACTIVE_LOW
* instead of checking each individual field for a hit, we look to see
what is hit once per frame and then just check against that; this
is faster, but does limit us to a single hit item
* added function input_field_by_tag_and_mask() to look up a particular
input_field_config by tag and mask; this makes it possible to easily
get the port default value or other information as necessary
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From: Fabio Priuli [mailto:doge.fabio@gmail.com]
Subject: to simplify cischeat inputs
Hi,
the enclosed diff has a twofold effect on cischeat.c:
on one side: it adds diplocations to bigrun, scudhamm,
cischeat & f1gpstar
on the other side: it removes the current hacky handling of
f1gpstar coinage dips (check video/cischeat.c to see what I
mean with hacky!) to use conditional ports instead. BUT in
order to do this, I had to add more possible values for the
PORTCOND in iptport.c. The problem is that f1gpstar has a set
of coinage settings when you set the region to JPN or USA and
another one when you set the region to EUR or FRA. To implement
this I added the following self-explanatory new PORTCOND:
ISLARGER (>), ISNOTLARGER (<=), ISSMALLER (<), ISNOTSMALLER (<=).
Only two were really needed to implement f1gpstar dips, but
the other two seemed costless to me while offering even more
flexibility to the PORT_CONDITION macro.
Also notice that the handling of conditional ports in 'TAB>Dip
Switches' menu doesn't work well (in the current source, not
affected by my patch) with contracted expressions like
PORT_DIPUNKNOWN_DIPLOC: the wrong items remain listed in the
UI menu even when you change the condition! If you leave the
DEF_STR( Unknown ) with ON/OFF cases, everything is displayed
correctly in the menu. However, I was not able to track down
what part of code is responsible for this bug.
Regards,
Fabio Priuli
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
PORT_START_TAG to PORT_START.
From: Fabio Priuli [mailto:doge.fabio@gmail.com]
Subject: let's say goodbye to untagged input ports ;)
Hi,
enclosed please find a few patches against 126u3 source
* port01.diff -> port09.diff : these patches continues the
cleanup of inputs in drivers starting with C (the remaining ones),
D and E. No ambiguous situations this time, so I guess there should
be no problem with the changes. Improvements include conditional dips
added to dynduke and diplocations for chinagat, chqflag, circus,
citycon, cloak, contra and dynduke
* tag01.diff -> tag09.diff : these patches add tag to EVERY input port
in drivers starting with F->Z. Notice that only tags are added, no
AM_READ_PORT, nor PORT_INCLUDE (and I saw a lot of drivers would need
it ;) ), nor other cleanups contained in the patches above. I'll keep
cleaning input next week, probably, but at least we can definitely
remove the untagged version of PORT_START :) Notice I was able to
compile the source commenting out the definition of PORT_START, so
I guess every occurrence is covered...
|
|
|
|
|
| |
Eventually it will probably disappear altogether. Fixed the
two remaining instances.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
lurking. If you run into anything odd, please let me know.
Added new module uiinput.c which manages input for the user interface.
The OSD is responsible for pushing mouse events and character events
to this interface in order to support mouse movement and text-based
input (currently only used for the select game menu). Added support
for navigating through the menus using the mouse.
[Nathan Woods, Aaron Giles]
Redesigned the UI menus so that they can maintain a richer state. Now
the menus can be generated once and reused, rather than requiring them
to be regenerated on each frame. All menus also share a comment eventing
system and navigation through them is managed centrally. Rewrote all the
menus to use the new system, apart from the cheat menus, which are now
disabled. Reorganized the video menu to make it easier to understand.
[Aaron Giles]
|
|
|
|
|
|
|
|
|
|
|
|
| |
Changed error reporting during input port detokenization to fill a buffer
rather than fatalerror-ing immediately. Should now properly skip over
any invalid tokens.
Enhanced error detection during input port detokenization to catch
duplicate bits. There are a lot of these!
Updated initialization code to print errors and fatal only if the input
ports were unable to be constructed at all.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
mode DIPs on the top of the menu
Fixed behavior of toggle switches so that they don't lose their value
when the UI is up. They also can now be used for multibit DIP switch
settings in which case they toggle through all the options.
New functions input_field_select_next_setting() and
input_field_select_previous_setting() which can be used to iterate
properly through DIP switches. Fixed the behavior for cases where
conditional ports are in play (you could get stuck). Changed uimenu.c
to call these instead of implementing its own.
Changed uimenu.c so that hitting ENTER on a DIP switch resets it to
its default value. This is analagous to how the OSD sliders behave.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Input ports are now maintained hierarchically. At the top
level are input ports, which contain a list of fields. Each
field represents one or more bits of the port. Certain fields
such as DIP switches and configuration switches contain a
list of settings, which can be selected. DIP switch fields
can also contain a list of DIP switch locations.
* Normalized behavior of port overrides (via PORT_INCLUDE or
by defining multiple overlapping bits). All fields within a
port are kept in strict increasing bit order, so altered DIP
switches are now kept in the appropriate order. This addresses
MAMETesters bug 01671.
* Live port state is now fully separate from configured
state. This is manifested in a similar way to devices, where
a const list of ports can be managed either offline or live.
Each port has a pointer to an opaque set of live state which
is NULL when offline or valid when live. Each port also has
a running_machine * which is also NULL when offline.
* Because of this new arrangement, the conversion from tokens
to a list of ports now requires reasonably complex memory
allocation, so these port lists must be explicitly allocated
and freed (they are not mantained by automatic resource
allocation).
* Custom and changed callbacks now take a pointer to a field
config instead of a running machine. This provides more
information about what field triggered the change notification.
The machine can be found by referenced field->port->machine.
* The inptport.c module has been cleaned up and many
ambiguities resolved. Most of this is internal, though it did
result in osd_customize_inputport_list() being changed to
osd_customize_input_type_list(). The parameter to this function
is now a linked list instead of an array, and the structures
referenced have been reorganized somewhat.
* Updated config.c to pass machine parameters to its callbacks.
* Updated validity checks, XML output, and UI system to handle
the new structures.
* Moved large table of default input settings to a separate
include file inpttype.h.
* Removed gross hacks in trackfld and hyperspt NVRAM. These
may be broken as a result.
|
|
|
|
|
| |
natural keyboard
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
memory maps. To do so, you either need to specify a shift amount
(mapping to a particular subset of the bus) or SHIFT_PACKED, which
maps a single larger sized read/write down to multiple reads or
writes at the smaller size.
Removed word-sized handlers from 6821pia.c. Updated drivers that
needed them to use these new interfaces instead.
Updated gaelco3d.c and itech8.c to remove the need for memconv.h
by using this new feature.
Re-removed input_port_set_digital_value().
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
src/emu/cpu/m68000/m68kmame.c:
src/emu/cpu/minx/minx.c:
- Fixed compilation errors on CPU cores not enabled in MAME
src/emu/inptport.c:
src/emu/inptport.h:
- Readded input_port_set_digital_value() (which is needed for natural
keyboard inpout in MESS)
- Added a running_machine parameter to inputx_update()
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
readinputport -> input_port_read_indexed
readinputportbytag -> input_port_read
readinputportbytag_safe -> input_port_read_safe
Added machine parameter to input port functions. Updated
many drivers to accomplish this.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(vsnes,c), tokkae (konamigx.c), sf2 (cps1.c): INP playback loses sync quickly
Rewrote INP recording from scratch, since all old INPs are broken anyways.
Header now includes timestamp, which overrides the default time base for MAME's system time.
Each frame recorded now gets a timestamp.
Analog ports are recorded once per frame and interpolated.
Analog port calculations are all done in fixed point for consistent results.
A bunch of other minor tweaks in the input port code.
There may still be a few changes to the final INP format (considering adding
NVRAM data directly in the INP file, for example....) but this at least seems
to work for the games I've tried.
|
|
|
|
|
| |
own token type rather than expanding into other tokens. The reduces the
number of redundant strings and data.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Updated all call-through handlers appropriately. Renamed read8_handler to
read8_machine_func, replicating this pattern throughout.
Defined new set of memory handler functions which are similar but which
pass a const device_config * in place of the running_machine *. These are
called read8_device_func, etc. Added macros READ8_DEVICE_HANDLER() for
specifying functions of this type. Note that some plumbing still needs to
happen in memory.c before this will work.
This check-in should remove the need for the global Machine and in turn
"deprecat.h" for a lot of drivers, but that work has not been done. On
the flip side, some new accesses to the global Machine were added in the
emu/ files. These should be addressed over time, but are smaller in
number than the references in the driver.
|
| |
|
|
|
|
|
|
|
|
| |
Usage is very similar to PORT_CUSTOM. See the Astro Invader driver for an example
- Removed input_port_set_changed_callback and converted all users to PORT_CHANGED
The only difference between the old callback and the ones supplied by PORT_CHANGED is
that values passed by PORT_CHANGED are normalized to start at bit 0, just like
PORT_CUSTOM.
|
|
|
|
|
|
|
|
|
| |
- Added a video_screen_register_vbl_cb() function for registering VBLANK callbanks
- Changed inptport.c and debugcpu.c to make use the VBLANK callbacks
- Added video_screen_get_time_until_vblank_start()
- CCPU and anything using cpu_scalebyfcount() are currently broken
- I did some fairly extensive testing, but this is a very signficant internal change,
so some things may have broke
|
| |
|
| |
|
|
|
|
|
|
| |
tokenizing data structures, as currently used by the input
port system. Redid the input port tokenization to be more
compact and make use of the new macros.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* PALETTE_INIT no longer has a colortable parameter
* removed game_colortable and remapped_colortable from machine_config
* updated a few stragglers that still referenced these fields
* removed tile_draw_colortable from tilemap.c
(From Zsolt): Added support for the new colortable object in the palette viewer
Changed the input port tokens to use a union instead of casting everything to FPTR.
In the future, C99-enabled compilers will be able to achieve type safety with
designated initializers.
|
|
|
|
|
|
|
|
| |
Added #include "deprecat.h" where necessary to make this happen.
Cleaned up cpuexec.c/.h to latest core style.
Cleaned up implementation of extended INP header in inptport.c.
Removed external access to cycles_currently_ran().
Replaced use of cycles_currently_ran() in v9938 code with mame_rand(), since that is effectively the same thing. :)
|
| |
|
|
|
|
| |
Added CUSTOM_INPUT macro for defining input port callbacks.
|
|
|
|
|
|
| |
- removed years from copyright notices
- removed redundant (c) from copyright notices
- updated "the MAME Team" to be "Nicola Salmoria and the MAME Team"
|
| |
|
| |
|
|
|