mirror of
https://github.com/holub/mame
synced 2025-06-30 16:00:01 +03:00
Cleaned up some recent commits.
This commit is contained in:
parent
270c31899f
commit
d246968ffc
@ -20,45 +20,49 @@ We output a leader, followed by the contents of the H8T file.
|
||||
|
||||
namespace {
|
||||
|
||||
static constexpr double ONE_FREQ = 1200.0;
|
||||
static constexpr double ONE_FREQ_VARIANCE = 300.0;
|
||||
static constexpr double ZERO_FREQ = 2400.0;
|
||||
static constexpr double ZERO_FREQ_VARIANCE = 600.0;
|
||||
constexpr double ONE_FREQ = 1200.0;
|
||||
constexpr double ONE_FREQ_VARIANCE = 300.0;
|
||||
constexpr double ZERO_FREQ = 2400.0;
|
||||
constexpr double ZERO_FREQ_VARIANCE = 600.0;
|
||||
|
||||
static const cassette_image::Modulation heath_h8t_modulation =
|
||||
const cassette_image::Modulation heath_h8t_modulation =
|
||||
{
|
||||
cassette_image::MODULATION_SINEWAVE,
|
||||
ONE_FREQ - ONE_FREQ_VARIANCE, ONE_FREQ, ONE_FREQ + ONE_FREQ_VARIANCE,
|
||||
ZERO_FREQ - ZERO_FREQ_VARIANCE, ZERO_FREQ, ZERO_FREQ + ZERO_FREQ_VARIANCE
|
||||
};
|
||||
|
||||
static cassette_image::error heath_h8t_identify(cassette_image *cassette, cassette_image::Options *opts)
|
||||
cassette_image::error heath_h8t_identify(cassette_image *cassette, cassette_image::Options *opts)
|
||||
{
|
||||
return cassette->modulation_identify(heath_h8t_modulation, opts);
|
||||
}
|
||||
|
||||
|
||||
#define MODULATE(_value) \
|
||||
for (int i = 0; i < (_value ? 8 : 4); i++) { \
|
||||
err = cassette->put_modulated_data_bit(0, time_index, _value, heath_h8t_modulation, &time_displacement); \
|
||||
if (err != cassette_image::error::SUCCESS) return err; \
|
||||
time_index += time_displacement; \
|
||||
}
|
||||
|
||||
static cassette_image::error heath_h8t_load(cassette_image *cassette)
|
||||
cassette_image::error heath_h8t_load(cassette_image *cassette)
|
||||
{
|
||||
cassette_image::error err = cassette_image::error::SUCCESS;
|
||||
uint64_t image_size = cassette->image_size();
|
||||
double time_index = 0.0;
|
||||
double time_displacement;
|
||||
|
||||
// leader - 1 second
|
||||
while (time_index < 1.0)
|
||||
{
|
||||
MODULATE(1);
|
||||
}
|
||||
auto const MODULATE =
|
||||
[&cassette, &err, &time_index, &time_displacement] (unsigned value)
|
||||
{
|
||||
for (int i = 0; (i < (value ? 8 : 4)); i++)
|
||||
{
|
||||
err = cassette->put_modulated_data_bit(0, time_index, value, heath_h8t_modulation, &time_displacement);
|
||||
if (cassette_image::error::SUCCESS == err)
|
||||
time_index += time_displacement;
|
||||
else
|
||||
return;
|
||||
}
|
||||
};
|
||||
|
||||
for (uint64_t image_pos = 0; image_pos < image_size; image_pos++)
|
||||
// leader - 1 second
|
||||
while ((cassette_image::error::SUCCESS == err) && (time_index < 1.0))
|
||||
MODULATE(1);
|
||||
|
||||
for (uint64_t image_pos = 0; (cassette_image::error::SUCCESS == err) && (image_pos < image_size); image_pos++)
|
||||
{
|
||||
uint8_t data = cassette->image_read_byte(image_pos);
|
||||
|
||||
@ -66,13 +70,12 @@ static cassette_image::error heath_h8t_load(cassette_image *cassette)
|
||||
MODULATE(0);
|
||||
|
||||
// data bits
|
||||
for (int bit = 0; bit < 8; bit++)
|
||||
{
|
||||
for (int bit = 0; (cassette_image::error::SUCCESS == err) && (bit < 8); bit++)
|
||||
MODULATE(util::BIT(data, bit));
|
||||
}
|
||||
|
||||
// stop bit
|
||||
MODULATE(1);
|
||||
if (cassette_image::error::SUCCESS == err)
|
||||
MODULATE(1);
|
||||
}
|
||||
|
||||
return err;
|
||||
|
@ -78,47 +78,50 @@ ROM_START( intlc8 )
|
||||
ROM_LOAD( "miss7.bin", 0x0700, 0x0100, NO_DUMP )
|
||||
ROM_END
|
||||
|
||||
ROM_START( intlc8m80a )
|
||||
ROM_REGION( 0x2000, "maincpu", ROMREGION_ERASEFF )
|
||||
ROM_LOAD( "3000_1702a.chip_0", 0x0000, 0x0100, CRC(a72cdab9) SHA1(c9931f1b55558383054a02b40fa716e9658ce3c4) )
|
||||
ROM_LOAD( "3100h_1702a.chip_1", 0x0100, 0x0100, CRC(62fbc181) SHA1(e704b5b198e43ff0b9c57067e375070a7674f3dd) )
|
||||
ROM_LOAD( "3200_1702a.chip_2", 0x0200, 0x0100, CRC(65215a39) SHA1(aaaae0f226a0d0f4eeac51e836b1ea674eb0f996) )
|
||||
// Empty sockets from CHIP 3 to CHIP 4
|
||||
ROM_LOAD( "icon_2708-p_mon8_3800_1702a.chip_5", 0x0300, 0x0100, CRC(00445543) SHA1(63ab074ba8c43905e2a43761b5cc5e0618f6e403) )
|
||||
ROM_LOAD( "prog_3600_1702a.chip_6", 0x0400, 0x0100, CRC(61a99002) SHA1(2be84f3191d6de5e184a8c7a40312c663b4c1817) )
|
||||
ROM_LOAD( "1702a.chip_7", 0x0500, 0x0100, CRC(90d9a76b) SHA1(3d66bc7aa5caa2abb487dfe28ab989b373fe6703) )
|
||||
ROM_LOAD( "3800_mon8_1702a.chip_8", 0x0600, 0x0100, CRC(ee7a08dc) SHA1(f12a690d72f08ef333e65634e0e60aff40746b7a) )
|
||||
ROM_LOAD( "3900h_mon8_1702a.chip_9", 0x0700, 0x0100, CRC(d2795e4d) SHA1(f3ef8e197fcfaf6752da8cee6ee776b7a450cef2) )
|
||||
ROM_LOAD( "3a00h_mon8_1702a.chip_a", 0x0800, 0x0100, CRC(c92f98e3) SHA1(dcb4316c6f037666a2a4b88df7e18ca74e754dd0) )
|
||||
ROM_LOAD( "3b00h_mon8_1702a.chip_b", 0x0900, 0x0100, CRC(23083008) SHA1(57af12b20f160d5faa99ad2bda597f21e52078c9) )
|
||||
ROM_LOAD( "3c00h_mon8_1702a.chip_c", 0x0a00, 0x0100, CRC(32f5c81b) SHA1(2371c0e087486c8bcb909575f158fd5ac9209bc8) )
|
||||
ROM_LOAD( "3d00h_mon8_1702a.chip_d", 0x0b00, 0x0100, CRC(5307307a) SHA1(f38adac5e1a8bb015e23f13be5ab434394e6495f) )
|
||||
ROM_LOAD( "3e00h_mon8_1702a.chip_e", 0x0c00, 0x0100, NO_DUMP )
|
||||
ROM_LOAD( "3f00h_mon8_1702a.chip_f", 0x0d00, 0x0100, CRC(beca9bd7) SHA1(8162306bfbd94a373736b9e8e9f426af104d744e) )
|
||||
ROM_END
|
||||
// FIXME: these are for an 8080-based system and possibly don't belong here
|
||||
|
||||
ROM_START( intlc8m80 )
|
||||
ROM_DEFAULT_BIOS("884a")
|
||||
ROM_SYSTEM_BIOS(0, "880", "880")
|
||||
ROM_SYSTEM_BIOS(1, "884a", "884A")
|
||||
|
||||
ROM_START( intlc8m80b )
|
||||
ROM_REGION( 0x2000, "maincpu", ROMREGION_ERASEFF )
|
||||
ROM_LOAD( "1702a.chip_0", 0x0000, 0x0100, CRC(64a1aa3a) SHA1(7158e866eb222b1fbc1f573cdc748f5aedd6d0d4) )
|
||||
ROM_LOAD( "1702a.chip_1", 0x0100, 0x0100, CRC(4583b6c3) SHA1(f9073ecfe0c043756437af595aa87b7224bf370d) )
|
||||
ROM_LOAD( "1702a.chip_2", 0x0200, 0x0100, CRC(5a2951cc) SHA1(d9252365a330cd390ebe029517c83d9e579750a2) )
|
||||
ROM_LOAD( "1702a.chip_3", 0x0300, 0x0100, CRC(37b1b90b) SHA1(b88872d56d03efe6ebc550fc9608e55ca0cae3cd) )
|
||||
ROM_LOAD( "1702a.chip_4", 0x0400, 0x0100, CRC(dcbcc405) SHA1(1dc65e9c73416353e2650158183ff4ff33a9eb0e) )
|
||||
|
||||
ROMX_LOAD( "3000_1702a.chip_0", 0x0000, 0x0100, CRC(a72cdab9) SHA1(c9931f1b55558383054a02b40fa716e9658ce3c4), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3100h_1702a.chip_1", 0x0100, 0x0100, CRC(62fbc181) SHA1(e704b5b198e43ff0b9c57067e375070a7674f3dd), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3200_1702a.chip_2", 0x0200, 0x0100, CRC(65215a39) SHA1(aaaae0f226a0d0f4eeac51e836b1ea674eb0f996), ROM_BIOS(0) )
|
||||
// Empty sockets from CHIP 3 to CHIP 4
|
||||
ROMX_LOAD( "icon_2708-p_mon8_3800_1702a.chip_5", 0x0300, 0x0100, CRC(00445543) SHA1(63ab074ba8c43905e2a43761b5cc5e0618f6e403), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "prog_3600_1702a.chip_6", 0x0400, 0x0100, CRC(61a99002) SHA1(2be84f3191d6de5e184a8c7a40312c663b4c1817), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "1702a.chip_7", 0x0500, 0x0100, CRC(90d9a76b) SHA1(3d66bc7aa5caa2abb487dfe28ab989b373fe6703), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3800_mon8_1702a.chip_8", 0x0600, 0x0100, CRC(ee7a08dc) SHA1(f12a690d72f08ef333e65634e0e60aff40746b7a), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3900h_mon8_1702a.chip_9", 0x0700, 0x0100, CRC(d2795e4d) SHA1(f3ef8e197fcfaf6752da8cee6ee776b7a450cef2), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3a00h_mon8_1702a.chip_a", 0x0800, 0x0100, CRC(c92f98e3) SHA1(dcb4316c6f037666a2a4b88df7e18ca74e754dd0), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3b00h_mon8_1702a.chip_b", 0x0900, 0x0100, CRC(23083008) SHA1(57af12b20f160d5faa99ad2bda597f21e52078c9), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3c00h_mon8_1702a.chip_c", 0x0a00, 0x0100, CRC(32f5c81b) SHA1(2371c0e087486c8bcb909575f158fd5ac9209bc8), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3d00h_mon8_1702a.chip_d", 0x0b00, 0x0100, CRC(5307307a) SHA1(f38adac5e1a8bb015e23f13be5ab434394e6495f), ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3e00h_mon8_1702a.chip_e", 0x0c00, 0x0100, NO_DUMP, ROM_BIOS(0) )
|
||||
ROMX_LOAD( "3f00h_mon8_1702a.chip_f", 0x0d00, 0x0100, CRC(beca9bd7) SHA1(8162306bfbd94a373736b9e8e9f426af104d744e), ROM_BIOS(0) )
|
||||
|
||||
ROMX_LOAD( "1702a.chip_0", 0x0000, 0x0100, CRC(64a1aa3a) SHA1(7158e866eb222b1fbc1f573cdc748f5aedd6d0d4), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_1", 0x0100, 0x0100, CRC(4583b6c3) SHA1(f9073ecfe0c043756437af595aa87b7224bf370d), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_2", 0x0200, 0x0100, CRC(5a2951cc) SHA1(d9252365a330cd390ebe029517c83d9e579750a2), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_3", 0x0300, 0x0100, CRC(37b1b90b) SHA1(b88872d56d03efe6ebc550fc9608e55ca0cae3cd), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_4", 0x0400, 0x0100, CRC(dcbcc405) SHA1(1dc65e9c73416353e2650158183ff4ff33a9eb0e), ROM_BIOS(1) )
|
||||
// Empty sockets from CHIP 5 to CHIP 6
|
||||
ROM_LOAD( "3700_1702a.chip_7", 0x0500, 0x0100, CRC(cf5a0f6e) SHA1(13841fe28ac310f00d4c55ed07fee8be556ecc9b) )
|
||||
ROM_LOAD( "1702a.chip_8", 0x0600, 0x0100, CRC(fee2425f) SHA1(0210012153d9e294f46ab3653b4eb439125b6cfe) )
|
||||
ROM_LOAD( "3900_1702a.chip_9", 0x0700, 0x0100, CRC(d2795e4d) SHA1(f3ef8e197fcfaf6752da8cee6ee776b7a450cef2) )
|
||||
ROM_LOAD( "1702a.chip_a", 0x0800, 0x0100, CRC(c92f98e3) SHA1(dcb4316c6f037666a2a4b88df7e18ca74e754dd0) )
|
||||
ROM_LOAD( "1702a.chip_b", 0x0900, 0x0100, CRC(23083008) SHA1(57af12b20f160d5faa99ad2bda597f21e52078c9) )
|
||||
ROM_LOAD( "3c00_1702a.chip_c", 0x0a00, 0x0100, CRC(32f5c81b) SHA1(2371c0e087486c8bcb909575f158fd5ac9209bc8) )
|
||||
ROM_LOAD( "1702a.chip_d", 0x0b00, 0x0100, CRC(5307307a) SHA1(f38adac5e1a8bb015e23f13be5ab434394e6495f) )
|
||||
ROM_LOAD( "3e00_1702a.chip_e", 0x0c00, 0x0100, CRC(a90bd1d4) SHA1(b85a4a3d6515aa4ae298a800192077716a060f85) )
|
||||
ROM_LOAD( "1702a.chip_f", 0x0d00, 0x0100, CRC(ae7c919b) SHA1(ab9e2f70ef19d969ce7238784118ae53a5c7ac85) )
|
||||
ROMX_LOAD( "3700_1702a.chip_7", 0x0500, 0x0100, CRC(cf5a0f6e) SHA1(13841fe28ac310f00d4c55ed07fee8be556ecc9b), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_8", 0x0600, 0x0100, CRC(fee2425f) SHA1(0210012153d9e294f46ab3653b4eb439125b6cfe), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "3900_1702a.chip_9", 0x0700, 0x0100, CRC(d2795e4d) SHA1(f3ef8e197fcfaf6752da8cee6ee776b7a450cef2), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_a", 0x0800, 0x0100, CRC(c92f98e3) SHA1(dcb4316c6f037666a2a4b88df7e18ca74e754dd0), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_b", 0x0900, 0x0100, CRC(23083008) SHA1(57af12b20f160d5faa99ad2bda597f21e52078c9), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "3c00_1702a.chip_c", 0x0a00, 0x0100, CRC(32f5c81b) SHA1(2371c0e087486c8bcb909575f158fd5ac9209bc8), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_d", 0x0b00, 0x0100, CRC(5307307a) SHA1(f38adac5e1a8bb015e23f13be5ab434394e6495f), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "3e00_1702a.chip_e", 0x0c00, 0x0100, CRC(a90bd1d4) SHA1(b85a4a3d6515aa4ae298a800192077716a060f85), ROM_BIOS(1) )
|
||||
ROMX_LOAD( "1702a.chip_f", 0x0d00, 0x0100, CRC(ae7c919b) SHA1(ab9e2f70ef19d969ce7238784118ae53a5c7ac85), ROM_BIOS(1) )
|
||||
ROM_END
|
||||
|
||||
} // Anonymous namespace
|
||||
|
||||
// YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS
|
||||
COMP( 1973, intlc8, 0, 0, intlc8, intlc8, intlc8_state, empty_init, "Intel", "Intellec 8 MCS", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) // MOD8 or MOD80?
|
||||
COMP( 1974, intlc8m80a, 0, 0, intlc8, intlc8, intlc8_state, empty_init, "Intel", "Intellec 8 MCS MOD80 (set 1, 884A)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING )
|
||||
COMP( 1974, intlc8m80b, intlc8m80a, 0, intlc8, intlc8, intlc8_state, empty_init, "Intel", "Intellec 8 MCS MOD80 (set 2, 880)", MACHINE_NO_SOUND | MACHINE_NOT_WORKING )
|
||||
// YEAR NAME PARENT COMPAT MACHINE INPUT CLASS INIT COMPANY FULLNAME FLAGS
|
||||
COMP( 1973, intlc8, 0, 0, intlc8, intlc8, intlc8_state, empty_init, "Intel", "intellec 8", MACHINE_NO_SOUND | MACHINE_NOT_WORKING ) // MOD8 or MOD80?
|
||||
COMP( 1974, intlc8m80, 0, 0, intlc8, intlc8, intlc8_state, empty_init, "Intel", "intellec 8/Mod 80", MACHINE_NO_SOUND | MACHINE_NOT_WORKING )
|
||||
|
@ -28,10 +28,10 @@ k001005_renderer::k001005_renderer(device_t &parent, screen_device &screen, devi
|
||||
int const width = 512;
|
||||
int const height = 384;
|
||||
|
||||
m_fb[0] = std::make_unique<bitmap_rgb32>(width, height);
|
||||
m_fb[1] = std::make_unique<bitmap_rgb32>(width, height);
|
||||
m_fb[0].allocate(width, height);
|
||||
m_fb[1].allocate(width, height);
|
||||
|
||||
m_zb = std::make_unique<bitmap_ind32>(width, height);
|
||||
m_zb.allocate(width, height);
|
||||
|
||||
m_3dfifo = std::make_unique<uint32_t []>(0x10000);
|
||||
m_3dfifo_ptr = 0;
|
||||
@ -75,9 +75,9 @@ k001005_renderer::k001005_renderer(device_t &parent, screen_device &screen, devi
|
||||
// save state
|
||||
parent.save_pointer(NAME(m_3dfifo), 0x10000);
|
||||
parent.save_item(NAME(m_3dfifo_ptr));
|
||||
parent.save_item(NAME(*m_fb[0]));
|
||||
parent.save_item(NAME(*m_fb[1]));
|
||||
parent.save_item(NAME(*m_zb));
|
||||
parent.save_item(NAME(m_fb[0]));
|
||||
parent.save_item(NAME(m_fb[1]));
|
||||
parent.save_item(NAME(m_zb));
|
||||
parent.save_item(NAME(m_fb_page));
|
||||
parent.save_item(NAME(m_light_r));
|
||||
parent.save_item(NAME(m_light_g));
|
||||
@ -122,10 +122,10 @@ void k001005_renderer::swap_buffers()
|
||||
{
|
||||
m_fb_page ^= 1;
|
||||
|
||||
m_fb[m_fb_page]->fill(0, m_cliprect);
|
||||
m_fb[m_fb_page].fill(0, m_cliprect);
|
||||
|
||||
float const zvalue = 10000000000.0F;
|
||||
m_zb->fill(*(int*)&zvalue, m_cliprect);
|
||||
m_zb.fill(*(int*)&zvalue, m_cliprect);
|
||||
}
|
||||
|
||||
bool k001005_renderer::fifo_filled()
|
||||
@ -139,8 +139,8 @@ void k001005_renderer::draw_scanline_generic(int32_t scanline, const extent_t& e
|
||||
{
|
||||
k001006_device* k001006 = downcast<k001006_device*>(m_k001006);
|
||||
|
||||
uint32_t *const fb = &m_fb[m_fb_page]->pix(scanline);
|
||||
float *const zb = (float*)&m_zb->pix(scanline);
|
||||
uint32_t *const fb = &m_fb[m_fb_page].pix(scanline);
|
||||
float *const zb = (float*)&m_zb.pix(scanline);
|
||||
|
||||
float z = extent.param[POLY_Z].start;
|
||||
float const dz = extent.param[POLY_Z].dpdx;
|
||||
@ -690,7 +690,7 @@ void k001005_renderer::draw(bitmap_rgb32 &bitmap, const rectangle &cliprect)
|
||||
for (int j = cliprect.min_y; j <= cliprect.max_y; j++)
|
||||
{
|
||||
uint32_t *const bmp = &bitmap.pix(j);
|
||||
uint32_t const *const src = &m_fb[m_fb_page ^ 1]->pix(j - cliprect.min_y);
|
||||
uint32_t const *const src = &m_fb[m_fb_page ^ 1].pix(j - cliprect.min_y);
|
||||
|
||||
for (int i = cliprect.min_x; i <= cliprect.max_x; i++)
|
||||
{
|
||||
|
@ -59,12 +59,12 @@ public:
|
||||
static constexpr int POLY_A = 9;
|
||||
|
||||
private:
|
||||
std::unique_ptr<bitmap_rgb32> m_fb[2];
|
||||
std::unique_ptr<bitmap_ind32> m_zb;
|
||||
bitmap_rgb32 m_fb[2];
|
||||
bitmap_ind32 m_zb;
|
||||
rectangle m_cliprect;
|
||||
int m_fb_page;
|
||||
|
||||
std::unique_ptr<uint32_t[]> m_3dfifo;
|
||||
std::unique_ptr<uint32_t []> m_3dfifo;
|
||||
int m_3dfifo_ptr;
|
||||
|
||||
vertex_t m_vertexb[4];
|
||||
|
@ -21518,8 +21518,7 @@ intlc440 //
|
||||
|
||||
@source:intel/intellec8.cpp
|
||||
intlc8 //
|
||||
intlc8m80a //
|
||||
intlc8m80b //
|
||||
intlc8m80 //
|
||||
|
||||
@source:intel/ipc.cpp
|
||||
ipb // intel
|
||||
|
Loading…
Reference in New Issue
Block a user