Previous 15994 Revisions Next

r15108 Monday 7th May, 2012 at 07:51:53 UTC by Miodrag Milanović
cleanup and version bump (no whatsnew)
[hash]snes.xml
[src]version.c
[src/emu]dirtc.c disound.c ioport.c ioport.h rendlay.c screen.c sound.c uimain.c uimain.h
[src/emu/cpu/i386]i386.c
[src/emu/machine]ds1302.c intelfsh.c intelfsh.h mc146818.c msm5832.c msm5832.h rp5c01.c rp5c15.c
[src/emu/sound]i5000.c
[src/lib/formats]ap2_dsk.c dfi_dsk.c
[src/lib/libflac/libflac]memory.c
[src/lib/util]avhuff.c
[src/mame]mame.lst
[src/mame/drivers]aliens.c amaticmg.c astrafr.c bfm_sc4.c bfm_sc5.c bfm_swp.c bmcpokr.c byvid.c chance32.c crimfght.c galdrvr.c gei.c hikaru.c ksys573.c namcos10.c puckpkmn.c seta2.c
[src/mame/includes]bfm_sc45.h megadriv.h
[src/mame/layout]bfm_sc1.lay bfm_sc4.lay
[src/mame/video]awpvid.c turbo.c
[src/mess/drivers]pc8001.c rainbow.c tvc.c
[src/mess/machine]3c505.c a2themill.c apple2.c apple2gs.c ay3600.c c64_ide64.c hd64610.c osborne1.c
[src/osd/windows]input.c

hash/snes.xml
r15107r15108
9393  - Pele! - USA, for 1993 or later, Accolade
9494  - Pocahontas - USA, for 1996 or later, Funcom
9595  - Popeye - USA, for 1993 or later, Technos
96  - Railroad Tycoon - USA, for 1993,    MicroProse
96  - Railroad Tycoon - USA, for 1993,   MicroProse
9797  - SGT. Saunder's Combat - USA, for 199?, Play Avenue/Chickenhead
9898  - Shadowhawk - USA, for 1995 or later, Shadowline Studios
9999  - Smurfs, The - USA, for 199?, Infogrames
src/mame/mame.lst
r15107r15108
47344734puckpkmna      // (c) 2000 IBS
47354735topshoot      // (c) 1995 Sun Mixing
47364736
4737batlemp
4737jzth
47384738
47394739// Sega MegaTech, the number shown is on the label of the instruction rom
47404740megatech
src/mame/includes/megadriv.h
r15107r15108
110110
111111   int m_protcount;
112112
113   // batlemp protection
113   // jzth protection
114114   DECLARE_WRITE16_MEMBER( bl_710000_w )
115115   {
116116      int pc = cpu_get_pc(&space.device());
r15107r15108
120120      // protection value is read from  0x710000 after a series of writes.. and stored at ff0007
121121      // startup
122122      /*
123      059ce0 writing to bl_710000_w ff08 ffff
124      059d04 writing to bl_710000_w 000a ffff
125      059d04 writing to bl_710000_w 000b ffff
126      059d04 writing to bl_710000_w 000c ffff
127      059d04 writing to bl_710000_w 000f ffff
128      059d1c writing to bl_710000_w ff09 ffff
129      059d2a reading from bl_710000_r  (wants 0xe)
130      059ce0 writing to bl_710000_w ff08 ffff
131      059d04 writing to bl_710000_w 000a ffff
132      059d04 writing to bl_710000_w 000b ffff
133      059d04 writing to bl_710000_w 000c ffff
134      059d04 writing to bl_710000_w 000f ffff
135      059d1c writing to bl_710000_w ff09 ffff
136      059d2a reading from bl_710000_r  (wants 0xe)
137      */
123        059ce0 writing to bl_710000_w ff08 ffff
124        059d04 writing to bl_710000_w 000a ffff
125        059d04 writing to bl_710000_w 000b ffff
126        059d04 writing to bl_710000_w 000c ffff
127        059d04 writing to bl_710000_w 000f ffff
128        059d1c writing to bl_710000_w ff09 ffff
129        059d2a reading from bl_710000_r  (wants 0xe)
130        059ce0 writing to bl_710000_w ff08 ffff
131        059d04 writing to bl_710000_w 000a ffff
132        059d04 writing to bl_710000_w 000b ffff
133        059d04 writing to bl_710000_w 000c ffff
134        059d04 writing to bl_710000_w 000f ffff
135        059d1c writing to bl_710000_w ff09 ffff
136        059d2a reading from bl_710000_r  (wants 0xe)
137        */
138138      // before lv stage 3
139139      /*
140      059ce0 writing to bl_710000_w 0008 ffff
141      059d04 writing to bl_710000_w 000b ffff
142      059d04 writing to bl_710000_w 000f ffff
143      059d1c writing to bl_710000_w ff09 ffff
144      059d2a reading from bl_710000_r  (wants 0x4)
145      */
140        059ce0 writing to bl_710000_w 0008 ffff
141        059d04 writing to bl_710000_w 000b ffff
142        059d04 writing to bl_710000_w 000f ffff
143        059d1c writing to bl_710000_w ff09 ffff
144        059d2a reading from bl_710000_r  (wants 0x4)
145        */
146146      // start level 3
147147      /*
148      059ce0 writing to bl_710000_w ff08 ffff
149      059d04 writing to bl_710000_w 000b ffff
150      059d04 writing to bl_710000_w 000c ffff
151      059d04 writing to bl_710000_w 000e ffff
152      059d1c writing to bl_710000_w ff09 ffff
153      059d2a reading from bl_710000_r  (wants 0x5)
148        059ce0 writing to bl_710000_w ff08 ffff
149        059d04 writing to bl_710000_w 000b ffff
150        059d04 writing to bl_710000_w 000c ffff
151        059d04 writing to bl_710000_w 000e ffff
152        059d1c writing to bl_710000_w ff09 ffff
153        059d2a reading from bl_710000_r  (wants 0x5)
154154
155      // after end sequence
156      059ce0 writing to bl_710000_w 0008 ffff
157      059d04 writing to bl_710000_w 000a ffff
158      059d04 writing to bl_710000_w 000b ffff
159      059d04 writing to bl_710000_w 000c ffff
160      059d04 writing to bl_710000_w 000f ffff
161      059d1c writing to bl_710000_w ff09 ffff
162      059d2a reading from bl_710000_r  (wants 0xe)
155        // after end sequence
156        059ce0 writing to bl_710000_w 0008 ffff
157        059d04 writing to bl_710000_w 000a ffff
158        059d04 writing to bl_710000_w 000b ffff
159        059d04 writing to bl_710000_w 000c ffff
160        059d04 writing to bl_710000_w 000f ffff
161        059d1c writing to bl_710000_w ff09 ffff
162        059d2a reading from bl_710000_r  (wants 0xe)
163163
164      */
164        */
165165      m_protcount++;
166
167
168
169166   }
170167
171168
src/mame/includes/bfm_sc45.h
r15107r15108
6262      : sc4_state(mconfig, type, tag),
6363        m_adder4cpu(*this, "adder4")
6464   { }
65   
65
6666   UINT32* m_adder4cpuregion;
6767   UINT32* m_adder4ram;
6868
r15107r15108
31213121   ROM_REGION( 0x400000, "ymz", ROMREGION_ERASE00 ) \
31223122    ROM_LOAD( "95008666.bin", 0x000000, 0x100000, CRC(6dcb4a96) SHA1(844dc67bacb7136a3c0f897a69ac5bcacaa4968a) ) \
31233123    ROM_LOAD( "95008667.bin", 0x100000, 0x100000, CRC(5243784c) SHA1(771248de9fa3446ad6fe1bd35b240ad6ae23f008) ) \
3124 
31253124
31263125
31273126
31283127
31293128
3129
src/mame/video/awpvid.c
r15107r15108
11/*************************************************************************************
22
33    AWP Hardware video simulation system
4   originally written for AGEMAME by J.Wallace
4    originally written for AGEMAME by J.Wallace
55
66    M.A.M.E Core Copyright Nicola Salmoria and the MAME Team.
77
8   This is a primitive handler for generating reels with multiple symbols visible
9   hanging off steppers.c .
10   
8    This is a primitive handler for generating reels with multiple symbols visible
9    hanging off steppers.c .
10
1111**************************************************************************************/
1212
1313#include "emu.h"
r15107r15108
3636      // if the reel isn't configured don't do this, otherwise you'll get DIV0
3737      if (stepper_get_max(rno))
3838      {
39         sprintf(rg,"sreel%d", x); // our new scrolling reels are called 'sreel'
39         sprintf(rg,"sreel%d", x); // our new scrolling reels are called 'sreel'
4040         // normalize the value
4141         int sreelpos = (reelpos[rno] * 0x10000) / stepper_get_max(rno);
42         
42
4343         output_set_value(rg,sreelpos);
4444      }
4545   }
src/mame/video/turbo.c
r15107r15108
342342                    VR2 = 910 Ohm
343343            */
344344         info->step[level] = sprite_xscale(xscale, 1.0e3 * machine.root_device().ioport("VR1")->read() / 100.0, 1.0e3 * machine.root_device().ioport("VR2")->read() / 100.0, 100e-12);
345       }
345      }
346346   }
347347}
348348
src/mame/layout/bfm_sc1.lay
r15107r15108
1919         <color red="0" green="0.6" blue="1.0" />
2020   </led14segsc>
2121   </element>
22   
22
2323   <element name="Steppers" defstate="0">
2424       <simplecounter maxstate="999" digits="3">
2525      <color red="1.0" green="1.0" blue="1.0" />
src/mame/layout/bfm_sc4.lay
r15107r15108
2828      <bounds x="0" y="0" width="7" height="7" />
2929      <color red="0.6" green="0.6" blue="0.6" />
3030    </rect>
31  </element>   
32   
31  </element>
32 
3333  <element name="Steppers" defstate="0">
3434    <simplecounter maxstate="999" digits="3">
3535      <color red="1.0" green="1.0" blue="1.0" />
r15107r15108
144144      <backdrop name="vfd15" element="vfd0" state="0">
145145         <bounds x="345" y="200" width="9" height="17"/>
146146      </backdrop>
147       
148     
147 
148 
149149    <backdrop name="reel1" element="Steppers" state="0">
150150         <bounds x="250" y="350" width="10" height="5"/>
151151      </backdrop>
r15107r15108
155155      <backdrop name="reel3" element="Steppers" state="0">
156156         <bounds x="350" y="350" width="10" height="5"/>
157157      </backdrop>
158       
158
159159      <backdrop name="reel4" element="Steppers" state="0">
160160         <bounds x="250" y="410" width="10" height="5"/>
161161      </backdrop>
r15107r15108
228228    </backdrop>
229229 
230230 
231     
232231 
232 
233233    <backdrop name="lamp0" element="matrixlamp" state="0">
234234         <bounds x="0" y="0" width="7" height="7"/>
235235      </backdrop>
src/mame/drivers/seta2.c
r15107r15108
687687static void funcube_debug_outputs(running_machine &machine)
688688{
689689#ifdef MAME_DEBUG
690//   seta2_state *state = machine.driver_data<seta2_state>();
691//   popmessage("LED: %02x OUT: %02x", (int)*state->m_funcube_leds, (int)*state->m_funcube_outputs);
690//  seta2_state *state = machine.driver_data<seta2_state>();
691//  popmessage("LED: %02x OUT: %02x", (int)*state->m_funcube_leds, (int)*state->m_funcube_outputs);
692692#endif
693693}
694694
src/mame/drivers/aliens.c
r15107r15108
292292   /* sound hardware */
293293   MCFG_SPEAKER_STANDARD_MONO("mono")
294294
295   MCFG_SOUND_ADD("ymsnd", YM2151, XTAL_3_579545MHz)    /* verified on pcb */
295   MCFG_SOUND_ADD("ymsnd", YM2151, XTAL_3_579545MHz)   /* verified on pcb */
296296   MCFG_SOUND_CONFIG(ym2151_config)
297297   MCFG_SOUND_ROUTE(0, "mono", 0.60)
298298   MCFG_SOUND_ROUTE(1, "mono", 0.60)
299299
300   MCFG_SOUND_ADD("k007232", K007232, XTAL_3_579545MHz)    /* verified on pcb */
300   MCFG_SOUND_ADD("k007232", K007232, XTAL_3_579545MHz)   /* verified on pcb */
301301   MCFG_SOUND_CONFIG(k007232_config)
302302   MCFG_SOUND_ROUTE(0, "mono", 0.20)
303303   MCFG_SOUND_ROUTE(1, "mono", 0.20)
src/mame/drivers/namcos10.c
r15107r15108
352352    */
353353
354354   UINT16 dd16 = d16 ^ key;
355   
355
356356   key = d16;
357357
358358   key =
src/mame/drivers/bfm_sc5.c
r15107r15108
1077410774   ROM_LOAD( "p3084s12.bin", 0x0000, 0x1000000, CRC(7d33e52d) SHA1(6591834c60103f71211449355c592473180c33d9) )
1077510775   ROM_LOAD( "39211386.bin", 0x00000, 0x1000000, CRC(05d2c75b) SHA1(7c82d48e74997b4fe2c12e56a96a7c7ca57628cb) )
1077610776   ROM_LOAD( "39212386.bin", 0x00000, 0x1000000, CRC(4b47f4fc) SHA1(4a72df0c60968bdedac967f1989e3a4bcd7b974d) )
10777
10777
1077810778   sc_sslam_others
1077910779ROM_END
1078010780
r15107r15108
1146711467    ROM_LOAD( "39212623.bin", 0x00000, 0x1000000, CRC(13b1e404) SHA1(ee170ffbd8fcd552c374e550e58a455da76af5fe) )
1146811468
1146911469
11470   
11471   
11470
11471
1147211472ROM_END
1147311473
1147411474
r15107r15108
1177811778
1177911779    ROM_LOAD( "39211172.bin", 0x00000, 0x1000000, CRC(8342c383) SHA1(cc92f7ebab0a55d2a6023ca194e81ef6154563a1) ) // video casino wow
1178011780   ROM_LOAD( "39212172.bin", 0x00000, 0x1000000, CRC(3aed8e3a) SHA1(de5a3fc0d77bf4044a17f17f41ab5c953b500e81) ) // video casino wow
11781 
11781
1178211782   ROM_LOAD( "39211351.bin", 0x00000, 0x511189, CRC(8dd8fc7d) SHA1(54a5e2887e0df095d12beb7fbe7e5fe766c116a4) )
1178311783    ROM_LOAD( "39212351.bin", 0x00000, 0x511189, CRC(38c7be05) SHA1(9d0057863fcd02b5d68717b3bbd5762131b15ed7) )
1178411784
src/mame/drivers/amaticmg.c
r15107r15108
594594   output_set_lamp_value(5, (data >> 4) & 1);   /* HOLD2 */
595595   output_set_lamp_value(6, (data >> 6) & 1);   /* CANCEL */
596596
597//   coin_counter_w(machine(), 0, data & 0x04);   /* Coin In */
598//   coin_counter_w(machine(), 1, data & 0x01);   /* Coin Out */
597//  coin_counter_w(machine(), 0, data & 0x04);  /* Coin In */
598//  coin_counter_w(machine(), 1, data & 0x01);  /* Coin Out */
599599
600600   logerror("port C: %2X\n", data);
601601}
602602
603603WRITE8_MEMBER( amaticmg_state::unk80_w )
604604{
605//   dac_data_w(machine().device("dac"), data & 0x01);      /* Sound DAC */
605//  dac_data_w(machine().device("dac"), data & 0x01);       /* Sound DAC */
606606}
607607
608608
r15107r15108
636636
637637static ADDRESS_MAP_START( amaticmg2_portmap, AS_IO, 8, amaticmg_state )
638638   ADDRESS_MAP_GLOBAL_MASK(0xff)
639//   ADDRESS_MAP_UNMAP_HIGH
639//  ADDRESS_MAP_UNMAP_HIGH
640640   AM_RANGE(0x00, 0x03) AM_DEVREADWRITE("ppi8255_0", i8255_device, read, write)
641641   AM_RANGE(0x20, 0x23) AM_DEVREADWRITE("ppi8255_1", i8255_device, read, write)
642642   AM_RANGE(0x40, 0x41) AM_DEVWRITE_LEGACY("ymsnd", ym3812_w)
r15107r15108
879879   MCFG_SOUND_CONFIG(ym3812_config)
880880   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
881881
882//   MCFG_SOUND_ADD("dac", DAC, 0)   /* Y3014B */
883//   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
882//  MCFG_SOUND_ADD("dac", DAC, 0)   /* Y3014B */
883//  MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
884884
885885MACHINE_CONFIG_END
886886
src/mame/drivers/galdrvr.c
r15107r15108
42094209   ROM_LOAD( "smc2f",        0x0800, 0x0800, CRC(410ab430) SHA1(d89abff6ac4afbf69377a1d63043d629a634aab7) )
42104210   ROM_LOAD( "smc3f",        0x1000, 0x0800, CRC(a6b4144b) SHA1(2b27ad54d716286c0dc9476d47df182ae01bcfd7) )
42114211   ROM_LOAD( "smc4f",        0x1800, 0x0800, CRC(4cc046fe) SHA1(465eaacd50967d768babadd09ab9cad35380f6bf) )
4212   ROM_LOAD( "smc5f",          0x2000, 0x0800, CRC(06d378a6) SHA1(99dbe9fc7f95f8fdce86eb5c32bd1ca1bea0ca3c) )
4212   ROM_LOAD( "smc5f",       0x2000, 0x0800, CRC(06d378a6) SHA1(99dbe9fc7f95f8fdce86eb5c32bd1ca1bea0ca3c) )
42134213   ROM_LOAD( "smc6f",        0x2800, 0x0800, CRC(6e84a927) SHA1(82e8e825d157c3c947a3a222bca059a735169c7d) )
42144214   ROM_LOAD( "smc7f",        0x3000, 0x0800, CRC(b45af1e8) SHA1(d7020774707234acdaef5c655f667d5ee9e54a13) )
42154215   ROM_LOAD( "smc8f_uk",     0x3800, 0x0800, CRC(b968b2ff) SHA1(40105423f48d2260e85597c3c1e4d8fe947db793) )
src/mame/drivers/bmcpokr.c
r15107r15108
209209      {
210210         UINT16 data = state->m_videoram[count];
211211         count++;
212         
212
213213         drawgfx_opaque(bitmap,cliprect,gfx,data,0,0,0,x*8,y*8);
214214
215215      }
src/mame/drivers/gei.c
r15107r15108
19371937GAME( 1991, quiz211,  0,        findout,  quiz,     0,       ROT0, "Elettronolo",           "Quiz (Revision 2.11)",                    GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND )
19381938
19391939GAME( 1992, geimulti, 0,        geimulti, geimulti, geimulti,ROT0, "Grayhound Electronics", "GEI Multi Game",                          GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND )
1940GAME( 1992, sprtauth, 0,        sprtauth, sprtauth, geimulti,ROT0, "Classic Games",         "Sports Authority",                        GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND )
No newline at end of file
1940GAME( 1992, sprtauth, 0,        sprtauth, sprtauth, geimulti,ROT0, "Classic Games",         "Sports Authority",                        GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND )
src/mame/drivers/bfm_swp.c
r15107r15108
1/* Bellfruit SWP (Skill With Prizes) Video hardware
1/* Bellfruit SWP (Skill With Prizes) Video hardware
22    aka Cobra 3
33
44*/
src/mame/drivers/astrafr.c
r15107r15108
111111         logerror("%08x astra_fgpa_slave_w offset %02x %02x\n", pc, offset, data);
112112      }
113113   }
114   
114
115115   // devices
116116   required_device<cpu_device> m_maincpu;
117117   optional_device<cpu_device> m_slavecpu;
r15107r15108
23142314GAME( 200?, as_tblf,  as_tbl        , astra_single,    astrafr,    0,    ROT0,  "Astra", "Triple Bells (Astra, V301)"      , GAME_IS_SKELETON_MECHANICAL)
23152315GAME( 200?, as_td,   0       , astra_single_2e,    astrafr,    astradec,   ROT0,  "Astra", "Twin Dragons (Astra, V103)"      , GAME_IS_SKELETON_MECHANICAL)
23162316
2317GAME( 200?, as_twp,   0          , astra_single_2e,    astrafr,    0,    ROT0,  "Astra", "Twin Pots (Astra, V106)"      , GAME_IS_SKELETON_MECHANICAL)
2317GAME( 200?, as_twp,   0          , astra_single_2e,    astrafr,    0,   ROT0,  "Astra", "Twin Pots (Astra, V106)"      , GAME_IS_SKELETON_MECHANICAL)
23182318GAME( 200?, as_twpa,  as_twp      , astra_single,    astrafr,    0,    ROT0,  "Astra", "Twin Pots (Astra, V104)"      , GAME_IS_SKELETON_MECHANICAL)
23192319GAME( 200?, as_vn,    0        , astrafr_dual_alt_37,    astrafr,    astradec_dual,   ROT0,  "Astra", "Vegas Nights (Astra, V205)"      , GAME_IS_SKELETON_MECHANICAL)
23202320GAME( 200?, as_vcv,    0        , astra_single,    astrafr,    astradec,   ROT0,  "Astra", "Viva Cash Vegas (Astra, V005)"      , GAME_IS_SKELETON_MECHANICAL)
src/mame/drivers/bfm_sc4.c
r15107r15108
2395423954
2395523955
2395623956// PR1326 CASINO EASY STREAK         PR1326 EASY STREAK SOUNDS11  (actually expects PR1326_CAS_EASY_STREAK_SOUNDS11 ? )
23957GAME( 200?, sc4eascs   ,0,          sc4, sc4, sc4, ROT0, "BFM","Easy Streak Casino (Bellfruit) (Scorpion 4) (set 1)", GAME_IS_SKELETON_MECHANICAL )
23957GAME( 200?, sc4eascs   ,0,        sc4, sc4, sc4, ROT0, "BFM","Easy Streak Casino (Bellfruit) (Scorpion 4) (set 1)", GAME_IS_SKELETON_MECHANICAL )
2395823958GAME( 200?, sc4eascsa   ,sc4eascs,   sc4, sc4, sc4, ROT0, "BFM","Easy Streak Casino (Bellfruit) (Scorpion 4) (set 2)", GAME_IS_SKELETON_MECHANICAL )
2395923959GAME( 200?, sc4eascsb   ,sc4eascs,   sc4, sc4, sc4, ROT0, "BFM","Easy Streak Casino (Bellfruit) (Scorpion 4) (set 3)", GAME_IS_SKELETON_MECHANICAL )
2396023960GAME( 200?, sc4eascsc   ,sc4eascs,   sc4, sc4, sc4, ROT0, "BFM","Easy Streak Casino (Bellfruit) (Scorpion 4) (set 4)", GAME_IS_SKELETON_MECHANICAL )
src/mame/drivers/byvid.c
r15107r15108
3232
3333   DECLARE_INPUT_CHANGED_MEMBER(video_test);
3434   DECLARE_INPUT_CHANGED_MEMBER(sound_test);
35   
35
3636   UINT8 m_sound_port2;
3737};
3838
r15107r15108
117117static WRITE_LINE_DEVICE_HANDLER(by133_cb2)
118118{
119119   // to M6803 port 2 d0?
120//   by133_state *drv_state = device->machine().driver_data<by133_state>();
121//   device_set_input_line(drv_state->m_audiocpu, M6801_TIN_LINE, state ? ASSERT_LINE : CLEAR_LINE);
120//  by133_state *drv_state = device->machine().driver_data<by133_state>();
121//  device_set_input_line(drv_state->m_audiocpu, M6801_TIN_LINE, state ? ASSERT_LINE : CLEAR_LINE);
122122}
123123
124124static READ8_DEVICE_HANDLER(by133_portb_r)
r15107r15108
130130{
131131   by133_state *state = device->machine().driver_data<by133_state>();
132132   device->machine().scheduler().synchronize();
133   
133
134134   // d0-d3 to m6803 d1-d4
135135   state->m_sound_port2 = data << 1 & 0x1f;
136136}
src/mame/drivers/hikaru.c
r15107r15108
321321
322322/*
323323    New hardware notes from Stefano Teso:
324
324
325325  - The master SH-4 port A: the bit layout for this thing is (MSB left)
326326
327327    xxxx xxii iiee eexM
r15107r15108
376376  - the serial device at 0080000(A|C) is not an EEPROM; it's likely some
377377    weird device that is used to query the heirarchy of the attached
378378    input/output devices. Probably the naomi has something similar, I
379    haven't looked into it yet.
380 
379    haven't looked into it yet.
380
381381*/
382382
383383#include "emu.h"
src/mame/drivers/ksys573.c
r15107r15108
348348  CN3         - Connector joining this PCB to the MAIN PCB
349349  HYC24855    - ?
350350  RCA-L/R     - RCA connectors for left/right audio output
351
351
352352  Drummania 10th Mix Multisession
353353  -------------------------------
354 
354
355355  This box is used with multi-session System 573 games.
356 
356
357357  Main board is standard GX700 PCB with CDROM (Drummania 10th Mix Multisession)
358358  and Digital I/O Board GX894-PWB(B)A
359359  BIOS is on a small plug-in daughterboard.
360360  Daughterboard contains one EPROM, one PAL22V10, 2 logic chips and a PIC16F84.
361361  The dumps provided are the EPROM dumped separately and a dump of the 'board'
362362  with it plugged in (reading may be affected by the PIC)
363 
364 
363
364
365365  PCB Layout of External Multisession Box
366366  ---------------------------------------
367 
367
368368  GXA25-PWB(A)(C)2000 KONAMI
369369  |--------------------------------------------------------------------------|
370370  |CN9  ADM232  LS273        PC16552          PC16552         XC9536(1)  CN13|
r15107r15108
407407          TC9446F      - Toshiba TC9446F-016 Audio Digital Processor for Decode of Dolby Digital (AC-3) MPEG2 Audio
408408          CN16-CN19    - Connector for sub board (3 of them are present). One board connects via a thin cable from
409409                         CN1 to the main board to a connector on the security board labelled 'AMP BOX'.
410 
410
411411  Sub Board Layout
412412  ----------------
413413
r15107r15108
421421  |ZUS1R50505        6379A          |
422422  |                          LM358  |
423423  |---------------------------------|
424         
424
425425  */
426426
427427#include "emu.h"
src/mame/drivers/puckpkmn.c
r15107r15108
128128
129129
130130
131static INPUT_PORTS_START( batlemp )
131static INPUT_PORTS_START( jzth )
132132   PORT_START("P2")   /* $700011.b */
133133   PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
134134   PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN )
r15107r15108
236236ADDRESS_MAP_END
237237
238238
239static ADDRESS_MAP_START( batlemp_map, AS_PROGRAM, 16, md_boot_state )
239static ADDRESS_MAP_START( jzth_map, AS_PROGRAM, 16, md_boot_state )
240240   AM_RANGE(0x000000, 0x3fffff) AM_ROM
241241   AM_RANGE(0x700010, 0x700011) AM_READ_PORT("P2")
242242   AM_RANGE(0x700012, 0x700013) AM_READ_PORT("P1")
r15107r15108
246246   AM_RANGE(0x700022, 0x700023) AM_DEVREADWRITE8("oki", okim6295_device, read, write, 0x00ff)
247247   AM_RANGE(0xa04000, 0xa04003) AM_DEVREADWRITE8_LEGACY("ymsnd", megadriv_68k_YM2612_read, megadriv_68k_YM2612_write, 0xffff)
248248   AM_RANGE(0xc00000, 0xc0001f) AM_READWRITE_LEGACY(megadriv_vdp_r, megadriv_vdp_w)
249   
250249
250
251251   AM_RANGE(0xe00000, 0xe0ffff) AM_RAM AM_MIRROR(0x1f0000) AM_BASE_LEGACY(&megadrive_ram)
252252
253253   AM_RANGE(0xa00000, 0xa00551) AM_NOP
r15107r15108
285285
286286   MCFG_DEVICE_REMOVE("genesis_snd_z80")
287287
288   MCFG_OKIM6295_ADD("oki", 1056000, OKIM6295_PIN7_HIGH) // clock frequency & pin 7 not verified
288   MCFG_OKIM6295_ADD("oki", XTAL_4MHz / 4, OKIM6295_PIN7_HIGH)
289289   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.25)
290290   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker",0.25)
291291MACHINE_CONFIG_END
r15107r15108
297297
298298MACHINE_CONFIG_END
299299
300static MACHINE_CONFIG_DERIVED( batlemp, puckpkmn )
300static MACHINE_CONFIG_DERIVED( jzth, puckpkmn )
301301
302302   MCFG_CPU_MODIFY("maincpu")
303   MCFG_CPU_PROGRAM_MAP(batlemp_map)
303   MCFG_CPU_PROGRAM_MAP(jzth_map)
304304
305305MACHINE_CONFIG_END
306306
r15107r15108
461461
462462
463463
464ROM_START( batlemp )
464ROM_START( jzth )
465465   ROM_REGION( 0x400000, "maincpu", 0 )
466466   ROM_LOAD16_BYTE( "s.y.u5", 0x000000, 0x080000, CRC(a4a526b5) SHA1(85d0299caf91ff50b6870f845b9aacbd358ed81f) )
467467   ROM_LOAD16_BYTE( "s.y.u4", 0x000001, 0x080000, CRC(c16654eb) SHA1(dca4b772a3b9caa7be3fa01511c401b591c2e6f3) )
r15107r15108
480480/* Genie Hardware (uses Genesis VDP) also has 'Sun Mixing Co' put into tile ram */
481481GAME( 2000, puckpkmn, 0,        puckpkmn,  puckpkmn, puckpkmn, ROT0, "Genie",                  "Puckman Pockimon (set 1)", 0 )
482482GAME( 2000, puckpkmna,puckpkmn, puckpkmna, puckpkmn, puckpkmn, ROT0, "IBS",                    "Puckman Pockimon (set 2)", 0 )
483GAME( 2000, batlemp,  0,        batlemp,   batlemp,  puckpkmn, ROT0, "<unknown>",              "Jue Zhan Tian Huang/Battle Emporer", GAME_IMPERFECT_SOUND )
483GAME( 2000, jzth,     0,        jzth,      jzth,     puckpkmn, ROT0, "<unknown>",              "Jue Zhan Tian Huang", GAME_IMPERFECT_SOUND )
src/mame/drivers/chance32.c
r15107r15108
148148   AM_RANGE(0x23, 0x23) AM_READ_PORT("DSW3")
149149   AM_RANGE(0x24, 0x24) AM_READ_PORT("DSW4")
150150   AM_RANGE(0x25, 0x25) AM_READ(mux_r)
151//   AM_RANGE(0x26, 0x26) AM_READ_PORT("UNK") // vblank?
151//  AM_RANGE(0x26, 0x26) AM_READ_PORT("UNK") // vblank?
152152   AM_RANGE(0x30, 0x30) AM_DEVWRITE("crtc", mc6845_device, address_w)
153153   AM_RANGE(0x31, 0x31) AM_DEVWRITE("crtc", mc6845_device, register_w)
154154   AM_RANGE(0x50, 0x50) AM_DEVREADWRITE("oki", okim6295_device, read, write)
155//   AM_RANGE(0x60, 0x60) AM_WRITENOP // lamps
155//  AM_RANGE(0x60, 0x60) AM_WRITENOP // lamps
156156
157157ADDRESS_MAP_END
158158
src/mame/drivers/crimfght.c
r15107r15108
318318   /* sound hardware */
319319   MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
320320
321   MCFG_SOUND_ADD("ymsnd", YM2151, XTAL_3_579545MHz)    /* verified on pcb */
321   MCFG_SOUND_ADD("ymsnd", YM2151, XTAL_3_579545MHz)   /* verified on pcb */
322322   MCFG_SOUND_CONFIG(ym2151_config)
323323   MCFG_SOUND_ROUTE(0, "lspeaker", 1.0)
324324   MCFG_SOUND_ROUTE(1, "rspeaker", 1.0)
325325
326   MCFG_SOUND_ADD("k007232", K007232, XTAL_3_579545MHz)    /* verified on pcb */
326   MCFG_SOUND_ADD("k007232", K007232, XTAL_3_579545MHz)   /* verified on pcb */
327327   MCFG_SOUND_CONFIG(k007232_config)
328328   MCFG_SOUND_ROUTE(0, "lspeaker", 0.20)
329329   MCFG_SOUND_ROUTE(0, "rspeaker", 0.20)
src/osd/windows/input.c
r15107r15108
792792            entry->configure_osd("RENDER_AVI", "Record Rendered Video");
793793            entry->defseq(SEQ_TYPE_STANDARD).set(KEYCODE_LALT, KEYCODE_F11);
794794            break;
795         
795
796796         // leave everything else alone
797797         default:
798798            break;
src/emu/cpu/i386/i386.c
r15107r15108
5252   entry = seg->selector & ~0x7;
5353   if (limit == 0 || entry + 7 > limit)
5454      return 0;
55   
55
5656   int cpl = cpustate->CPL;
5757   cpustate->CPL = 0;
5858
src/emu/rendlay.c
r15107r15108
664664      m_numstops = 0;
665665      location=symbollist.find(0,",");
666666      while (location!=-1)
667      {   
668         m_stopnames[m_numstops] = symbollist;   
667      {
668         m_stopnames[m_numstops] = symbollist;
669669         m_stopnames[m_numstops].substr(0, location);
670670         symbollist.substr(location+1, symbollist.len()-(location-1));
671671         m_numstops++;
r15107r15108
685685            m_imagefile[i] = m_stopnames[i];
686686            m_stopnames[i].substr(0, location);
687687            m_imagefile[i].substr(location+1, m_imagefile[i].len()-(location-1));
688           
689            //m_alphafile[i] =
688
689            //m_alphafile[i] =
690690            m_file[i] = global_alloc(emu_file(machine.options().art_path(), OPEN_FLAG_READ));
691691         }
692692         else
r15107r15108
10451045      {
10461046         basey = bounds.min_y - ((use_state)*(ourheight/num_shown)/(max_state_used/m_numstops)) + curry;
10471047      }
1048           
1048
10491049      // wrap around...
10501050      if (basey < bounds.min_y)
10511051         basey += ((max_state_used)*(ourheight/num_shown)/(max_state_used/m_numstops));
r15107r15108
10651065               break;
10661066            aspect *= 0.9f;
10671067         }
1068   
1068
10691069         INT32 curx;
10701070         curx = bounds.min_x + (bounds.width() - width) / 2;
10711071
r15107r15108
10761076         if (m_file[fruit]) // render gfx
10771077         {
10781078            bitmap_argb32 tempbitmap2(dest.width(), ourheight/num_shown);
1079           
1079
10801080            if (m_bitmap[fruit].valid())
10811081            {
10821082               render_resample_argb_bitmap_hq(tempbitmap2, m_bitmap[fruit], m_color);
r15107r15108
11031103                        }
11041104                     }
11051105                  }
1106                       
1106
11071107               }
11081108            }
11091109         }
r15107r15108
11111111         {
11121112            // allocate a temporary bitmap
11131113            bitmap_argb32 tempbitmap(dest.width(), dest.height());
1114   
1114
11151115            // loop over characters
11161116            for (const char *s = m_stopnames[fruit]; *s != 0; s++)
11171117            {
r15107r15108
12101210
12111211   // load the alpha bitmap if specified
12121212   //if (m_bitmap[number].valid() && m_alphafile[number])
1213   //   render_load_png(m_bitmap[number], *m_file[number], m_dirname, m_alphafile[number], true);
1213   //  render_load_png(m_bitmap[number], *m_file[number], m_dirname, m_alphafile[number], true);
12141214
12151215   // if we can't load the bitmap just use text rendering
12161216   if (!m_bitmap[number].valid())
src/emu/dirtc.c
r15107r15108
6464   if (update)
6565   {
6666      rtc_clock_updated(m_register[RTC_YEAR], m_register[RTC_MONTH], m_register[RTC_DAY], m_register[RTC_DAY_OF_WEEK],
67         m_register[RTC_HOUR], m_register[RTC_MINUTE], m_register[RTC_SECOND]);   
67         m_register[RTC_HOUR], m_register[RTC_MINUTE], m_register[RTC_SECOND]);
6868   }
6969}
7070
7171
7272//-------------------------------------------------
73//  set_current_time - called to initialize the RTC
74//   to the current system time
73//  set_current_time - called to initialize the RTC
74//  to the current system time
7575//-------------------------------------------------
7676
7777void device_rtc_interface::set_current_time(running_machine &machine)
r15107r15108
105105
106106
107107//-------------------------------------------------
108//  set_clock_register -
108//  set_clock_register -
109109//-------------------------------------------------
110110
111111void device_rtc_interface::set_clock_register(int reg, int value)
r15107r15108
115115
116116
117117//-------------------------------------------------
118//  get_clock_register -
118//  get_clock_register -
119119//-------------------------------------------------
120120
121121int device_rtc_interface::get_clock_register(int reg)
r15107r15108
125125
126126
127127//-------------------------------------------------
128//  clock_updated -
128//  clock_updated -
129129//-------------------------------------------------
130130
131131void device_rtc_interface::clock_updated()
132132{
133133   rtc_clock_updated(m_register[RTC_YEAR], m_register[RTC_MONTH], m_register[RTC_DAY], m_register[RTC_DAY_OF_WEEK],
134      m_register[RTC_HOUR], m_register[RTC_MINUTE], m_register[RTC_SECOND]);   
134      m_register[RTC_HOUR], m_register[RTC_MINUTE], m_register[RTC_SECOND]);
135135}
136136
137137
src/emu/sound/i5000.c
r15107r15108
4545
4646   m_rom_base = (UINT16 *)device().machine().root_device().memregion(":i5000snd")->base();
4747   m_rom_mask = device().machine().root_device().memregion(":i5000snd")->bytes() / 2 - 1;
48   
48
4949   // register for savestates
5050   for (int ch = 0; ch < 16; ch++)
5151   {
r15107r15108
6666        save_item(NAME(m_channels[ch].output_r), ch);
6767        save_item(NAME(m_channels[ch].output_l), ch);
6868   }
69   
69
7070   save_item(NAME(m_regs));
7171}
7272
src/emu/ioport.c
r15107r15108
165165   friend class simple_list<analog_field>;
166166   friend class ioport_manager;
167167   friend void ioport_field::set_user_settings(const ioport_field::user_settings &settings);
168   
168
169169public:
170170   // construction/destruction
171171   analog_field(ioport_field &field);
172   
172
173173   // getters
174174   analog_field *next() const { return m_next; }
175175   ioport_manager &manager() const { return m_field.manager(); }
r15107r15108
183183   void read(ioport_value &value);
184184   float crosshair_read();
185185   void frame_update(running_machine &machine);
186   
186
187187private:
188188   // helpers
189189   INT32 apply_min_max(INT32 value) const;
r15107r15108
239239class dynamic_field
240240{
241241   friend class simple_list<dynamic_field>;
242   
242
243243public:
244244   // construction/destruction
245245   dynamic_field(ioport_field &field);
246   
246
247247   // getters
248248   dynamic_field *next() const { return m_next; }
249249   ioport_field &field() const { return m_field; }
250   
250
251251   // read/write
252252   void read(ioport_value &result);
253253   void write(ioport_value newval);
254   
254
255255private:
256256   // internal state
257257   dynamic_field *         m_next;            // linked list of info for this port
r15107r15108
284284{
285285   // construction/destruction
286286   ioport_port_live(ioport_port &port);
287   
287
288288   // public state
289289   simple_list<analog_field> analoglist;      // list of analog port info
290290   simple_list<dynamic_field> readlist;      // list of dynamic read fields
r15107r15108
313313
314314//-------------------------------------------------
315315//  compute_scale -- compute an 8.24 scale value
316//   from a numerator and a denominator
316//  from a numerator and a denominator
317317//-------------------------------------------------
318318
319319inline INT64 compute_scale(INT32 num, INT32 den)
r15107r15108
335335
336336//-------------------------------------------------
337337//  apply_scale -- apply an 8.24 scale value to
338//   a 32-bit value
338//  a 32-bit value
339339//-------------------------------------------------
340340
341341inline INT32 apply_scale(INT32 value, INT64 scale)
r15107r15108
858858
859859//-------------------------------------------------
860860//  configure_osd - set the token and name of an
861//   OSD entry
861//  OSD entry
862862//-------------------------------------------------
863863
864864void input_type_entry::configure_osd(const char *token, const char *name)
r15107r15108
889889
890890
891891//-------------------------------------------------
892//  set_axis - configure a single axis of a
892//  set_axis - configure a single axis of a
893893//  digital joystick
894894//-------------------------------------------------
895895
r15107r15108
902902
903903
904904//-------------------------------------------------
905//  frame_update - update the state of digital
906//  joysticks prior to accumulating the results
905//  frame_update - update the state of digital
906//  joysticks prior to accumulating the results
907907//  in a port
908908//-------------------------------------------------
909909
r15107r15108
10541054   if (can_post_directly(ch))
10551055      internal_post(ch);
10561056
1057   // can we post this key with an alternate representation?
1057   // can we post this key with an alternate representation?
10581058   else if (can_post_alternate(ch))
10591059   {
10601060      const char_info *info = char_info::find(ch);
r15107r15108
10771077{
10781078   // set the fixed rate
10791079   m_current_rate = rate;
1080   
1080
10811081   // 0 length means strlen
10821082   if (length == 0)
10831083      for (const unicode_char *scan = text; *scan != 0; scan++)
r15107r15108
11011101{
11021102   // set the fixed rate
11031103   m_current_rate = rate;
1104   
1105   // 0-length means strlen   
1104
1105   // 0-length means strlen
11061106   if (length == 0)
11071107      length = strlen(text);
11081108
r15107r15108
11171117         count = 1;
11181118         uc = INVALID_CHAR;
11191119      }
1120     
1120
11211121      // append to the buffer
11221122      post(uc);
11231123      text += count;
r15107r15108
11701170
11711171   // set the fixed rate
11721172   m_current_rate = rate;
1173   
1174   // 0-length means strlen   
1173
1174   // 0-length means strlen
11751175   if (length == 0)
11761176      length = strlen(text);
11771177
r15107r15108
12821282   const char_info *info = char_info::find(ch);
12831283   if (info == NULL)
12841284      return false;
1285   
1285
12861286   const char *altstring = info->alternate;
12871287   if (altstring == NULL)
12881288      return false;
r15107r15108
13031303
13041304//-------------------------------------------------
13051305//  choose_delay - determine the delay between
1306//   posting keyboard events
1306//  posting keyboard events
13071307//-------------------------------------------------
13081308
13091309attotime natural_keyboard::choose_delay(unicode_char ch)
r15107r15108
13161316   if (!m_queue_chars.isnull())
13171317      return attotime::from_msec(10);
13181318
1319   // otherwise, default to constant delay with a longer delay on CR   
1319   // otherwise, default to constant delay with a longer delay on CR
13201320   return attotime::from_msec((ch == '\r') ? 200 : 50);
13211321}
13221322
r15107r15108
13441344
13451345//-------------------------------------------------
13461346//  timer - timer callback to keep things flowing
1347//   when posting a string of characters
1347//  when posting a string of characters
13481348//-------------------------------------------------
13491349
13501350void natural_keyboard::timer(void *ptr, int param)
r15107r15108
13751375
13761376
13771377//-------------------------------------------------
1378//  unicode_to_string - obtain a string
1379//  representation of a given code; used for
1378//  unicode_to_string - obtain a string
1379//  representation of a given code; used for
13801380//  logging and debugging
13811381//-------------------------------------------------
13821382
r15107r15108
14291429
14301430//-------------------------------------------------
14311431//  frame_update - once per frame update of the
1432//   natural keyboard state
1432//  natural keyboard state
14331433//-------------------------------------------------
14341434
14351435void natural_keyboard::frame_update(ioport_port &port, ioport_value &digital)
r15107r15108
16741674
16751675
16761676//-------------------------------------------------
1677//  name - return the field name for a given input
1677//  name - return the field name for a given input
16781678//  field
16791679//-------------------------------------------------
16801680
r15107r15108
16871687      return m_name;
16881688
16891689   // otherwise, return the name associated with the type
1690   return machine().ioport().type_name(m_type, m_player);
1690   return manager().type_name(m_type, m_player);
16911691}
16921692
16931693
16941694//-------------------------------------------------
1695//  seq - return the live input sequence for the
1695//  seq - return the live input sequence for the
16961696//  given input field
16971697//-------------------------------------------------
16981698
r15107r15108
17031703      return defseq(seqtype);
17041704
17051705   // if the field is disabled, return no key
1706   if (m_flags & FIELD_FLAG_UNUSED)
1706   if (unused())
17071707      return input_seq::empty_seq;
17081708
17091709   // if the sequence is the special default code, return the expanded default value
17101710   if (m_live->seq[seqtype].is_default())
1711      return machine().ioport().type_seq(m_type, m_player, seqtype);
1711      return manager().type_seq(m_type, m_player, seqtype);
17121712
17131713   // otherwise, return the sequence as-is
17141714   return m_live->seq[seqtype];
r15107r15108
17161716
17171717
17181718//-------------------------------------------------
1719//  defseq - return the default input sequence for
1719//  defseq - return the default input sequence for
17201720//  the given input field
17211721//-------------------------------------------------
17221722
17231723const input_seq &ioport_field::defseq(input_seq_type seqtype) const
17241724{
17251725   // if the field is disabled, return no key
1726   if (m_flags & FIELD_FLAG_UNUSED)
1726   if (unused())
17271727      return input_seq::empty_seq;
17281728
17291729   // if the sequence is the special default code, return the expanded default value
17301730   if (m_seq[seqtype].is_default())
1731      return machine().ioport().type_seq(m_type, m_player, seqtype);
1731      return manager().type_seq(m_type, m_player, seqtype);
17321732
17331733   // otherwise, return the sequence as-is
17341734   return m_seq[seqtype];
r15107r15108
17371737
17381738//-------------------------------------------------
17391739//  type_class - return the type class for this
1740//   field
1740//  field
17411741//-------------------------------------------------
17421742
17431743ioport_type_class ioport_field::type_class() const
r15107r15108
18111811
18121812
18131813//-------------------------------------------------
1814//  keyboard_code - accesses a particular keyboard
1814//  keyboard_code - accesses a particular keyboard
18151815//  code
18161816//-------------------------------------------------
18171817
r15107r15108
18271827
18281828
18291829//-------------------------------------------------
1830//  get_user_settings - return the current
1830//  get_user_settings - return the current
18311831//  settings for the given input field
18321832//-------------------------------------------------
18331833
r15107r15108
18881888
18891889
18901890//-------------------------------------------------
1891//  setting_name - return the expanded setting
1891//  setting_name - return the expanded setting
18921892//  name for a field
18931893//-------------------------------------------------
18941894
r15107r15108
19081908
19091909
19101910//-------------------------------------------------
1911//  has_previous_setting - return true if the
1911//  has_previous_setting - return true if the
19121912//  given field has a "previous" setting
19131913//-------------------------------------------------
19141914
r15107r15108
19271927
19281928
19291929//-------------------------------------------------
1930//  select_previous_setting - select the previous
1930//  select_previous_setting - select the previous
19311931//  item for a DIP switch or configuration field
19321932//-------------------------------------------------
19331933
r15107r15108
19661966
19671967
19681968//-------------------------------------------------
1969//  has_next_setting - return true if the given
1969//  has_next_setting - return true if the given
19701970//  field has a "next" setting
19711971//-------------------------------------------------
19721972
r15107r15108
19911991
19921992
19931993//-------------------------------------------------
1994//  select_next_setting - select the next item for
1994//  select_next_setting - select the next item for
19951995//  a DIP switch or configuration field
19961996//-------------------------------------------------
19971997
r15107r15108
20272027
20282028
20292029//-------------------------------------------------
2030//  frame_update_digital - get the state of a
2030//  frame_update_digital - get the state of a
20312031//  digital field
20322032//-------------------------------------------------
20332033
r15107r15108
20432043      m_live->analog->frame_update(machine());
20442044      return;
20452045   }
2046   
2046
20472047   // if UI is active, ignore digital inputs
20482048   if (ui_is_menu_active())
20492049      return;
r15107r15108
21362136
21372137//-------------------------------------------------
21382138//  crosshair_position - compute the crosshair
2139//   position
2139//  position
21402140//-------------------------------------------------
21412141
21422142void ioport_field::crosshair_position(float &x, float &y, bool &gotx, bool &goty)
r15107r15108
23002300{
23012301   // fill in the basic values
23022302   for (input_seq_type seqtype = SEQ_TYPE_STANDARD; seqtype < SEQ_TYPE_TOTAL; seqtype++)
2303      seq[seqtype] = field.defseq(seqtype);
2303      seq[seqtype] = field.defseq_unresolved(seqtype);
23042304
23052305   // if this is a digital joystick field, make a note of it
23062306   if (field.is_digital_joystick())
r15107r15108
23642364
23652365//-------------------------------------------------
23662366//  machine - return a reference to the running
2367//   machine
2367//  machine
23682368//-------------------------------------------------
23692369
23702370running_machine &ioport_port::machine() const
r15107r15108
23742374
23752375
23762376//-------------------------------------------------
2377//  manager - return a reference to the
2377//  manager - return a reference to the
23782378//  ioport_manager on the running machine
23792379//-------------------------------------------------
23802380
r15107r15108
24652465
24662466//-------------------------------------------------
24672467//  collapse_fields - remove any fields that are
2468//   wholly overlapped by other fields
2468//  wholly overlapped by other fields
24692469//-------------------------------------------------
24702470
24712471void ioport_port::collapse_fields(astring &errorbuf)
r15107r15108
24832483         lastmodcount = field->modcount();
24842484         maskbits = 0;
24852485      }
2486     
2486
24872487      // reinsert this field
24882488      ioport_field *current = field;
24892489      field = field->next();
r15107r15108
24942494
24952495//-------------------------------------------------
24962496//  insert_field - insert a new field, checking
2497//   for errors
2497//  for errors
24982498//-------------------------------------------------
24992499
25002500void ioport_port::insert_field(ioport_field &newfield, ioport_value &disallowedbits, astring &errorbuf)
r15107r15108
25122512   for (ioport_field *field = first_field(); field != NULL; field = nextfield)
25132513   {
25142514      nextfield = field->next();
2515      if ((field->mask() & newfield.mask()) != 0 &&
2515      if ((field->mask() & newfield.mask()) != 0 &&
25162516         (newfield.condition().none() || field->condition().none() || field->condition() == newfield.condition()))
25172517      {
25182518         // reduce the mask of the field we found
r15107r15108
25692569      analog_field *analog = NULL;
25702570      if (field->is_analog())
25712571         analog = &analoglist.append(*global_alloc(analog_field(*field)));
2572     
2572
25732573      // allocate a dynamic field for reading
25742574      if (field->has_dynamic_read())
25752575         readlist.append(*global_alloc(dynamic_field(*field)));
2576         
2576
25772577      // allocate a dynamic field for writing
25782578      if (field->has_dynamic_write())
25792579         writelist.append(*global_alloc(dynamic_field(*field)));
2580     
2580
25812581      // let the field initialize its live state
25822582      field->init_live_state(analog);
25832583   }
r15107r15108
26102610
26112611//-------------------------------------------------
26122612//  initialize - walk the configured ports and
2613//   create live state information
2613//  create live state information
26142614//-------------------------------------------------
26152615
26162616time_t ioport_manager::initialize()
r15107r15108
27482748
27492749
27502750//-------------------------------------------------
2751//  exit - exit callback to ensure we clean up
2751//  exit - exit callback to ensure we clean up
27522752//  and close our files
27532753//-------------------------------------------------
27542754
r15107r15108
27612761
27622762
27632763//-------------------------------------------------
2764//  type_name - return the name for the given
2764//  type_name - return the name for the given
27652765//  type/player
27662766//-------------------------------------------------
27672767
r15107r15108
27782778
27792779
27802780//-------------------------------------------------
2781//  type_group - return the group for the given
2781//  type_group - return the group for the given
27822782//  type/player
27832783//-------------------------------------------------
27842784
r15107r15108
27942794
27952795
27962796//-------------------------------------------------
2797//  type_seq - return the input sequence for the
2797//  type_seq - return the input sequence for the
27982798//  given type/player
27992799//-------------------------------------------------
28002800
r15107r15108
28142814
28152815
28162816//-------------------------------------------------
2817//  set_type_seq - change the input sequence for
2817//  set_type_seq - change the input sequence for
28182818//  the given type/player
28192819//-------------------------------------------------
28202820
r15107r15108
28272827
28282828
28292829//-------------------------------------------------
2830//  type_pressed - return true if the sequence for
2830//  type_pressed - return true if the sequence for
28312831//  the given input type/player is pressed
28322832//-------------------------------------------------
28332833
r15107r15108
28532853
28542854
28552855//-------------------------------------------------
2856//  has_keyboard - determine if there is a
2856//  has_keyboard - determine if there is a
28572857//  keyboard present in the control list
28582858//-------------------------------------------------
28592859
r15107r15108
28762876}
28772877
28782878//-------------------------------------------------
2879//  count_players - counts the number of active
2879//  count_players - counts the number of active
28802880//  players
28812881//-------------------------------------------------
28822882
r15107r15108
28932893
28942894
28952895//-------------------------------------------------
2896//  crosshair_position - return the extracted
2896//  crosshair_position - return the extracted
28972897//  crosshair values for the given player
28982898//-------------------------------------------------
28992899
r15107r15108
29172917
29182918
29192919//-------------------------------------------------
2920//  update_defaults - force an update to the input
2920//  update_defaults - force an update to the input
29212921//  port values based on current conditions
29222922//-------------------------------------------------
29232923
r15107r15108
29532953   for (digital_joystick *joystick = m_joystick_list.first(); joystick != NULL; joystick = joystick->next())
29542954      if (joystick->player() == player && joystick->number() == number)
29552955         return *joystick;
2956   
2956
29572957   // create a new one
29582958   return m_joystick_list.append(*global_alloc(digital_joystick(player, number)));
29592959}
r15107r15108
29722972
29732973
29742974//-------------------------------------------------
2975//  frame_update_internal - core logic for
2976//   per-frame input port updating
2975//  frame_update_internal - core logic for
2976//  per-frame input port updating
29772977//-------------------------------------------------
29782978
29792979void ioport_manager::frame_update()
r15107r15108
30313031
30323032
30333033//-------------------------------------------------
3034//  frame_interpolate - interpolate between two
3034//  frame_interpolate - interpolate between two
30353035//  values based on the time between frames
30363036//-------------------------------------------------
30373037
r15107r15108
32303230//**************************************************************************
32313231
32323232//-------------------------------------------------
3233//  save_config - config callback for saving input
3233//  save_config - config callback for saving input
32343234//  port configuration
32353235//-------------------------------------------------
32363236
r15107r15108
32703270
32713271
32723272//-------------------------------------------------
3273//  save_this_input_field_type - determine if the
3273//  save_this_input_field_type - determine if the
32743274//  given port type is worth saving
32753275//-------------------------------------------------
32763276
r15107r15108
32833283      case IPT_PORT:
32843284      case IPT_UNKNOWN:
32853285         return false;
3286     
3286
32873287      default:
32883288         break;
32893289   }
r15107r15108
33403340void ioport_manager::save_game_inputs(xml_data_node *parentnode)
33413341{
33423342   // iterate over ports
3343   for (ioport_port *port = machine().ioport().first_port(); port != NULL; port = port->next())
3343   for (ioport_port *port = first_port(); port != NULL; port = port->next())
33443344      for (ioport_field *field = port->first_field(); field != NULL; field = field->next())
33453345         if (save_this_input_field_type(field->type()))
33463346         {
r15107r15108
36033603   if (filename[0] == 0)
36043604      return;
36053605
3606   // open the record file
3606   // open the record file
36073607   file_error filerr = m_record_file.open(filename);
36083608   assert_always(filerr == FILERR_NONE, "Failed to open file for recording");
36093609
r15107r15108
37653765   // create the full tag
37663766   astring fulltag;
37673767   m_owner.subtag(fulltag, tag);
3768   
3768
37693769   // add it to the list, and reset current field/setting
37703770   m_curport = &m_portlist.append(fulltag, *global_alloc(ioport_port(m_owner, fulltag)));
37713771   m_curfield = NULL;
r15107r15108
37883788   m_curport = m_portlist.find(fulltag.cstr());
37893789   if (m_curport == NULL)
37903790      throw emu_fatalerror("Requested to modify nonexistent port '%s'", fulltag.cstr());
3791   
3791
37923792   // bump the modification count, and reset current field/setting
37933793   m_curport->m_modcount++;
37943794   m_curfield = NULL;
r15107r15108
38583858
38593859//-------------------------------------------------
38603860//  set_condition - set the condition for either
3861//   the current setting or field
3861//  the current setting or field
38623862//-------------------------------------------------
38633863
38643864void ioport_configurer::set_condition(ioport_condition::condition_t condition, const char *tag, ioport_value mask, ioport_value value)
r15107r15108
38833883      field_set_toggle();
38843884      m_curfield->m_seq[SEQ_TYPE_STANDARD].set(KEYCODE_F2);
38853885   }
3886   
3886
38873887   // expand the diplocation
38883888   if (diplocation != NULL)
38893889      field_set_diplocation(diplocation);
r15107r15108
39433943
39443944//-------------------------------------------------
39453945//  read - read the updated value and merge it
3946//   into the target
3946//  into the target
39473947//-------------------------------------------------
39483948
39493949void dynamic_field::read(ioport_value &result)
r15107r15108
39513951   // skip if not enabled
39523952   if (!m_field.enabled())
39533953      return;
3954   
3954
39553955   // call the callback to read a new value
39563956   ioport_value newval = m_field.m_read(m_field, m_field.m_read_param);
39573957   m_oldval = newval;
3958   
3958
39593959   // merge in the bits (don't invert yet, as all digitals are inverted together)
39603960   result = (result & ~m_field.mask()) | ((newval << m_shift) & m_field.mask());
39613961}
r15107r15108
39633963
39643964//-------------------------------------------------
39653965//  write - track a change to a value and call
3966//   the write callback if there's something new
3966//  the write callback if there's something new
39673967//-------------------------------------------------
39683968
39693969void dynamic_field::write(ioport_value newval)
r15107r15108
41664166
41674167
41684168//-------------------------------------------------
4169//  apply_min_max - clamp the given input value to
4169//  apply_min_max - clamp the given input value to
41704170//  the appropriate min/max for the analog control
41714171//-------------------------------------------------
41724172
r15107r15108
42034203
42044204//-------------------------------------------------
42054205//  apply_sensitivity - apply a sensitivity
4206//   adjustment for a current value
4206//  adjustment for a current value
42074207//-------------------------------------------------
42084208
42094209inline INT32 analog_field::apply_sensitivity(INT32 value) const
r15107r15108
42134213
42144214
42154215//-------------------------------------------------
4216//  apply_inverse_sensitivity - reverse-apply the
4217//   sensitivity adjustment for a current value
4216//  apply_inverse_sensitivity - reverse-apply the
4217//  sensitivity adjustment for a current value
42184218//-------------------------------------------------
42194219
42204220inline INT32 analog_field::apply_inverse_sensitivity(INT32 value) const
r15107r15108
42244224
42254225
42264226//-------------------------------------------------
4227//  apply_settings - return the value of an
4227//  apply_settings - return the value of an
42284228//  analog input
42294229//-------------------------------------------------
42304230
r15107r15108
42544254
42554255
42564256//-------------------------------------------------
4257//  frame_update - update the internals of a
4257//  frame_update - update the internals of a
42584258//  single analog field periodically
42594259//-------------------------------------------------
42604260
r15107r15108
43964396
43974397//-------------------------------------------------
43984398//  read - read the current value and insert into
4399//   the provided ioport_value
4399//  the provided ioport_value
44004400//-------------------------------------------------
44014401
44024402void analog_field::read(ioport_value &result)
r15107r15108
44304430
44314431//-------------------------------------------------
44324432//  crosshair_read - read a value for crosshairs,
4433//   scaled between 0 and 1
4433//  scaled between 0 and 1
44344434//-------------------------------------------------
44354435
44364436float analog_field::crosshair_read()
r15107r15108
45124512/*
45134513int validate_natural_keyboard_statics(void)
45144514{
4515   int i;
4516   int error = FALSE;
4517   unicode_char last_char = 0;
4518   const char_info *ci;
4515    int i;
4516    int error = FALSE;
4517    unicode_char last_char = 0;
4518    const char_info *ci;
45194519
4520   // check to make sure that charinfo is in order
4521   for (i = 0; i < ARRAY_LENGTH(charinfo); i++)
4522   {
4523      if (last_char >= charinfo[i].ch)
4524      {
4525         mame_printf_error("inputx: charinfo is out of order; 0x%08x should be higher than 0x%08x\n", charinfo[i].ch, last_char);
4526         error = TRUE;
4527      }
4528      last_char = charinfo[i].ch;
4529   }
4520    // check to make sure that charinfo is in order
4521    for (i = 0; i < ARRAY_LENGTH(charinfo); i++)
4522    {
4523        if (last_char >= charinfo[i].ch)
4524        {
4525            mame_printf_error("inputx: charinfo is out of order; 0x%08x should be higher than 0x%08x\n", charinfo[i].ch, last_char);
4526            error = TRUE;
4527        }
4528        last_char = charinfo[i].ch;
4529    }
45304530
4531   // check to make sure that I can look up everything on alternate_charmap
4532   for (i = 0; i < ARRAY_LENGTH(charinfo); i++)
4533   {
4534      ci = char_info::find(charinfo[i].ch);
4535      if (ci != &charinfo[i])
4536      {
4537         mame_printf_error("ioport: expected char_info::find(0x%08x) to work properly\n", charinfo[i].ch);
4538         error = TRUE;
4539      }
4540   }
4541   return error;
4531    // check to make sure that I can look up everything on alternate_charmap
4532    for (i = 0; i < ARRAY_LENGTH(charinfo); i++)
4533    {
4534        ci = char_info::find(charinfo[i].ch);
4535        if (ci != &charinfo[i])
4536        {
4537            mame_printf_error("ioport: expected char_info::find(0x%08x) to work properly\n", charinfo[i].ch);
4538            error = TRUE;
4539        }
4540    }
4541    return error;
45424542}
45434543*/
45444544
src/emu/ioport.h
r15107r15108
194194      IPT_JOYSTICKLEFT_DOWN,
195195      IPT_JOYSTICKLEFT_LEFT,
196196      IPT_JOYSTICKLEFT_RIGHT,
197   
197
198198   IPT_DIGITAL_JOYSTICK_LAST,
199199
200200   // action buttons
r15107r15108
217217
218218   // mahjong inputs
219219   IPT_MAHJONG_FIRST,
220   
220
221221      IPT_MAHJONG_A,
222222      IPT_MAHJONG_B,
223223      IPT_MAHJONG_C,
r15107r15108
247247      IPT_MAHJONG_FLIP_FLOP,
248248      IPT_MAHJONG_BIG,
249249      IPT_MAHJONG_SMALL,
250   
250
251251   IPT_MAHJONG_LAST,
252252
253253   // hanafuda inputs
r15107r15108
263263      IPT_HANAFUDA_H,
264264      IPT_HANAFUDA_YES,
265265      IPT_HANAFUDA_NO,
266   
266
267267   IPT_HANAFUDA_LAST,
268268
269269   // gambling inputs
r15107r15108
325325
326326   // analog inputs
327327   IPT_ANALOG_FIRST,
328   
328
329329      IPT_ANALOG_ABSOLUTE_FIRST,
330330
331331         IPT_AD_STICK_X,      // absolute // autocenter
r15107r15108
340340         IPT_LIGHTGUN_Y,      // absolute
341341         IPT_POSITIONAL,      // absolute // autocenter if not wraps
342342         IPT_POSITIONAL_V,   // absolute // autocenter if not wraps
343     
343
344344      IPT_ANALOG_ABSOLUTE_LAST,
345345
346346      IPT_DIAL,         // relative
r15107r15108
349349      IPT_TRACKBALL_Y,   // relative
350350      IPT_MOUSE_X,      // relative
351351      IPT_MOUSE_Y,      // relative
352   
352
353353   IPT_ANALOG_LAST,
354354
355355   // analog adjuster support
r15107r15108
414414      IPT_OSD_14,
415415      IPT_OSD_15,
416416      IPT_OSD_16,
417   
417
418418   IPT_UI_LAST,
419419
420420   // other meaning not mapped to standard defaults
r15107r15108
750750   const char *name() const { return m_name; }
751751   input_seq &defseq(input_seq_type seqtype = SEQ_TYPE_STANDARD) { return m_defseq[seqtype]; }
752752   const input_seq &seq(input_seq_type seqtype = SEQ_TYPE_STANDARD) const { return m_seq[seqtype]; }
753   
753
754754   // setters
755755   void configure_osd(const char *token, const char *name);
756   
756
757757private:
758758   // internal state
759759   input_type_entry *   m_next;            // next description in the list
r15107r15108
785785      JOYDIR_RIGHT,
786786      JOYDIR_COUNT
787787   };
788   
788
789789   // bit constants
790790   static const UINT8 UP_BIT = 1 << JOYDIR_UP;
791791   static const UINT8 DOWN_BIT = 1 << JOYDIR_DOWN;
r15107r15108
794794
795795   // construction/destruction
796796   digital_joystick(int player, int number);
797   
797
798798   // getters
799799   digital_joystick *next() const { return m_next; }
800800   int player() const { return m_player; }
801801   int number() const { return m_number; }
802802   UINT8 current() const { return m_current; }
803803   UINT8 current4way() const { return m_current4way; }
804   
804
805805   // configuration
806806   direction_t set_axis(ioport_field &field);
807807
808808   // updates
809809   void frame_update();
810   
810
811811private:
812812   // internal state
813813   digital_joystick *   m_next;               // next joystick in the list
r15107r15108
831831public:
832832   // construction/destruction
833833   natural_keyboard(running_machine &machine);
834   
834
835835   // getters and queries
836836   running_machine &machine() const { return m_machine; }
837837   bool empty() const { return (m_bufbegin == m_bufend); }
r15107r15108
855855   // internal keyboard code information
856856   struct keycode_map_entry
857857   {
858      unicode_char    ch;
858      unicode_char   ch;
859859      ioport_field *   field[UCHAR_SHIFT_END + 1 - UCHAR_SHIFT_BEGIN];
860860   };
861861
r15107r15108
881881   bool               m_status_keydown;      // current keydown status
882882   bool               m_last_cr;            // was the last char a CR?
883883   emu_timer *            m_timer;            // timer for posting characters
884   attotime             m_current_rate;         // current rate for posting
884   attotime            m_current_rate;         // current rate for posting
885885   ioport_queue_chars_delegate m_queue_chars;      // queue characters callback
886886   ioport_accept_char_delegate m_accept_char;      // accept character callback
887887   ioport_charqueue_empty_delegate m_charqueue_empty; // character queue empty callback
r15107r15108
913913
914914   // getters
915915   const char *tag() const { return m_tag; }
916   
916
917917   // operators
918918   bool operator==(const ioport_condition &rhs) const { return (m_mask == rhs.m_mask && m_value == rhs.m_value && m_condition == rhs.m_condition && strcmp(m_tag, rhs.m_tag) == 0); }
919919   bool eval(device_t &device) const;
r15107r15108
949949public:
950950   // construction/destruction
951951   ioport_setting(ioport_field &field, ioport_value value, const char *name);
952   
952
953953   // getters
954954   ioport_setting *next() const { return m_next; }
955955   ioport_field &field() const { return m_field; }
r15107r15108
983983public:
984984   // construction/destruction
985985   ioport_diplocation(const char *name, UINT8 swnum, bool invert);
986   
986
987987   // getters
988988   ioport_diplocation *next() const { return m_next; }
989989   const char *name() const { return m_name; }
r15107r15108
10391039   ioport_type type() const { return m_type; }
10401040   UINT8 player() const { return m_player; }
10411041
1042   bool unused() const { return ((m_flags & FIELD_FLAG_UNUSED) != 0); }
1043   bool cocktail() const { return ((m_flags & FIELD_FLAG_COCKTAIL) != 0); }
1044   bool toggle() const { return ((m_flags & FIELD_FLAG_TOGGLE) != 0); }
1045   bool rotated() const { return ((m_flags & FIELD_FLAG_ROTATED) != 0); }
1046   bool analog_reverse() const { return ((m_flags & ANALOG_FLAG_REVERSE) != 0); }
1047   bool analog_reset() const { return ((m_flags & ANALOG_FLAG_RESET) != 0); }
1048   bool analog_wraps() const { return ((m_flags & ANALOG_FLAG_WRAPS) != 0); }
1049   bool analog_invert() const { return ((m_flags & ANALOG_FLAG_INVERT) != 0); }
1042   bool unused() const { return ((m_flags & FIELD_FLAG_UNUSED) != 0); }
1043   bool cocktail() const { return ((m_flags & FIELD_FLAG_COCKTAIL) != 0); }
1044   bool toggle() const { return ((m_flags & FIELD_FLAG_TOGGLE) != 0); }
1045   bool rotated() const { return ((m_flags & FIELD_FLAG_ROTATED) != 0); }
1046   bool analog_reverse() const { return ((m_flags & ANALOG_FLAG_REVERSE) != 0); }
1047   bool analog_reset() const { return ((m_flags & ANALOG_FLAG_RESET) != 0); }
1048   bool analog_wraps() const { return ((m_flags & ANALOG_FLAG_WRAPS) != 0); }
1049   bool analog_invert() const { return ((m_flags & ANALOG_FLAG_INVERT) != 0); }
10501050
10511051   UINT8 impulse() const { return m_impulse; }
10521052   const char *name() const;
10531053   const char *specific_name() const { return m_name; }
10541054   const input_seq &seq(input_seq_type seqtype = SEQ_TYPE_STANDARD) const;
10551055   const input_seq &defseq(input_seq_type seqtype = SEQ_TYPE_STANDARD) const;
1056   const input_seq &defseq_unresolved(input_seq_type seqtype = SEQ_TYPE_STANDARD) const { return m_seq[seqtype]; }
10561057   bool has_dynamic_read() const { return !m_read.isnull(); }
10571058   bool has_dynamic_write() const { return !m_write.isnull(); }
1058   
1059
10591060   ioport_value minval() const { return m_min; }
10601061   ioport_value maxval() const { return m_max; }
10611062   INT32 sensitivity() const { return m_sensitivity; }
r15107r15108
10661067   double crosshair_offset() const { return m_crosshair_offset; }
10671068   UINT16 full_turn_count() const { return m_full_turn_count; }
10681069   const ioport_value *remap_table() const { return m_remap_table; }
1069   
1070
10701071   UINT8 way() const { return m_way; }
10711072   unicode_char keyboard_code(int which) const;
10721073   ioport_field_live &live() const { assert(m_live != NULL); return *m_live; }
1073   
1074
10741075   // setters
10751076   void set_crosshair_scale(double scale) { m_crosshair_scale = scale; }
10761077   void set_crosshair_offset(double offset) { m_crosshair_offset = offset; }
r15107r15108
11141115   ioport_field_live *         m_live;            // live state of field (NULL if not live)
11151116   int                     m_modcount;         // modification count
11161117   simple_list<ioport_setting> m_settinglist;      // list of input_setting_configs
1117   simple_list<ioport_diplocation> m_diploclist;    // list of locations for various bits
1118   simple_list<ioport_diplocation> m_diploclist;   // list of locations for various bits
11181119
11191120   // generally-applicable data
11201121   ioport_value            m_mask;            // mask of bits belonging to the field
r15107r15108
11931194   ioport_value active() const { return m_active; }
11941195   ioport_value active_safe(ioport_value defval) const { return (this == NULL) ? defval : active(); }
11951196   ioport_port_live &live() const { assert(m_live != NULL); return *m_live; }
1196   
1197
11971198   // read/write to the port
11981199   ioport_value read();
11991200   ioport_value read_safe(ioport_value defval) { return (this == NULL) ? defval : read(); }
r15107r15108
12121213   // internal state
12131214   ioport_port *            m_next;         // pointer to next port
12141215   device_t &               m_device;      // associated device
1215   simple_list<ioport_field>    m_fieldlist;   // list of ioport_fields
1216   simple_list<ioport_field>   m_fieldlist;   // list of ioport_fields
12161217   astring                  m_tag;         // copy of this port's tag
12171218   int                     m_modcount;      // modification count
12181219   ioport_value            m_active;      // mask of active bits in the port
r15107r15108
13771378   device_t &         m_owner;
13781379   ioport_list &      m_portlist;
13791380   astring &         m_errorbuf;
1380   
1381
13811382   ioport_port *      m_curport;
13821383   ioport_field *      m_curfield;
13831384   ioport_setting *   m_cursetting;
src/emu/uimain.c
r15107r15108
130130   device_iterator deviter(machine().root_device());
131131   for (device_t *device = deviter.first(); device != NULL; device = deviter.next())
132132      if (device->rom_region())
133         for (const rom_entry *rom = device->rom_region(); !ROMENTRY_ISEND(rom); rom++)
133         for (const rom_entry *rom = device->rom_region(); !ROMENTRY_ISEND(rom); rom++)
134134            if (ROMENTRY_ISSYSTEM_BIOS(rom)) { has_bioses= true; break; }
135135
136136   /* add input menu items */
r15107r15108
319319      case BIOS_SELECTION:
320320         ui_menu::stack_push(auto_alloc_clear(machine(), ui_menu_bios_selection(machine(), container)));
321321         break;
322         
322
323323      default:
324324         fatalerror("ui_menu_main::handle - unknown reference");
325325      }
r15107r15108
496496   {
497497      if (device->rom_region()) {
498498         const char *val = "default";
499         for (const rom_entry *rom = device->rom_region(); !ROMENTRY_ISEND(rom); rom++)
499         for (const rom_entry *rom = device->rom_region(); !ROMENTRY_ISEND(rom); rom++)
500500         {
501501            if (ROMENTRY_ISSYSTEM_BIOS(rom) && ROM_GETBIOSFLAGS(rom)==device->system_bios())
502502            {
r15107r15108
529529      if (menu_event->iptkey == IPT_UI_LEFT || menu_event->iptkey == IPT_UI_RIGHT) {
530530         device_t *dev = (device_t *)menu_event->itemref;
531531         int cnt = 0;
532         for (const rom_entry *rom = dev->rom_region(); !ROMENTRY_ISEND(rom); rom++)
532         for (const rom_entry *rom = dev->rom_region(); !ROMENTRY_ISEND(rom); rom++)
533533         {
534534            if (ROMENTRY_ISSYSTEM_BIOS(rom)) cnt ++;
535535         }
r15107r15108
763763               if(pollingitem && pollingref == field && pollingseq == seqtype)
764764                  pollingitem = item;
765765               item->seq = field->seq(seqtype);
766               item->defseq = &get_field_default_seq(field, seqtype);
766               item->defseq = &field->defseq(seqtype);
767767               item->sortorder = sortorder + suborder[seqtype];
768768               item->type = field->is_analog() ? (INPUT_TYPE_ANALOG + seqtype) : INPUT_TYPE_DIGITAL;
769769               item->name = name;
r15107r15108
815815      selected_seq.reset();
816816}
817817
818/*-------------------------------------------------
819    get_field_default_seq - return a pointer
820    to the default sequence for the given field
821-------------------------------------------------*/
822
823const input_seq &ui_menu_input::get_field_default_seq(ioport_field *field, input_seq_type seqtype)
824{
825   if (field->seq(seqtype).is_default())
826      return field->machine().ioport().type_seq(field->type(), field->player(), seqtype);
827   else
828      return field->seq(seqtype);
829}
830
831818void ui_menu_input::handle()
832819{
833820   input_item_data *seqchangeditem = NULL;
r15107r15108
13851372               case IPT_PEDAL3:
13861373                  use_autocenter = true;
13871374                  break;
1388               
1375
13891376               default:
13901377                  break;
13911378            }
src/emu/uimain.h
r15107r15108
121121   void populate_and_sort(struct input_item_data *itemlist);
122122   virtual void update_input(struct input_item_data *seqchangeditem) = 0;
123123   void toggle_none_default(input_seq &selected_seq, input_seq &original_seq, const input_seq &selected_defseq);
124   const input_seq &get_field_default_seq(ioport_field *field, input_seq_type seqtype);
125124
126125protected:
127126   const void *      pollingref;
src/emu/disound.c
r15107r15108
240240
241241//-------------------------------------------------
242242//  inputnum_from_device - return the input number
243//   that is connected to the given device's output
243//  that is connected to the given device's output
244244//-------------------------------------------------
245245
246246int device_sound_interface::inputnum_from_device(device_t &source_device, int outputnum) const
src/emu/machine/rp5c15.c
r15107r15108
291291
292292
293293//-------------------------------------------------
294//  rtc_clock_updated -
294//  rtc_clock_updated -
295295//-------------------------------------------------
296296
297297void rp5c15_device::rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second)
r15107r15108
395395         m_reg[mode][offset & 0x0f] = data & REGISTER_WRITE_MASK[mode][offset & 0x0f];
396396
397397         set_time(false, read_counter(REGISTER_1_YEAR), read_counter(REGISTER_1_MONTH), read_counter(REGISTER_1_DAY), m_reg[MODE00][REGISTER_DAY_OF_THE_WEEK],
398            read_counter(REGISTER_1_HOUR), read_counter(REGISTER_1_MINUTE), read_counter(REGISTER_1_SECOND));
398            read_counter(REGISTER_1_HOUR), read_counter(REGISTER_1_MINUTE), read_counter(REGISTER_1_SECOND));
399399         break;
400400
401401      case MODE01:
src/emu/machine/ds1302.c
r15107r15108
99
1010/*
1111
12   TODO:
12    TODO:
1313
14   - 12 hour format
15   - synchronize user buffers on falling edge of CE after write
14    - 12 hour format
15    - synchronize user buffers on falling edge of CE after write
1616
1717*/
1818
r15107r15108
115115void ds1302_device::device_reset()
116116{
117117   set_current_time(machine());
118   
118
119119   m_clk = 0;
120120   m_ce = 0;
121121   m_state = STATE_COMMAND;
122   m_bits = 0;   
122   m_bits = 0;
123123}
124124
125125
r15107r15108
170170
171171
172172//-------------------------------------------------
173//  rtc_clock_updated -
173//  rtc_clock_updated -
174174//-------------------------------------------------
175175
176176void ds1302_device::rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second)
r15107r15108
231231         m_data = m_user[m_addr];
232232
233233         if (LOG) logerror("DS1302 '%s' Read Clock %u:%02x\n", tag(), m_addr, m_data);
234      }                 
234      }
235235   }
236236   else
237237   {
r15107r15108
246246         if (LOG) logerror("DS1302 '%s' Write Clock %u:%02x\n", tag(), m_addr, m_data);
247247
248248         m_reg[m_addr] = m_data;
249      }     
249      }
250250   }
251251}
252252
src/emu/machine/msm5832.c
r15107r15108
151151
152152
153153//-------------------------------------------------
154//  rtc_clock_updated -
154//  rtc_clock_updated -
155155//-------------------------------------------------
156156
157157void msm5832_device::rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second)
src/emu/machine/msm5832.h
r15107r15108
6767    // device-level overrides
6868    virtual void device_start();
6969    virtual void device_reset();
70      virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
70   virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
7171
7272   // device_rtc_interface overrides
7373   virtual void rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second);
src/emu/machine/intelfsh.c
r15107r15108
832832
833833      if (m_byte_count == m_page_size)
834834      {
835         m_flash_mode = FM_NORMAL;         
835         m_flash_mode = FM_NORMAL;
836836      }
837837      break;
838838   case FM_CLEARPART1:
src/emu/machine/intelfsh.h
r15107r15108
122122   UINT8               m_device_id;
123123   UINT8               m_maker_id;
124124   bool               m_sector_is_4k;
125   UINT8                m_page_size;
125   UINT8               m_page_size;
126126
127127   // internal state
128128   UINT8               m_status;
src/emu/machine/rp5c01.c
r15107r15108
270270
271271
272272//-------------------------------------------------
273//  rtc_clock_updated -
273//  rtc_clock_updated -
274274//-------------------------------------------------
275275
276276void rp5c01_device::rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second)
r15107r15108
420420         m_reg[mode][offset & 0x0f] = data & REGISTER_WRITE_MASK[mode][offset & 0x0f];
421421
422422         set_time(false, read_counter(REGISTER_1_YEAR), read_counter(REGISTER_1_MONTH), read_counter(REGISTER_1_DAY), m_reg[MODE00][REGISTER_DAY_OF_THE_WEEK],
423            read_counter(REGISTER_1_HOUR), read_counter(REGISTER_1_MINUTE), read_counter(REGISTER_1_SECOND));
423            read_counter(REGISTER_1_HOUR), read_counter(REGISTER_1_MINUTE), read_counter(REGISTER_1_SECOND));
424424         break;
425425
426426      case BLOCK10:
src/emu/machine/mc146818.c
r15107r15108
300300
301301
302302//-------------------------------------------------
303//  rtc_clock_updated -
303//  rtc_clock_updated -
304304//-------------------------------------------------
305305
306306void mc146818_device::rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second)
src/emu/screen.c
r15107r15108
783783
784784//-------------------------------------------------
785785//  vblank_port_read - custom port handler to
786//   return a VBLANK state
786//  return a VBLANK state
787787//-------------------------------------------------
788788
789789int screen_device::vblank_port_read()
src/emu/sound.c
r15107r15108
144144
145145
146146//-------------------------------------------------
147//  user_gain - return the user-controllable gain
147//  user_gain - return the user-controllable gain
148148//  on a given stream's input
149149//-------------------------------------------------
150150
r15107r15108
217217
218218
219219//-------------------------------------------------
220//  input_source_device - return the device
220//  input_source_device - return the device
221221//  attached as a given input's source
222222//-------------------------------------------------
223223
r15107r15108
229229
230230
231231//-------------------------------------------------
232//  input_source_device - return the output number
232//  input_source_device - return the output number
233233//  attached as a given input's source
234234//-------------------------------------------------
235235
src/lib/formats/dfi_dsk.c
r15107r15108
151151         } else // (v & 0x80) == 0
152152            total_time += v & 0x7f;
153153      }
154     
154
155155      // its possible on single read images for there to be no index pulse during the image at all!
156156      if (onerev_time == 0) onerev_time = total_time;
157157
src/lib/formats/ap2_dsk.c
r15107r15108
11001100                  visualgrid[se][0] |= ADDRFOUND;
11011101                  visualgrid[se][0] |= ((chk ^ vl ^ tr ^ se)==0)?ADDRGOOD:0;
11021102#ifdef LENIENT_ADDR_CHECK
1103//                     if ((visualgrid[se][0] & ADDRFOUND) == ADDRFOUND) {
1103//                          if ((visualgrid[se][0] & ADDRFOUND) == ADDRFOUND) {
11041104#else
11051105                     if ((visualgrid[se][0] & ADDRGOOD) == ADDRGOOD) {
11061106#endif
r15107r15108
12171217            io_generic_write(io, data, pos_data, 256);
12181218            pos_data += 256;
12191219      }
1220     
1220
12211221      // for the rest of the tracks
12221222      for(int track=2; track < 70; track+=2) {
12231223            UINT8 sectdata[(768)*6];
r15107r15108
12621262                        visualgrid[se][track/2] |= ADDRFOUND;
12631263                        visualgrid[se][track/2] |= ((chk ^ tr ^ se)==0)?ADDRGOOD:0;
12641264#ifdef LENIENT_ADDR_CHECK
1265//                           if ((visualgrid[se][track/2] & ADDRFOUND) == ADDRFOUND) {
1265//                                  if ((visualgrid[se][track/2] & ADDRFOUND) == ADDRFOUND) {
12661266#else
12671267                           if ((visualgrid[se][track/2] & ADDRGOOD) == ADDRGOOD) {
12681268#endif
r15107r15108
12801280                                 data[i] = gcr6bw_tb[gb(buf, ts, pos, wrap)] ;//^ c;
12811281                                 c ^= data[i];
12821282                                 /*if (((i&0x3)+1)==0x04) {
1283                                    printf("%c", ((((data[i-3]&0x30)<<2)|((data[i-2]&0x3F)>>0))&0x3F)+0x40);
1284                                    printf("%c", ((((data[i-3]&0x0C)<<4)|((data[i-1]&0x3F)>>0))&0x3F)+0x40);
1285                                    printf("%c", ((((data[i-3]&0x03)<<6)|((data[i-0]&0x3F)>>0))&0x3F)+0x40);
1286                                    *dest++ = ((data[i-3]&0x30)<<2)|((data[i-2]&0x3F)>>0);
1287                                    *dest++ = ((data[i-3]&0x0C)<<4)|((data[i-1]&0x3F)>>0);
1288                                    *dest++ = ((data[i-3]&0x03)<<6)|((data[i-0]&0x3F)>>0);
1289                                 }*/
1283                                                printf("%c", ((((data[i-3]&0x30)<<2)|((data[i-2]&0x3F)>>0))&0x3F)+0x40);
1284                                                printf("%c", ((((data[i-3]&0x0C)<<4)|((data[i-1]&0x3F)>>0))&0x3F)+0x40);
1285                                                printf("%c", ((((data[i-3]&0x03)<<6)|((data[i-0]&0x3F)>>0))&0x3F)+0x40);
1286                                                *dest++ = ((data[i-3]&0x30)<<2)|((data[i-2]&0x3F)>>0);
1287                                                *dest++ = ((data[i-3]&0x0C)<<4)|((data[i-1]&0x3F)>>0);
1288                                                *dest++ = ((data[i-3]&0x03)<<6)|((data[i-0]&0x3F)>>0);
1289                                            }*/
12901290                              //  printf("%02x ", data[i]);
12911291                              //  if (((i&0xf)+1)==0x10) printf("\n");
12921292                              }
r15107r15108
12971297                                    dpost <<= 8;
12981298                                    dpost |= gb(buf, ts, pos, wrap);
12991299                              }
1300                             
1300
13011301                              /*if (se == 0) // dump some debug data to help find the lfsr before sector 5
1302                              {
1303                                 printf("Data Postamble was 0x%08x\n", dpost);
1304                                 for(int i=0; i<0x400; i++) {
1305                                    data[i] = gcr6bw_tb[gb(buf, ts, pos, wrap)] ;//^ c;
1306                                    c ^= data[i];
1307                                printf("%02x ", data[i]);
1308                                if (((i&0xf)+1)==0x10) printf("\n");
1309                                 }
1310                              }*/
1302                                        {
1303                                            printf("Data Postamble was 0x%08x\n", dpost);
1304                                            for(int i=0; i<0x400; i++) {
1305                                                data[i] = gcr6bw_tb[gb(buf, ts, pos, wrap)] ;//^ c;
1306                                                c ^= data[i];
1307                                          printf("%02x ", data[i]);
1308                                          if (((i&0xf)+1)==0x10) printf("\n");
1309                                            }
1310                                        }*/
13111311
13121312                              // only write it if the bitfield of the track shows datagood is NOT set.
13131313                              // if it is set we don't want to overwrite a guaranteed good read with a bad one
r15107r15108
13871387                                 fprintf(stderr,"Data Mark:\tChecksum xpctd %d found %d: %s, Postamble %03X: %s\n", data[0x400], c, (data[0x400]==c)?"OK":"BAD", dpost, (dpost&0xFF000000)==0xD4000000?"OK":"BAD");
13881388                              if (data[0x400] == c) visualgrid[se][track/2] |= DATAGOOD;
13891389                              if ((dpost&0xFF000000)==0xD4000000) visualgrid[se][track/2] |= DATAPOST;
1390                           }
1390                           }
13911391                        }
13921392                        hb = 0;
13931393                  }
r15107r15108
14231423      return true;
14241424}
14251425
1426const floppy_format_type FLOPPY_RWTS18_FORMAT = &floppy_image_format_creator<a2_rwts18_format>;
No newline at end of file
1426const floppy_format_type FLOPPY_RWTS18_FORMAT = &floppy_image_format_creator<a2_rwts18_format>;
src/lib/libflac/libflac/memory.c
r15107r15108
8484   FLAC__ASSERT(0 != aligned_pointer);
8585   FLAC__ASSERT(unaligned_pointer != aligned_pointer);
8686
87//   if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
88//      return false;
87//  if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
88//      return false;
8989
9090   pu = (FLAC__int32*)FLAC__memory_alloc_aligned(sizeof(*pu) * (size_t)elements, &u.pv);
9191   if(0 == pu) {
r15107r15108
113113   FLAC__ASSERT(0 != aligned_pointer);
114114   FLAC__ASSERT(unaligned_pointer != aligned_pointer);
115115
116//   if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
117//      return false;
116//  if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
117//      return false;
118118
119119   pu = (FLAC__uint32*)FLAC__memory_alloc_aligned(sizeof(*pu) * elements, &u.pv);
120120   if(0 == pu) {
r15107r15108
142142   FLAC__ASSERT(0 != aligned_pointer);
143143   FLAC__ASSERT(unaligned_pointer != aligned_pointer);
144144
145//   if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
146//      return false;
145//  if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
146//      return false;
147147
148148   pu = (FLAC__uint64*)FLAC__memory_alloc_aligned(sizeof(*pu) * elements, &u.pv);
149149   if(0 == pu) {
r15107r15108
171171   FLAC__ASSERT(0 != aligned_pointer);
172172   FLAC__ASSERT(unaligned_pointer != aligned_pointer);
173173
174//   if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
175//      return false;
174//  if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
175//      return false;
176176
177177   pu = (unsigned*)FLAC__memory_alloc_aligned(sizeof(*pu) * elements, &u.pv);
178178   if(0 == pu) {
r15107r15108
202202   FLAC__ASSERT(0 != aligned_pointer);
203203   FLAC__ASSERT(unaligned_pointer != aligned_pointer);
204204
205//   if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
206//      return false;
205//  if((size_t)elements > SIZE_MAX / sizeof(*pu)) /* overflow check */
206//      return false;
207207
208208   pu = (FLAC__real*)FLAC__memory_alloc_aligned(sizeof(*pu) * elements, &u.pv);
209209   if(0 == pu) {
src/lib/util/avhuff.c
r15107r15108
675675   if (complength < 10 + 2 * channels)
676676      return AVHERR_INVALID_DATA;
677677   UINT32 totalsize = 10 + 2 * channels;
678   totalsize += (source[8] << 8) | source[9];
678   UINT32 treesize = (source[8] << 8) | source[9];
679   if (treesize != 0xffff)
680      totalsize += treesize;
679681   for (int chnum = 0; chnum < channels; chnum++)
680682      totalsize += (source[10 + 2 * chnum] << 8) | source[11 + 2 * chnum];
681683   if (totalsize >= complength)
src/version.c
r15107r15108
3838***************************************************************************/
3939
4040extern const char build_version[];
41const char build_version[] = "0.145u7 ("__DATE__")";
41const char build_version[] = "0.145u8 ("__DATE__")";
src/mess/machine/ay3600.c
r15107r15108
625625   return true;
626626}
627627
628 
629628
629
src/mess/machine/apple2gs.c
r15107r15108
13491349   {
13501350      meminfo->read_mem      = (state->m_flags & VAR_PAGE2)   ? 0x010400 : 0x000400;
13511351      meminfo->write_mem      = (state->m_flags & VAR_PAGE2)   ? 0x010400 : 0x000400;
1352      meminfo->write_handler   = (state->m_flags & VAR_PAGE2)   ? &write_delegates[0] : &write_delegates[1]; 
1352      meminfo->write_handler   = (state->m_flags & VAR_PAGE2)   ? &write_delegates[0] : &write_delegates[1];
13531353   }
13541354   else
13551355   {
13561356      meminfo->read_mem      = (state->m_flags & VAR_RAMRD)   ? 0x010400 : 0x000400;
13571357      meminfo->write_mem      = (state->m_flags & VAR_RAMWRT)   ? 0x010400 : 0x000400;
1358      meminfo->write_handler   = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1]; 
1358      meminfo->write_handler   = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];
13591359   }
13601360}
13611361
r15107r15108
13781378   {
13791379      meminfo->read_mem      = (state->m_flags & VAR_PAGE2)   ? 0x012000 : 0x002000;
13801380      meminfo->write_mem      = (state->m_flags & VAR_PAGE2)   ? 0x012000 : 0x002000;
1381      meminfo->write_handler   = (state->m_flags & VAR_PAGE2)   ? &write_delegates[0] : &write_delegates[1];   
1381      meminfo->write_handler   = (state->m_flags & VAR_PAGE2)   ? &write_delegates[0] : &write_delegates[1];
13821382   }
13831383   else
13841384   {
13851385      meminfo->read_mem      = (state->m_flags & VAR_RAMRD)   ? 0x012000 : 0x002000;
13861386      meminfo->write_mem      = (state->m_flags & VAR_RAMWRT)   ? 0x012000 : 0x002000;
1387      meminfo->write_handler   = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];   
1387      meminfo->write_handler   = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];
13881388   }
13891389}
13901390
r15107r15108
13971397        write8_delegate(FUNC(apple2gs_state::apple2gs_main4000_w), state)
13981398    };
13991399   meminfo->read_mem         = (state->m_flags & VAR_RAMRD)   ? 0x014000 : 0x004000;
1400   meminfo->write_handler      = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];   
1400   meminfo->write_handler      = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];
14011401}
14021402
14031403static void apple2gs_mem_xxD000(running_machine &machine,apple2_meminfo *meminfo, UINT32 lcmem)
src/mess/machine/3c505.c
r15107r15108
680680   LOG2(("set_command_pending %d m_rx_pending=%d m_rx_data_buffer.get_length()=%x%s",
681681         m_command_pending, m_rx_pending, m_rx_data_buffer.get_length(), onoff ? "" :"\n"));
682682
683//-   verbose = onoff ? 1 : 2;
683//- verbose = onoff ? 1 : 2;
684684
685685   if (!m_command_pending)
686686   {
r15107r15108
716716   switch (m_command_buffer[0])
717717   {
718718   case CMD_RESET: // 0x00
719//      FIXME:
720//      device_reset();
719//      FIXME:
720//      device_reset();
721721      break;
722722
723723   case CMD_CONFIGURE_ADAPTER_MEMORY: // 0x01
r15107r15108
10721072            m_tx_data_buffer.reset();
10731073            if (m_command_buffer[0] != CMD_MC_F9)
10741074            {
1075//               set_command_pending(0);
1075//                  set_command_pending(0);
10761076               m_wait_for_ack = 1;
10771077            }
10781078            break;
10791079
10801080         case CMD_DOWNLOAD_PROGRAM_RESPONSE:
10811081            m_program_buffer.reset();
1082//            set_command_pending(0);
1082//              set_command_pending(0);
10831083            m_wait_for_ack = 1;
10841084            break;
10851085
10861086         default:
1087//            set_command_pending(0);
1087//              set_command_pending(0);
10881088            m_wait_for_ack = 1;
10891089            break;
10901090         }
r15107r15108
12241224         m_status &= ~HRDY; /* data register no longer ready */
12251225         m_rx_data_buffer.log("Rx Data");
12261226         m_rx_data_buffer.reset();
1227//         set_command_pending(0);
1227//          set_command_pending(0);
12281228         m_wait_for_ack = 1;
12291229      }
12301230   }
r15107r15108
12911291      if (m_command_buffer[0] == CMD_MC_F9)
12921292      {
12931293         m_mc_f9_pending = 1;
1294//-         verbose = 2;
1294//-         verbose = 2;
12951295      }
12961296
12971297      if (data == 0x00)
src/mess/machine/c64_ide64.c
r15107r15108
1111 
1212    TODO:
1313 
14   - fast loader does not work with 1541
15   - graphics corruption during Ultimax mode (VIC issue?)
16   - IDE unknown command (E8)
14    - fast loader does not work with 1541
15    - graphics corruption during Ultimax mode (VIC issue?)
16    - IDE unknown command (E8)
1717    - FT245 USB
1818    - CompactFlash slot
1919    - ShortBus (ETH64, DUART, DigiMAX, ETFE)
src/mess/machine/hd64610.c
r15107r15108
238238
239239
240240//-------------------------------------------------
241//  rtc_clock_updated -
241//  rtc_clock_updated -
242242//-------------------------------------------------
243243
244244void hd64610_device::rtc_clock_updated(int year, int month, int day, int day_of_week, int hour, int minute, int second)
src/mess/machine/a2themill.c
r15107r15108
33    a2themill.c
44
55    Implementation of the Stellation Two The Mill 6809 card
6
6
77    The OS9 add-on changes the address mapping as follows:
88    6809 0x0000-0xafff -> 6502 0x1000-0xbfff
99    6809 0xb000-0xdfff -> 6502 0xd000-0xffff
1010    6809 0xe000-0xefff -> 6502 0xc000-0xcfff
1111    6809 0xf000-0xffff -> 6502 0x0000-0x0fff
12
12
1313    (reference: http://mirrors.apple2.org.za/ground.icaen.uiowa.edu/MiscInfo/Hardware/mill.6809 )
14
14
1515    ProDOS "Stellation The Mill Disk.po" requires Mill in slot 2; boot
1616    the disc and type "-DEMO1" and press Enter to launch the simple demo.
17
17
1818    The OS9 disk image available around the internet seems to be bad - the
1919    6809 boot vector is 0x4144 which maps to 6502 0x5144 and there's all
2020    zeros from 6502 1000-8fff.  There is valid 6809 code from 9000-BFFF
2121    at the point where it wants to boot the 6809, but I don't know what
2222    is supposed to be the entry point.
23     
23
2424*********************************************************************/
2525
2626#include "a2themill.h"
r15107r15108
166166                m_status &= ~0x02;
167167            }
168168            break;
169       
169
170170        case 3: // 6809 NMI
171171            if (data & 0x80)
172172            {
src/mess/machine/osborne1.c
r15107r15108
193193READ8_MEMBER( osborne1_state::ieee_pia_pb_r )
194194{
195195   /*
196   
197       bit     description
198   
199       0       
200       1       
201       2       
202       3       EOI
203       4       
204       5       DAV
205       6       NDAC
206       7       NRFD
207   
208   */
209196
197        bit     description
198
199        0
200        1
201        2
202        3       EOI
203        4
204        5       DAV
205        6       NDAC
206        7       NRFD
207
208    */
209
210210   UINT8 data = 0;
211211
212212   data |= m_ieee->eoi_r() << 3;
r15107r15108
221221WRITE8_MEMBER( osborne1_state::ieee_pia_pb_w )
222222{
223223   /*
224   
225       bit     description
226   
227       0       
228       1       
229       2       
230       3       EOI
231       4       ATN
232       5       DAV
233       6       NDAC
234       7       NRFD
235   
236   */
237224
225        bit     description
226
227        0
228        1
229        2
230        3       EOI
231        4       ATN
232        5       DAV
233        6       NDAC
234        7       NRFD
235
236    */
237
238238   m_ieee->eoi_w(BIT(data, 3));
239239   m_ieee->atn_w(BIT(data, 4));
240240   m_ieee->dav_w(BIT(data, 5));
r15107r15108
245245
246246const pia6821_interface osborne1_ieee_pia_config =
247247{
248   DEVCB_DEVICE_MEMBER(IEEE488_TAG, ieee488_device, dio_r),    /* in_a_func */
248   DEVCB_DEVICE_MEMBER(IEEE488_TAG, ieee488_device, dio_r),   /* in_a_func */
249249   DEVCB_DRIVER_MEMBER(osborne1_state, ieee_pia_pb_r),            /* in_b_func */
250250   DEVCB_NULL,                     /* in_ca1_func */
251251   DEVCB_NULL,                     /* in_cb1_func */
src/mess/machine/apple2.c
r15107r15108
788788   {
789789      meminfo->read_mem      = (state->m_flags & VAR_PAGE2)   ? 0x012000 : 0x002000;
790790      meminfo->write_mem      = (state->m_flags & VAR_PAGE2)   ? 0x012000 : 0x002000;
791      meminfo->write_handler   = (state->m_flags & VAR_PAGE2)   ? &write_delegates[0] : &write_delegates[1];
791      meminfo->write_handler   = (state->m_flags & VAR_PAGE2)   ? &write_delegates[0] : &write_delegates[1];
792792   }
793793   else
794794   {
795795      meminfo->read_mem      = (state->m_flags & VAR_RAMRD)   ? 0x012000 : 0x002000;
796796      meminfo->write_mem      = (state->m_flags & VAR_RAMWRT)   ? 0x012000 : 0x002000;
797      meminfo->write_handler   = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];
797      meminfo->write_handler   = (state->m_flags & VAR_RAMWRT)   ? &write_delegates[0] : &write_delegates[1];
798798   }
799799}
800800
src/mess/drivers/rainbow.c
r15107r15108
33        DEC Rainbow 100
44
55        Driver-in-progress by R. Belmont and Miodrag Milanovic
6
6
77****************************************************************************/
88
99#include "emu.h"
src/mess/drivers/tvc.c
r15107r15108
245245      PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("M") PORT_CODE(KEYCODE_M)
246246   PORT_START("LINE8")
247247      PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Insert")  PORT_CODE(KEYCODE_INSERT)
248      PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Up")      PORT_CODE(KEYCODE_UP)
249      PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Down")      PORT_CODE(KEYCODE_DOWN)
250      PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Fire")      PORT_CODE(KEYCODE_F1)
251      PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Acc")      PORT_CODE(KEYCODE_F2)
248      PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Up")     PORT_CODE(KEYCODE_UP)
249      PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Down")    PORT_CODE(KEYCODE_DOWN)
250      PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Fire")    PORT_CODE(KEYCODE_F1)
251      PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Acc")    PORT_CODE(KEYCODE_F2)
252252      PORT_BIT(0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Right")   PORT_CODE(KEYCODE_RIGHT)
253      PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Left")      PORT_CODE(KEYCODE_LEFT)
253      PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Left")    PORT_CODE(KEYCODE_LEFT)
254254      PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_UNUSED)
255255   PORT_START("LINE9")
256256      PORT_BIT(0xFF, IP_ACTIVE_LOW, IPT_UNUSED)
src/mess/drivers/pc8001.c
r15107r15108
100100READ8_MEMBER( pc8001_state::port40_r )
101101{
102102   /*
103   
104       bit     description
105   
106       0       BUSY
107       1       ACK
108       2       CMT CDIN
109       3       EXP /EXTON
110       4       RTC DATA OUT
111       5       VRTC
112       6       
113       7       
114   
115   */
116103
104        bit     description
105
106        0       BUSY
107        1       ACK
108        2       CMT CDIN
109        3       EXP /EXTON
110        4       RTC DATA OUT
111        5       VRTC
112        6
113        7
114
115    */
116
117117   UINT8 data = 0x08;
118118
119119   data |= m_centronics->busy_r();
r15107r15108
127127WRITE8_MEMBER( pc8001_state::port40_w )
128128{
129129   /*
130   
131       bit     description
132   
133       0       STROBE
134       1       RTC STB
135       2       RTC CLK
136       3       CRT /CLDS CLK
137       4       
138       5       SPEAKER
139       6       
140       7       
141   
142   */
143130
131        bit     description
132
133        0       STROBE
134        1       RTC STB
135        2       RTC CLK
136        3       CRT /CLDS CLK
137        4
138        5       SPEAKER
139        6
140        7
141
142    */
143
144144   m_centronics->strobe_w(BIT(data, 0));
145145
146146   m_rtc->clk_w(BIT(data, 2));

Previous 15994 Revisions Next


© 1998-2018 The MESS Team