mirror of
https://github.com/holub/mame
synced 2025-06-07 13:23:50 +03:00
machine/intelfsh.cpp: Support reading the busy/ready pin for Flash chips that have one. [R. Belmont]
This commit is contained in:
parent
747f93d3a2
commit
e81c0d609a
@ -317,6 +317,15 @@ void intelfsh_device::device_start()
|
|||||||
save_pointer( &m_data[0], "m_data", m_size);
|
save_pointer( &m_data[0], "m_data", m_size);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//-------------------------------------------------
|
||||||
|
// is_ready - emulates the *Busy/Ready pin on some
|
||||||
|
// flash devices.
|
||||||
|
//-------------------------------------------------
|
||||||
|
|
||||||
|
bool intelfsh_device::is_ready()
|
||||||
|
{
|
||||||
|
return (m_status & 0x80) ? true : false;
|
||||||
|
}
|
||||||
|
|
||||||
//-------------------------------------------------
|
//-------------------------------------------------
|
||||||
// delay_tick - handle delayed commands/events
|
// delay_tick - handle delayed commands/events
|
||||||
@ -332,6 +341,7 @@ TIMER_CALLBACK_MEMBER(intelfsh_device::delay_tick)
|
|||||||
|
|
||||||
case FM_ERASEAMD4:
|
case FM_ERASEAMD4:
|
||||||
m_flash_mode = FM_NORMAL;
|
m_flash_mode = FM_NORMAL;
|
||||||
|
m_status = 0x80;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,6 +15,8 @@ class intelfsh_device : public device_t,
|
|||||||
public:
|
public:
|
||||||
uint8_t *base() { return &m_data[0]; }
|
uint8_t *base() { return &m_data[0]; }
|
||||||
|
|
||||||
|
bool is_ready();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
// construction/destruction
|
// construction/destruction
|
||||||
intelfsh_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t bits, uint32_t size, uint8_t maker_id, uint16_t device_id);
|
intelfsh_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t bits, uint32_t size, uint8_t maker_id, uint16_t device_id);
|
||||||
|
Loading…
Reference in New Issue
Block a user