Previous 15994 Revisions Next

r1315 Wednesday 21st November, 2007 at 01:52:48 UTC by Nathan Woods
Fixed bug #1427
[src/mess/machine]pdp1.c
[src/mess/video]m6847.c

src/mess/video/m6847.c
r1314r1315
928928
929929
930930
931#define ATTOTIME_STRING_PRECISION   9
932
931933#define M6847_RGB(r,g,b)   ((r << 16) | (g << 8) | (b << 0))
932934
933935
r1314r1315
16201622static TIMER_CALLBACK(hs_fall)
16211623{
16221624   if (LOG_HS)
1623      logerror("hs_fall(): time=%g\n", attotime_to_double(timer_get_time()));
1625      logerror("hs_fall(): time=%s\n", attotime_string(timer_get_time(), ATTOTIME_STRING_PRECISION));
16241626
16251627   set_horizontal_sync();
16261628}
r1314r1315
16281630static TIMER_CALLBACK(hs_rise)
16291631{
16301632   if (LOG_HS)
1631      logerror("hs_rise(): time=%g\n", attotime_to_double(timer_get_time()));
1633      logerror("hs_rise(): time=%s\n", attotime_string(timer_get_time(), ATTOTIME_STRING_PRECISION));
16321634
16331635   timer_adjust(m6847->hs_rise_timer,
16341636      attotime_make(0, m6847->scanline_period),
r1314r1315
16441646static TIMER_CALLBACK(fs_fall)
16451647{
16461648   if (LOG_FS)
1647      logerror("fs_fall(): time=%g scanline=%d\n", attotime_to_double(timer_get_time()), get_scanline());
1649      logerror("fs_fall(): time=%s scanline=%d\n", attotime_string(timer_get_time(), ATTOTIME_STRING_PRECISION), get_scanline());
16481650
16491651   set_field_sync();
16501652}
r1314r1315
16521654static TIMER_CALLBACK(fs_rise)
16531655{
16541656   if (LOG_FS)
1655      logerror("fs_rise(): time=%g scanline=%d\n", attotime_to_double(timer_get_time()), get_scanline());
1657      logerror("fs_rise(): time=%s scanline=%d\n", attotime_string(timer_get_time(), ATTOTIME_STRING_PRECISION), get_scanline());
16561658
16571659   /* adjust field sync falling edge timer */
16581660   timer_adjust(m6847->fs_fall_timer,
r1314r1315
18651867   frequency = v->frames_per_second
18661868      * ((UINT32) (v->scanlines_per_frame * FACTOR_SCANLINES_PER_FRAME))
18671869      * ((UINT32) (v->clocks_per_scanline * FACTOR_CLOCKS_PER_SCANLINE));
1868   period = ATTOTIME_MAX_SECONDS / frequency;
1870   period = ATTOSECONDS_PER_SECOND / frequency;
18691871
18701872   /* choose CPU clock, if specified */
18711873   if (cfg->cpu0_timing_factor > 0)
r1314r1315
19081910   if (LOG_STATS)
19091911   {
19101912      logerror("m6847_init():\n");
1911      logerror("\tclock:      %30s sec\n", attotime_string(attotime_make(0, period * GROSS_FACTOR), 6));
1913      logerror("\tclock:      %30s sec\n", attotime_string(attotime_make(0, period * GROSS_FACTOR), ATTOTIME_STRING_PRECISION));
19121914      if (cpu0_clock_period > 0)
1913         logerror("\tCPU0 clock: %30s sec\n", attotime_string(attotime_make(0, cpu0_clock_period), 6));
1914      logerror("\tscanline:   %30s sec\n", attotime_string(attotime_make(0, m6847->scanline_period), 6));
1915      logerror("\tfield sync: %30s sec\n", attotime_string(attotime_make(0, m6847->field_sync_period), 6));
1916      logerror("\thorz sync:  %30s sec\n", attotime_string(attotime_make(0, m6847->horizontal_sync_period), 6));
1917      logerror("\tvblank:     %30s sec\n", attotime_string(attotime_make(0, m6847->vblank_period), 6));
1918      logerror("\tframe:      %30s sec\n", attotime_string(attotime_make(0, frame_period), 6));
1915         logerror("\tCPU0 clock: %30s sec\n", attotime_string(attotime_make(0, cpu0_clock_period), ATTOTIME_STRING_PRECISION));
1916      logerror("\tscanline:   %30s sec\n", attotime_string(attotime_make(0, m6847->scanline_period), ATTOTIME_STRING_PRECISION));
1917      logerror("\tfield sync: %30s sec\n", attotime_string(attotime_make(0, m6847->field_sync_period), ATTOTIME_STRING_PRECISION));
1918      logerror("\thorz sync:  %30s sec\n", attotime_string(attotime_make(0, m6847->horizontal_sync_period), ATTOTIME_STRING_PRECISION));
1919      logerror("\tvblank:     %30s sec\n", attotime_string(attotime_make(0, m6847->vblank_period), ATTOTIME_STRING_PRECISION));
1920      logerror("\tframe:      %30s sec\n", attotime_string(attotime_make(0, frame_period), ATTOTIME_STRING_PRECISION));
19191921      logerror("\n");
19201922   }
19211923
src/mess/machine/pdp1.c
r1314r1315
11571157{
11581158   (*io) = attotime_mul(
11591159      timer_timeelapsed(parallel_drum.rotation_timer),
1160      ATTOTIME_MAX_SECONDS / (attotime_to_attoseconds(PARALLEL_DRUM_WORD_TIME))).seconds & 0007777;
1160      ATTOSECONDS_PER_SECOND / (attotime_to_attoseconds(PARALLEL_DRUM_WORD_TIME))).seconds & 0007777;
11611161
11621162   /* set parity error and timing error... */
11631163}

Previous 15994 Revisions Next


© 1998-2018 The MESS Team