Previous 199869 Revisions Next

r20420 Wednesday 23rd January, 2013 at 21:52:41 UTC by Wilbert Pol
(MESS) ef9340/1: Hooked up 2KB external ram by default. (nw)
[src/emu/video]ef9340_1.c ef9340_1.h

trunk/src/emu/video/ef9340_1.c
r20419r20420
186186         switch ( m_ef9340.M & 0xE0 )
187187         {
188188            case 0x00:  /* Write */
189logerror("%d,%d = %02x, %02x\n", m_ef9340.X, m_ef9340.Y, m_ef9341.TB, m_ef9341.TA);
189190               m_ef934x_ram_a[addr] = m_ef9341.TA;
190191               m_ef934x_ram_b[addr] = m_ef9341.TB;
191192               ef9340_inc_c();
r20419r20420
209210
210211            case 0x80:  /* Write slice */
211212               {
213                  UINT8 a = m_ef934x_ram_a[addr];
212214                  UINT8 b = m_ef934x_ram_b[addr];
213215                  UINT8 slice = ( m_ef9340.M & 0x0f ) % 10;
214216
r20419r20420
216218                  if ( b >= 0xa0 )
217219                  {
218220logerror("write slice external ram %04x\n", external_chargen_address(b,slice));
219                     m_ef934x_ext_char_ram[ external_chargen_address( b, slice ) ] = BITSWAP8(m_ef9341.TA,0,1,2,3,4,5,6,7);
221                     m_ef934x_ext_char_ram[ ( ( a & 0x80 ) << 3 ) | external_chargen_address( b, slice ) ] = BITSWAP8(m_ef9341.TA,0,1,2,3,4,5,6,7);
220222                  }
221223
222224                  // Increment slice number
r20419r20420
323325               if ( b & 0x60 )
324326               {
325327                  // Extension
326                  char_data = m_ef934x_ext_char_ram[ external_chargen_address( b & 0x7f, slice ) ];
328                  char_data = m_ef934x_ext_char_ram[ 0x400 | external_chargen_address( b & 0x7f, slice ) ];
327329                  fg = bgr2rgb[ a & 0x07 ];
328330                  bg = bgr2rgb[ ( a >> 4 ) & 0x07 ];
329331               }
r20419r20420
345347               {
346348                  // Extension
347349                  char_data = m_ef934x_ext_char_ram[ external_chargen_address( b & 0x7f, slice ) ];
348                  fg = bgr2rgb[ a & 0x07 ];
350
351                  if ( a & 0x40 )
352                  {
353                     fg = bg;
354                     bg = bgr2rgb[ a & 0x07 ];
355                  }
356                  else
357                  {
358                     fg = bgr2rgb[ a & 0x07 ];
359                  }
349360               }
350361               else
351362               {
352363                  // DEL
364                  char_data = 0xff;
365                  fg = bgr2rgb[ a & 0x07 ];
353366               }
354367            }
355368            else
356369            {
357370               // Normal
358371               char_data = ef9341_char_set[0][b & 0x7f][slice];
359               fg = bgr2rgb[ a & 0x07 ];
372
373               if ( a & 0x40 )
374               {
375                  fg = bg;
376                  bg = bgr2rgb[ a & 0x07 ];
377               }
378               else
379               {
380                  fg = bgr2rgb[ a & 0x07 ];
381               }
360382            }
361383         }
362384
trunk/src/emu/video/ef9340_1.h
r20419r20420
7474   } m_ef9340;
7575   UINT8   m_ef934x_ram_a[1024];
7676   UINT8   m_ef934x_ram_b[1024];
77   UINT8   m_ef934x_ext_char_ram[1024];
77   UINT8   m_ef934x_ext_char_ram[2048];   /* The G7400 has 2KB of external ram hooked up. The datasheet only describes how to hookup 1KB. */
7878};
7979
8080

Previous 199869 Revisions Next


© 1997-2024 The MAME Team