mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
Merge pull request #564 from meesokim/patch-6
[spc1000] cassette tape motor fixed for working properly [Miso Kim]
This commit is contained in:
commit
57ea5b0e4f
@ -15,7 +15,7 @@ NOTE: 2014-09-13: added code from someone's modified MESS driver for floppy
|
||||
disk. Since it is not to our coding standards, it is
|
||||
commented out with #if 0/#endif and 3 slashes (///).
|
||||
It is planned to be converted when time permits. The
|
||||
author is Meeso Kim.
|
||||
author is Miso Kim.
|
||||
|
||||
Hardware details of the fdc: Intelligent device, Z80 CPU,
|
||||
XTAL_8MHz, PPI 8255, FDC uPD765C, 2 RAM chips, 28 other
|
||||
@ -26,12 +26,7 @@ NOTE: 2014-09-13: added code from someone's modified MESS driver for floppy
|
||||
|
||||
2015-06-19: Added code for the centronics printer port
|
||||
|
||||
IMPORTANT NOTE for tape usage: you *FIRST* press PLAY on the tape drive
|
||||
(e.g. by pressing F2 in partial emulated keyboard mode) and *THEN* you
|
||||
type LOAD on the BASIC prompt!
|
||||
Otherwise, the system turns the tape motor ON but it does not receive any
|
||||
data from tape, and it turns it OFF before the user can press PLAY.
|
||||
|
||||
2016-01-14: Casstte tape motor fixed for working perperly and ROM file changed for CP/M disk loading
|
||||
|
||||
****************************************************************************/
|
||||
/*
|
||||
@ -224,7 +219,7 @@ WRITE8_MEMBER( spc1000_state::cass_w )
|
||||
{
|
||||
attotime time = machine().scheduler().time();
|
||||
m_cass->output(BIT(data, 0) ? -1.0 : 1.0);
|
||||
if (BIT(data, 1) && ATTOSECONDS_IN_MSEC((time - m_time).as_attoseconds()) > 500) {
|
||||
if (BIT(data, 1) && (time - m_time).as_attoseconds()/ATTOSECONDS_PER_MICROSECOND > 100) {
|
||||
m_cass->change_state((m_cass->get_state() & CASSETTE_MASK_MOTOR) == CASSETTE_MOTOR_DISABLED ? CASSETTE_MOTOR_ENABLED : CASSETTE_MOTOR_DISABLED, CASSETTE_MASK_MOTOR);
|
||||
m_time = time;
|
||||
}
|
||||
@ -438,7 +433,7 @@ READ8_MEMBER( spc1000_state::porta_r )
|
||||
{
|
||||
UINT8 data = 0x3f;
|
||||
data |= (m_cass->input() > 0.0038) ? 0x80 : 0;
|
||||
data |= ((m_cass->get_state() & CASSETTE_MASK_UISTATE) != CASSETTE_STOPPED) && ((m_cass->get_state() & CASSETTE_MASK_MOTOR) == CASSETTE_MOTOR_ENABLED) ? 0x00 : 0x40;
|
||||
data |= ((m_cass->get_state() & CASSETTE_MASK_UISTATE) == CASSETTE_STOPPED || ((m_cass->get_state() & CASSETTE_MASK_MOTOR) == CASSETTE_MOTOR_DISABLED)) ? 0x40 : 0;
|
||||
data &= ~(m_io_joy->read() & 0x3f);
|
||||
data &= ~((m_centronics_busy == 0)<< 5);
|
||||
return data;
|
||||
@ -506,7 +501,7 @@ MACHINE_CONFIG_END
|
||||
/* ROM definition */
|
||||
ROM_START( spc1000 )
|
||||
ROM_REGION(0x10000, "maincpu", ROMREGION_ERASEFF)
|
||||
ROM_LOAD("spcall.rom", 0x0000, 0x8000, CRC(19638fc9) SHA1(489f1baa7aebf3c8c660325fb1fd790d84203284))
|
||||
ROM_LOAD("spcall.rom", 0x0000, 0x8000, CRC(240426be) SHA1(8eb32e147c17a6d0f947b8bb3c6844750a7b64a8))
|
||||
ROM_END
|
||||
|
||||
#if 0
|
||||
@ -521,4 +516,4 @@ ROM_END
|
||||
/* Driver */
|
||||
|
||||
/* YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS */
|
||||
COMP( 1982, spc1000, 0, 0, spc1000, spc1000, driver_device, 0, "Samsung", "SPC-1000", MACHINE_NOT_WORKING )
|
||||
COMP( 1982, spc1000, 0, 0, spc1000, spc1000, driver_device, 0, "Samsung", "SPC-1000", 0 )
|
||||
|
Loading…
Reference in New Issue
Block a user