diff options
author | 2008-12-18 08:28:50 +0000 | |
---|---|---|
committer | 2008-12-18 08:28:50 +0000 | |
commit | cf9fc5861805c5e344fab6e96d084a372c2683aa (patch) | |
tree | d1fd7dd4b3d409b5cdc49be0441a5fccee7e2188 /src/emu/cpu/i8085/i8085.h | |
parent | d9fbf0dba5d2e98f1fe0a2f7107ac17db1146e03 (diff) |
Made the concept of a "clock" native to devices. The clock is now
specified when the device is added, and the clock is available in
the device_config directly via device->clock. Updated all devices
that have a clock to specify it when adding the device, rather than
as part of their configuration. As part of this work, also created
device-specific _ADD and _REMOVE macros to simplify configuration.
Dfined a generic device execute function callback, though it
is not used yet. The long term plan is that any device with an
execute callback will be scheduled along with the CPUs. Now that
CPUs are devices, their scheduling will be moved over to this
logic eventually.
Changed various NVRAM devices to fetch their default memory region
from the device->region rather than specifying it in the
configuration.
Moved a number of CPUINFO_PTR_* constants to CPUINFO_FCT_*.
Fixed several drivers that manually created their own gfx_elements
to fill in the machine object, so they no longer crash.
Fixed incorrect CPU display on info screen (recently broken).
Moved device startup to *before* the DRIVER_INIT is called. This
is to allow the DRIVER_INIT to configure devices that have been
properly allocated. So far I don't see any negative effects, but
be on the lookout if something weird shows up.
Rewrote the device iteration logic to make use of the typenext
field and the newly-introduced classnext field for iterating more
efficiently through devices of a given type or class.
Fixed behavior of MDRV_CPU_REPLACE so it does not delete and then
re-add a CPU (causing the order to change).
Diffstat (limited to 'src/emu/cpu/i8085/i8085.h')
-rw-r--r-- | src/emu/cpu/i8085/i8085.h | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/emu/cpu/i8085/i8085.h b/src/emu/cpu/i8085/i8085.h index cd6fb41a7ea..8e05e894b26 100644 --- a/src/emu/cpu/i8085/i8085.h +++ b/src/emu/cpu/i8085/i8085.h @@ -13,10 +13,11 @@ enum enum { - CPUINFO_PTR_I8085_SOD_CALLBACK = CPUINFO_PTR_CPU_SPECIFIC, - CPUINFO_PTR_I8085_SID_CALLBACK = CPUINFO_PTR_CPU_SPECIFIC + 1, - CPUINFO_PTR_I8085_INTE_CALLBACK = CPUINFO_PTR_CPU_SPECIFIC + 2, - CPUINFO_PTR_I8085_STATUS_CALLBACK = CPUINFO_PTR_CPU_SPECIFIC + 3, + CPUINFO_FCT_I8085_SOD_CALLBACK = CPUINFO_FCT_CPU_SPECIFIC, + CPUINFO_FCT_I8085_SID_CALLBACK, + CPUINFO_FCT_I8085_INTE_CALLBACK, + CPUINFO_FCT_I8085_STATUS_CALLBACK, + CPUINFO_INT_I8085_SID = CPUINFO_INT_CPU_SPECIFIC }; @@ -67,22 +68,22 @@ CPU_DISASSEMBLE( i8085 ); INLINE void i8085_set_sod_callback(const device_config *device, i8085_sod_func callback) { - device_set_info_fct(device, CPUINFO_PTR_I8085_SOD_CALLBACK, (genf *)callback); + device_set_info_fct(device, CPUINFO_FCT_I8085_SOD_CALLBACK, (genf *)callback); } INLINE void i8085_set_sid_callback(const device_config *device, i8085_sid_func callback) { - device_set_info_fct(device, CPUINFO_PTR_I8085_SID_CALLBACK, (genf *)callback); + device_set_info_fct(device, CPUINFO_FCT_I8085_SID_CALLBACK, (genf *)callback); } INLINE void i8085_set_inte_callback(const device_config *device, i8085_inte_func callback) { - device_set_info_fct(device, CPUINFO_PTR_I8085_INTE_CALLBACK, (genf *)callback); + device_set_info_fct(device, CPUINFO_FCT_I8085_INTE_CALLBACK, (genf *)callback); } INLINE void i8085_set_status_callback(const device_config *device, i8085_status_func callback) { - device_set_info_fct(device, CPUINFO_PTR_I8085_STATUS_CALLBACK, (genf *)callback); + device_set_info_fct(device, CPUINFO_FCT_I8085_STATUS_CALLBACK, (genf *)callback); } INLINE void i8085_set_sid(const device_config *device, int sid) |