diff options
Diffstat (limited to 'src/mame/machine/rmnimbus.cpp')
-rw-r--r-- | src/mame/machine/rmnimbus.cpp | 172 |
1 files changed, 86 insertions, 86 deletions
diff --git a/src/mame/machine/rmnimbus.cpp b/src/mame/machine/rmnimbus.cpp index ba7342a06db..e4824cd2faa 100644 --- a/src/mame/machine/rmnimbus.cpp +++ b/src/mame/machine/rmnimbus.cpp @@ -144,48 +144,48 @@ enum struct t_area_params { - UINT16 ofs_brush; - UINT16 seg_brush; - UINT16 ofs_data; - UINT16 seg_data; - UINT16 count; + uint16_t ofs_brush; + uint16_t seg_brush; + uint16_t ofs_data; + uint16_t seg_data; + uint16_t count; }; struct t_plot_string_params { - UINT16 ofs_font; - UINT16 seg_font; - UINT16 ofs_data; - UINT16 seg_data; - UINT16 x; - UINT16 y; - UINT16 length; + uint16_t ofs_font; + uint16_t seg_font; + uint16_t ofs_data; + uint16_t seg_data; + uint16_t x; + uint16_t y; + uint16_t length; }; struct t_nimbus_brush { - UINT16 style; - UINT16 style_index; - UINT16 colour1; - UINT16 colour2; - UINT16 transparency; - UINT16 boundary_spec; - UINT16 boundary_colour; - UINT16 save_colour; + uint16_t style; + uint16_t style_index; + uint16_t colour1; + uint16_t colour2; + uint16_t transparency; + uint16_t boundary_spec; + uint16_t boundary_colour; + uint16_t save_colour; }; static int instruction_hook(device_t &device, offs_t curpc); -static void decode_subbios(device_t *device,offs_t pc, UINT8 raw_flag); +static void decode_subbios(device_t *device,offs_t pc, uint8_t raw_flag); static void decode_dos21(device_t *device,offs_t pc); -static void decode_dssi_generic(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag); -static void decode_dssi_f_fill_area(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag); -static void decode_dssi_f_plot_character_string(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag); -static void decode_dssi_f_set_new_clt(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag); -static void decode_dssi_f_plonk_char(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag); -static void decode_dssi_f_rw_sectors(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag); +static void decode_dssi_generic(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag); +static void decode_dssi_f_fill_area(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag); +static void decode_dssi_f_plot_character_string(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag); +static void decode_dssi_f_set_new_clt(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag); +static void decode_dssi_f_plonk_char(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag); +static void decode_dssi_f_rw_sectors(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag); -void rmnimbus_state::external_int(UINT8 vector, bool state) +void rmnimbus_state::external_int(uint8_t vector, bool state) { if(!state && (vector != m_vector)) return; @@ -264,9 +264,9 @@ static int instruction_hook(device_t &device, offs_t curpc) { rmnimbus_state *state = device.machine().driver_data<rmnimbus_state>(); address_space &space = device.memory().space(AS_PROGRAM); - UINT8 *addr_ptr; + uint8_t *addr_ptr; - addr_ptr = (UINT8*)space.get_read_ptr(curpc); + addr_ptr = (uint8_t*)space.get_read_ptr(curpc); if ((addr_ptr !=nullptr) && (addr_ptr[0]==0xCD)) { @@ -289,21 +289,21 @@ static int instruction_hook(device_t &device, offs_t curpc) #define set_drv(drv_name) sprintf(drv_str,drv_name) #define set_func(func_name) sprintf(func_str,func_name) -static void decode_subbios(device_t *device,offs_t pc, UINT8 raw_flag) +static void decode_subbios(device_t *device,offs_t pc, uint8_t raw_flag) { char type_str[80]; char drv_str[80]; char func_str[80]; - void (*dump_dssi)(device_t *,UINT16, UINT16 ,UINT8) = nullptr; + void (*dump_dssi)(device_t *,uint16_t, uint16_t ,uint8_t) = nullptr; device_t *cpu = device->machine().device(MAINCPU_TAG); - UINT16 ax = cpu->state().state_int(I8086_AX); - UINT16 bx = cpu->state().state_int(I8086_BX); - UINT16 cx = cpu->state().state_int(I8086_CX); - UINT16 ds = cpu->state().state_int(I8086_DS); - UINT16 si = cpu->state().state_int(I8086_SI); + uint16_t ax = cpu->state().state_int(I8086_AX); + uint16_t bx = cpu->state().state_int(I8086_BX); + uint16_t cx = cpu->state().state_int(I8086_CX); + uint16_t ds = cpu->state().state_int(I8086_DS); + uint16_t si = cpu->state().state_int(I8086_SI); // *** TEMP Don't show f_enquire_display_line calls ! if((cx==6) && (ax==43)) @@ -629,7 +629,7 @@ static void decode_subbios(device_t *device,offs_t pc, UINT8 raw_flag) } } -static inline void *get_dssi_ptr(address_space &space, UINT16 ds, UINT16 si) +static inline void *get_dssi_ptr(address_space &space, uint16_t ds, uint16_t si) { int addr; @@ -639,17 +639,17 @@ static inline void *get_dssi_ptr(address_space &space, UINT16 ds, UINT16 si) return space.get_read_ptr(addr); } -static void decode_dssi_generic(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag) +static void decode_dssi_generic(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag) { rmnimbus_state *state = device->machine().driver_data<rmnimbus_state>(); address_space &space = state->m_maincpu->space(AS_PROGRAM); - UINT16 *params; + uint16_t *params; int count; if(raw_flag) return; - params=(UINT16 *)get_dssi_ptr(space,ds,si); + params=(uint16_t *)get_dssi_ptr(space,ds,si); for(count=0; count<10; count++) device->logerror("%04X ",params[count]); @@ -658,12 +658,12 @@ static void decode_dssi_generic(device_t *device,UINT16 ds, UINT16 si, UINT8 ra } -static void decode_dssi_f_fill_area(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag) +static void decode_dssi_f_fill_area(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag) { rmnimbus_state *state = device->machine().driver_data<rmnimbus_state>(); address_space &space = state->m_maincpu->space(AS_PROGRAM); - UINT16 *addr_ptr; + uint16_t *addr_ptr; t_area_params *area_params; t_nimbus_brush *brush; int cocount; @@ -694,7 +694,7 @@ static void decode_dssi_f_fill_area(device_t *device,UINT16 ds, UINT16 si, UINT OUTPUT_SEGOFS("SegData:OfsData",area_params->seg_data,area_params->ofs_data); } - addr_ptr = (UINT16 *)space.get_read_ptr(LINEAR_ADDR(area_params->seg_data,area_params->ofs_data)); + addr_ptr = (uint16_t *)space.get_read_ptr(LINEAR_ADDR(area_params->seg_data,area_params->ofs_data)); for(cocount=0; cocount < area_params->count; cocount++) { if(raw_flag) @@ -712,12 +712,12 @@ static void decode_dssi_f_fill_area(device_t *device,UINT16 ds, UINT16 si, UINT device->logerror("\n"); } -static void decode_dssi_f_plot_character_string(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag) +static void decode_dssi_f_plot_character_string(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag) { rmnimbus_state *state = device->machine().driver_data<rmnimbus_state>(); address_space &space = state->m_maincpu->space(AS_PROGRAM); - UINT8 *char_ptr; + uint8_t *char_ptr; t_plot_string_params *plot_string_params; int charno; @@ -731,7 +731,7 @@ static void decode_dssi_f_plot_character_string(device_t *device,UINT16 ds, UIN device->logerror("x=%d, y=%d, length=%d\n",plot_string_params->x,plot_string_params->y,plot_string_params->length); - char_ptr=(UINT8*)space.get_read_ptr(LINEAR_ADDR(plot_string_params->seg_data,plot_string_params->ofs_data)); + char_ptr=(uint8_t*)space.get_read_ptr(LINEAR_ADDR(plot_string_params->seg_data,plot_string_params->ofs_data)); if (plot_string_params->length==0xFFFF) device->logerror("%s",char_ptr); @@ -742,13 +742,13 @@ static void decode_dssi_f_plot_character_string(device_t *device,UINT16 ds, UIN device->logerror("\n"); } -static void decode_dssi_f_set_new_clt(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag) +static void decode_dssi_f_set_new_clt(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag) { rmnimbus_state *state = device->machine().driver_data<rmnimbus_state>(); address_space &space = state->m_maincpu->space(AS_PROGRAM); - UINT16 *new_colours; + uint16_t *new_colours; int colour; - new_colours=(UINT16 *)get_dssi_ptr(space,ds,si); + new_colours=(uint16_t *)get_dssi_ptr(space,ds,si); if(raw_flag) return; @@ -760,12 +760,12 @@ static void decode_dssi_f_set_new_clt(device_t *device,UINT16 ds, UINT16 si, UI } -static void decode_dssi_f_plonk_char(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag) +static void decode_dssi_f_plonk_char(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag) { rmnimbus_state *state = device->machine().driver_data<rmnimbus_state>(); address_space &space = state->m_maincpu->space(AS_PROGRAM); - UINT16 *params; - params=(UINT16 *)get_dssi_ptr(space,ds,si); + uint16_t *params; + params=(uint16_t *)get_dssi_ptr(space,ds,si); if(raw_flag) return; @@ -775,17 +775,17 @@ static void decode_dssi_f_plonk_char(device_t *device,UINT16 ds, UINT16 si, UIN device->logerror("plonked_char=%c\n",params[0]); } -static void decode_dssi_f_rw_sectors(device_t *device,UINT16 ds, UINT16 si, UINT8 raw_flag) +static void decode_dssi_f_rw_sectors(device_t *device,uint16_t ds, uint16_t si, uint8_t raw_flag) { rmnimbus_state *state = device->machine().driver_data<rmnimbus_state>(); address_space &space = state->m_maincpu->space(AS_PROGRAM); - UINT16 *params; + uint16_t *params; int param_no; if(raw_flag) return; - params=(UINT16 *)get_dssi_ptr(space,ds,si); + params=(uint16_t *)get_dssi_ptr(space,ds,si); for(param_no=0;param_no<16;param_no++) device->logerror("%04X ",params[param_no]); @@ -797,18 +797,18 @@ static void decode_dos21(device_t *device,offs_t pc) { device_t *cpu = device->machine().device(MAINCPU_TAG); - UINT16 ax = cpu->state().state_int(I8086_AX); - UINT16 bx = cpu->state().state_int(I8086_BX); - UINT16 cx = cpu->state().state_int(I8086_CX); - UINT16 dx = cpu->state().state_int(I8086_DX); - UINT16 cs = cpu->state().state_int(I8086_CS); - UINT16 ds = cpu->state().state_int(I8086_DS); - UINT16 es = cpu->state().state_int(I8086_ES); - UINT16 ss = cpu->state().state_int(I8086_SS); + uint16_t ax = cpu->state().state_int(I8086_AX); + uint16_t bx = cpu->state().state_int(I8086_BX); + uint16_t cx = cpu->state().state_int(I8086_CX); + uint16_t dx = cpu->state().state_int(I8086_DX); + uint16_t cs = cpu->state().state_int(I8086_CS); + uint16_t ds = cpu->state().state_int(I8086_DS); + uint16_t es = cpu->state().state_int(I8086_ES); + uint16_t ss = cpu->state().state_int(I8086_SS); - UINT16 si = cpu->state().state_int(I8086_SI); - UINT16 di = cpu->state().state_int(I8086_DI); - UINT16 bp = cpu->state().state_int(I8086_BP); + uint16_t si = cpu->state().state_int(I8086_SI); + uint16_t di = cpu->state().state_int(I8086_DI); + uint16_t bp = cpu->state().state_int(I8086_BP); device->logerror("=======================================================================\n"); device->logerror("DOS Int 0x21 call at %05X\n",pc); @@ -915,13 +915,13 @@ void rmnimbus_state::nimbus_bank_memory() int ramblock = 0; int blockno; char bank[10]; - UINT8 *ram = &m_ram->pointer()[0]; - UINT8 *map_blocks[3]; - UINT8 *map_base; + uint8_t *ram = &m_ram->pointer()[0]; + uint8_t *map_blocks[3]; + uint8_t *map_base; int map_blockno; int block_ofs; - UINT8 ramsel = (m_mcu_reg080 & 0x1F); + uint8_t ramsel = (m_mcu_reg080 & 0x1F); // Invalid ramsel, return. if((ramsel & 0x07)!=0x07) @@ -1039,7 +1039,7 @@ WRITE_LINE_MEMBER(rmnimbus_state::nimbus_fdc_drq_w) m_maincpu->drq1_w(state && FDC_DRQ_ENABLED()); } -UINT8 rmnimbus_state::fdc_driveno(UINT8 drivesel) +uint8_t rmnimbus_state::fdc_driveno(uint8_t drivesel) { switch (drivesel) { @@ -1121,7 +1121,7 @@ READ8_MEMBER(rmnimbus_state::scsi_r) */ WRITE8_MEMBER(rmnimbus_state::fdc_ctl_w) { - UINT8 reg400_old = m_nimbus_drives.reg400; + uint8_t reg400_old = m_nimbus_drives.reg400; char drive[5]; floppy_image_device *floppy; @@ -1272,7 +1272,7 @@ void rmnimbus_state::ipc_dumpregs() READ8_MEMBER(rmnimbus_state::nimbus_pc8031_r) { int pc=space.device().safe_pc(); - UINT8 result; + uint8_t result; switch(offset*2) { @@ -1322,7 +1322,7 @@ WRITE8_MEMBER(rmnimbus_state::nimbus_pc8031_w) READ8_MEMBER(rmnimbus_state::nimbus_pc8031_iou_r) { int pc=space.device().safe_pc(); - UINT8 result = 0; + uint8_t result = 0; switch (offset & 0x01) { @@ -1386,7 +1386,7 @@ WRITE8_MEMBER(rmnimbus_state::nimbus_pc8031_iou_w) READ8_MEMBER(rmnimbus_state::nimbus_pc8031_port_r) { int pc=space.device().safe_pc(); - UINT8 result = 0; + uint8_t result = 0; if(LOG_PC8031_PORT) logerror("8031: PCPORTR %04X read of %04X returns %02X\n",pc,offset,result); @@ -1435,7 +1435,7 @@ WRITE8_MEMBER(rmnimbus_state::nimbus_pc8031_port_w) READ8_MEMBER(rmnimbus_state::nimbus_iou_r) { int pc=space.device().safe_pc(); - UINT8 result=0; + uint8_t result=0; if(offset==0) { @@ -1539,12 +1539,12 @@ void rmnimbus_state::mouse_js_reset() void rmnimbus_state::device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) { - UINT8 x = 0; - UINT8 y = 0; + uint8_t x = 0; + uint8_t y = 0; // int pc=m_maincpu->pc(); - UINT8 intstate_x; - UINT8 intstate_y; + uint8_t intstate_x; + uint8_t intstate_y; int xint; int yint; @@ -1552,10 +1552,10 @@ void rmnimbus_state::device_timer(emu_timer &timer, device_timer_id id, int para x = m_io_mousex->read(); y = m_io_mousey->read(); - UINT8 mxa; - UINT8 mxb; - UINT8 mya; - UINT8 myb; + uint8_t mxa; + uint8_t mxb; + uint8_t mya; + uint8_t myb; //logerror("poll_mouse()\n"); @@ -1682,7 +1682,7 @@ READ8_MEMBER(rmnimbus_state::nimbus_mouse_js_r) 7 ?? always reads 1 */ - UINT8 result; + uint8_t result; //int pc=m_maincpu->_pc(); if (m_io_config->read() & 0x01) |