Changes from MESS:

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()
This commit is contained in:
Nathan Woods 2008-04-14 11:12:42 +00:00
parent 4df26527bc
commit f9766f2052
4 changed files with 22 additions and 4 deletions

View File

@ -241,7 +241,7 @@ static void m68008_get_context(void *dst)
static void m68008_set_context(void *src)
{
if (m68k_memory_intf.read8 != program_read_byte_8)
if (m68k_memory_intf.read8 != program_read_byte_8be)
m68k_memory_intf = interface_d8;
m68k_set_context(src);
}

View File

@ -90,8 +90,8 @@ typedef struct {
static minx_regs regs;
static int minx_icount;
#define rd(offset) program_read_byte_8( offset )
#define wr(offset,data) program_write_byte_8( offset, data )
#define rd(offset) program_read_byte_8be( offset )
#define wr(offset,data) program_write_byte_8be( offset, data )
#define minx_PC ( ( regs.PC & 0x8000 ) ? ( regs.V << 15 ) | (regs.PC & 0x7FFF ) : regs.PC )
INLINE UINT16 rd16( UINT32 offset ) {

View File

@ -2904,7 +2904,7 @@ profiler_mark(PROFILER_INPUT);
#ifdef MESS
/* less MESS to MESSy things */
inputx_update();
inputx_update(machine);
#endif
/* handle playback/record */
@ -3359,6 +3359,22 @@ UINT32 input_port_read_safe(running_machine *machine, const char *tag, UINT32 de
/*************************************
*
* Input port writing
*
*************************************/
void input_port_set_digital_value(running_machine *machine, int port_num, UINT32 value, UINT32 mask)
{
/* used by MESS for natural keyboard input */
input_port_info *portinfo = &port_info[port_num];
portinfo->digital &= ~mask;
portinfo->digital |= value;
}
/*************************************
*
* Return position of crosshair axis

View File

@ -937,6 +937,8 @@ int input_ui_pressed_repeat(int code, int speed);
void input_port_update_defaults(void);
void input_port_set_digital_value(running_machine *machine, int port_num, UINT32 value, UINT32 mask);
UINT32 get_crosshair_pos(int port_num, UINT8 player, UINT8 axis);
UINT32 input_port_read_indexed(running_machine *machine, int port);