Previous 199869 Revisions Next

r33861 Saturday 13th December, 2014 at 16:39:01 UTC by Miodrag Milanović
Merge pull request #77 from shattered/_6d9f6c6

vt240.c: mc7105 WIP (nw)
[hash]vz_cass.xml*
[src/emu/cpu/arcompact]arcompactdasm_ops.c
[src/emu/cpu/e132xs]e132xs.c e132xs.h
[src/emu/cpu/h8]h8_intc.c h8_timer16.c
[src/emu/imagedev]floppy.c
[src/mame/drivers]5clown.c f-32.c mjkjidai.c viper.c wallc.c
[src/mess/drivers]ngen.c vtech1.c

trunk/hash/vz_cass.xml
r0r242373
1<?xml version="1.0"?>
2<!DOCTYPE softwarelist SYSTEM "softwarelist.dtd">
3
4<!--
5
6List of known tape releases by Dick Smith in Australia:
7
8X-7274   Attack of the Killer Tomatoes
9X-7231   Match Box
10X-7232   Poker
11X-7233   Hangman
12X-7234   Slot Machine/Knock Off/Russian Roulette
13X-7235   Blackjack
14X-7236   Circus (*)
15X-7237   Biorhythm/Pair Matching/Calendar
16X-7238   Horse Race
17X-7239   Invaders (*)
18X-7240   Dynasty Derby
19X-7241   Learjet
20X-7242   Ghost Hunter (*)
21X-7243   Hoppy (*)
22X-7244   Super Snake
23X-7245   Knights and Dragons
24X-7247   Star Blaster (*)
25X-7248   VZ-Asteroids
26X-7249   Air Traffic Controller
27X-7250   Lunar Lander
28X-7251   Statistics 1
29X-7252   Statistics 2
30X-7253   Matrix
31X-7254   Tennis Lesson/Golf Lesson
32X-7255   Introduction to BASIC
33X-7256   Elementary Geometry
34X-7257   Speed Reading
35X-7258   Typing Teacher
36X-7259   Mailing List
37X-7261   Portfolio Management
38X-7262   Discounted Cash Flow Analysis
39X-7263   Financial Ratio Analysis
40X-7264   Tennis (*)
41X-7265   Checkers
42X-7266   Planet Patrol (*)
43X-7268   Ladder Challenge (*)
44X-7270   Panik (*)
45X-7271   Othello
46X-7272   Dracula's Castle
47X-7273   Backgammon
48X-7275   VZ Chess (*)
49X-7276   Music Writer
50X-7278   Disassembler
51X-7279   Duel
52X-7280   Hex Utilities
53X-7281   Word Processor
54X-7282   Editor Assembler
55X-7285   Spell'O'Matic 1 & 2
56X-7286   Spell'O'Matic 3 & 4
57X-7287   Flashword 1 & 2
58X-7288   Flashword 3 & 4
59X-7289   Metric Spycatcher
60X-7290   Whizkid Spycatcher
61X-7330   Sprite Generator
62X-7331   Formula One
63X-7332   Galaxon (*)
64X-7333   Dawn Patrol (*)
65X-7339   Space RAM
66X-7342   Crash
67X-7344   Maze of Argon
68X-7345   Word Matching
69
70* = dumped
71
72Demonstration Tape (included with the VZ200)
73Demonstration Tape (included with the VZ300)
74
75-->
76
77<softwarelist name="vz_cass" description="Dick Smith VZ-200/300 cassettes">
78
79   <software name="chess">
80      <description>Chess</description>
81      <year>198?</year>
82      <publisher>Dick Smith</publisher>
83      <info name="serial" value="X-7275" />
84      <part name="cass1" interface="vtech1_cass">
85         <dataarea name="cass" size="2854400">
86            <rom name="chess.wav" size="2854400" crc="7cc80cf3" sha1="770b09e8755fad97e12f320cd5fea3416669cd36" offset="0" />
87         </dataarea>
88      </part>
89   </software>
90
91   <software name="circus">
92      <description>Circus</description>
93      <year>198?</year>
94      <publisher>Dick Smith</publisher>
95      <info name="serial" value="X-7236" />
96      <part name="cass1" interface="vtech1_cass">
97         <dataarea name="cass" size="1317376">
98            <rom name="circus.wav" size="1317376" crc="ab3ba833" sha1="1b33e2f3f2389f61f2e815be626b5d84083be77e" offset="0" />
99         </dataarea>
100      </part>
101   </software>
102
103   <software name="dawn">
104      <description>Dawn Patrol</description>
105      <year>198?</year>
106      <publisher>Dick Smith</publisher>
107      <info name="serial" value="X-7333" />
108      <part name="cass1" interface="vtech1_cass">
109         <dataarea name="cass" size="3640544">
110            <rom name="dawn.wav" size="3640544" crc="22d096f5" sha1="ac480a16b6d6b8d6f08875e9c6ca13cadc413fa1" offset="0" />
111         </dataarea>
112      </part>
113   </software>
114
115   <!-- Not released by Dick Smith? -->
116   <software name="defpen">
117      <description>Defense Penetrator</description>
118      <year>1982</year>
119      <publisher>Cosmic Software</publisher>
120      <info name="author" value="Tom Thiel" />
121      <part name="cass1" interface="vtech1_cass">
122         <dataarea name="cass" size="1926592">
123            <rom name="defpen.wav" size="1926592" crc="b3dfa117" sha1="b7b53d11483fd78dfc81484e0830e6f6913c6e47" offset="0" />
124         </dataarea>
125      </part>
126   </software>
127
128   <software name="galaxon">
129      <description>Galaxon</description>
130      <year>198?</year>
131      <publisher>Dick Smith</publisher>
132      <info name="serial" value="X-7332" />
133      <part name="cass1" interface="vtech1_cass">
134         <dataarea name="cass" size="1628976">
135            <rom name="galaxon.wav" size="1628976" crc="8909df05" sha1="4ee1ce9aa8538b8aad9d0839fdb1396335074945" offset="0" />
136         </dataarea>
137      </part>
138   </software>
139
140   <software name="ghost">
141      <description>Ghost Hunter</description>
142      <year>198?</year>
143      <publisher>Dick Smith</publisher>
144      <info name="author" value="Dubois and McNamara" />
145      <info name="serial" value="X-7242" />
146      <part name="cass1" interface="vtech1_cass">
147         <dataarea name="cass" size="1732336">
148            <rom name="ghost.wav" size="1732336" crc="b5ed2320" sha1="f58e328e0b20d453a1c0486fd8e10c5f3e7ecfa7" offset="0" />
149         </dataarea>
150      </part>
151   </software>
152
153   <software name="hamsam">
154      <description>Hamburger Sam</description>
155      <year>????</year>
156      <publisher></publisher>
157      <part name="cass1" interface="vtech1_cass">
158         <dataarea name="cass" size="5109472">
159            <rom name="hamsam.wav" size="5109472" crc="7aed86a7" sha1="b5061edb1401cea4aee97d8cd92c582c9c14e66b" offset="0" />
160         </dataarea>
161      </part>
162   </software>
163
164   <software name="hoppy">
165      <description>Hoppy</description>
166      <year>198?</year>
167      <publisher>Dick Smith</publisher>
168      <info name="serial" value="X-7243" />
169      <part name="cass1" interface="vtech1_cass">
170         <dataarea name="cass" size="3172080">
171            <rom name="hoppy.wav" size="3172080" crc="60e7e15a" sha1="1d56a04af700a94d44d6bb0ddfaf89213db39ce8" offset="0" />
172         </dataarea>
173      </part>
174   </software>
175
176   <software name="invaders">
177      <description>Invaders</description>
178      <year>198?</year>
179      <publisher>Dick Smith</publisher>
180      <info name="author" value="Dubois and McNamara" />
181      <info name="serial" value="X-7239" />
182      <part name="cass1" interface="vtech1_cass">
183         <dataarea name="cass" size="1723824">
184            <rom name="invaders.wav" size="1723824" crc="f959681e" sha1="e12bc9384e7fe1efc0ecff6356c3e3ded7ee8373" offset="0" />
185         </dataarea>
186      </part>
187   </software>
188
189   <software name="ladder">
190      <description>Ladder Challenge</description>
191      <year>198?</year>
192      <publisher>Dick Smith</publisher>
193      <info name="serial" value="X-7268" />
194      <part name="cass1" interface="vtech1_cass">
195         <dataarea name="cass" size="1622288">
196            <rom name="ladder.wav" size="1622288" crc="47ab9ccf" sha1="e6d72b7bc26b124c906b9c0e0015137ae8844a4d" offset="0" />
197         </dataarea>
198      </part>
199   </software>
200
201   <software name="missile">
202      <description>Missile</description>
203      <year>????</year>
204      <publisher></publisher>
205      <part name="cass1" interface="vtech1_cass">
206         <dataarea name="cass" size="5109776">
207            <rom name="missile.wav" size="5109776" crc="55a1fda4" sha1="1de495534447cee16d3db22b043d53b6d15f05fe" offset="0" />
208         </dataarea>
209      </part>
210   </software>
211
212   <software name="panik">
213      <description>Panik</description>
214      <year>198?</year>
215      <publisher>Dick Smith</publisher>
216      <info name="serial" value="X-7270" />
217      <part name="cass1" interface="vtech1_cass">
218         <dataarea name="cass" size="1708928">
219            <rom name="panik.wav" size="1708928" crc="8b8c4c5a" sha1="e9e2ae5c406f9ac79b186cb34b2849b9e2a477e3" offset="0" />
220         </dataarea>
221      </part>
222   </software>
223
224   <software name="ppatrol">
225      <description>Planet Patrol</description>
226      <year>198?</year>
227      <publisher>Dick Smith</publisher>
228      <info name="serial" value="X-7266" />
229      <part name="cass1" interface="vtech1_cass">
230         <dataarea name="cass" size="2107776">
231            <rom name="ppatrol.wav" size="2107776" crc="3eb828ed" sha1="b56777b732587856f554d978d844a3815ec50f69" offset="0" />
232         </dataarea>
233      </part>
234   </software>
235
236   <software name="starblas">
237      <description>Star Blaster</description>
238      <year>198?</year>
239      <publisher>Dick Smith</publisher>
240      <info name="serial" value="X-7247" />
241      <info name="usage" value="Needs 16k memory expansion" />
242      <part name="cass1" interface="vtech1_cass">
243         <dataarea name="cass" size="3327120">
244            <rom name="starblas.wav" size="3327120" crc="e6a5b55f" sha1="07715fd8104891d0d4d3b06b5609674ca93af920" offset="0" />
245         </dataarea>
246      </part>
247   </software>
248
249   <software name="tennis">
250      <description>Tennis</description>
251      <year>198?</year>
252      <publisher>Dick Smith</publisher>
253      <info name="serial" value="X-7264" />
254      <part name="cass1" interface="vtech1_cass">
255         <dataarea name="cass" size="2100784">
256            <rom name="tennis.wav" size="2100784" crc="3eb5ed00" sha1="6c2f2d4c9d60b6f2bd977eddd397d6dbdbfc52f1" offset="0" />
257         </dataarea>
258      </part>
259   </software>
260
261</softwarelist>
trunk/src/emu/cpu/arcompact/arcompactdasm_ops.c
r242372r242373
344344   // fedc ba98 7654 3210 fedc ba98 7654 3210
345345   // fields
346346   // 0001 0bbb ssss ssss SBBB DaaZ ZXAA AAAA
347   int size = 4;
347348
348
349349   int A = (op & 0x0000003f) >> 0;  //op &= ~0x0000003f;
350350   int X = (op & 0x00000040) >> 6;  //op &= ~0x00000040;
351351   int Z = (op & 0x00000180) >> 7;  //op &= ~0x00000180;
r242372r242373
359359   int breg = b | (B << 3);
360360   int sdat = s | (S << 8); // todo - signed
361361
362   UINT32 limm = 0;
363   if (breg == LIMM_REG)
364   {
365      GET_LIMM_32;
366      size = 8;
367   }
368
362369   output  += sprintf( output, "LD");
363370   output  += sprintf( output, "%s", datasize[Z]);
364371   output  += sprintf( output, "%s", dataextend[X]);
r242372r242373
367374   output  += sprintf( output, " ");
368375   output  += sprintf( output, "%s, ", regnames[A]);
369376   output  += sprintf( output, "[");
370   output  += sprintf( output, "%s, ", regnames[breg]);
377   if (breg == LIMM_REG) output  += sprintf( output, "(%08x), ", limm);
378   else output  += sprintf( output, "%s, ", regnames[breg]);
371379   output  += sprintf( output, "%d", sdat);
372380   output  += sprintf( output, "]");
373381
374   return 4;
382   return size;
375383}
376384
377385int arcompact_handle03_dasm(DASM_OPS_32)
378386{
387   int size = 4;
379388   // bitpos
380   // 11111 111 11111111 0 000 000000 0 00 00 0
381   // fedcb a98 76543210 f edc ba9876 5 43 21 0
389   // 1111 1111 1111 1111 0000 0000 0000 0000
390   // fedc ba98 7654 3210 fedc ba98 7654 3210
382391   // fields
383   // 00011 bbb ssssssss S BBB CCCCCC D aa ZZ R
392   // 0001 1bbb ssss ssss SBBB CCCC CCDa aZZR
393   int B = (op & 0x00007000) >> 12;// op &= ~0x00007000;
394   int S = (op & 0x00008000) >> 15;// op &= ~0x00008000;
395   int s = (op & 0x00ff0000) >> 16;// op &= ~0x00ff0000;
396   int b = (op & 0x07000000) >> 24;// op &= ~0x07000000;
384397
385   print("ST r+o (%08x)", op );
386   return 4;
398   int breg = b | (B << 3);
399   int sdat = s | (S << 8); // todo - signed
400
401   int R = (op & 0x00000001) >> 0; op &= ~0x00000001;
402   int Z = (op & 0x00000006) >> 1; op &= ~0x00000006;
403   int a = (op & 0x00000018) >> 3; op &= ~0x00000018;
404   int D = (op & 0x00000020) >> 5; op &= ~0x00000020;
405   int C = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0;
406   
407   UINT32 limm = 0;
408   if (breg == LIMM_REG)
409   {
410      GET_LIMM_32;
411      size = 8;
412   }
413
414
415   output  += sprintf( output, "ST");
416   output  += sprintf( output, "%s", datasize[Z]);
417   output  += sprintf( output, "%s", addressmode[a]);
418   output  += sprintf( output, "%s", cachebit[D]);
419   output  += sprintf( output, " ");
420
421   output  += sprintf( output, "%s, ", regnames[C]);
422   if (breg == LIMM_REG) output  += sprintf( output, "(%08x), ", limm);
423   else output  += sprintf( output, "%s, ", regnames[breg]);
424   output  += sprintf( output, "%d", sdat);
425
426   if (R) output  += sprintf( output, "(reserved bit set)");
427
428
429   return size;
387430}
388431
389432
390int arcompact_handle04_helper_dasm(char *output, offs_t pc, UINT32 op, const UINT8* oprom, const char* optext, int ignore_dst)
433int arcompact_handle04_helper_dasm(char *output, offs_t pc, UINT32 op, const UINT8* oprom, const char* optext, int ignore_dst, int b_reserved)
391434{
392435   //           PP
393436   // 0010 0bbb 00ii iiii FBBB CCCC CCAA AAAA
r242372r242373
401444
402445   output  += sprintf( output, "%s", optext);
403446   output  += sprintf( output, "%s", flagbit[F]);
404   output  += sprintf( output, " p(%d)", p);
405   output  += sprintf( output, " %s, ", regnames[breg]);
447//   output  += sprintf( output, " p(%d)", p);
448   
449   
450   if (!b_reserved)
451   {
452      output += sprintf(output, " %s, ", regnames[breg]);
453   }
454   else
455   {
456      if (breg) output += sprintf(output, "reserved(%s), ", regnames[breg]);
457   }
406458
459
407460   if (p == 0)
408461   {
409462      // 0010 0bbb 00ii iiii FBBB CCCC CCAA AAAA
r242372r242373
417470         GET_LIMM_32;
418471         size = 8;   
419472         output  += sprintf( output, "(%08x) ", limm );
420         if (!ignore_dst) output  += sprintf( output, "A(%s)", regnames[A]);
421         else  output  += sprintf( output, "unused(%s)", regnames[A]);     
473         if (!ignore_dst) output  += sprintf( output, "DST(%s)", regnames[A]);
474         else
475         {
476            if (A) output += sprintf(output, "unused(%s)", regnames[A]);
477         }
422478      }
423479      else
424480      {
425481         output  += sprintf( output, "C(%s) ", regnames[C]);
426         if (!ignore_dst) output  += sprintf( output, "A(%s)", regnames[A]);
427         else  output  += sprintf( output, "unused(%s)", regnames[A]);     
482         if (!ignore_dst) output  += sprintf( output, "DST(%s)", regnames[A]);
483         else
484         {
485            if (A) output += sprintf(output, "unused(%s)", regnames[A]);
486         }
428487
429488      }
430489   }
r242372r242373
435494      int A = (op & 0x0000003f) >> 0; op &= ~0x0000003f;
436495
437496      output  += sprintf( output, "U(%02x) ", U );
438      if (!ignore_dst) output  += sprintf( output, "A(%s)", regnames[A]);         
439      else  output  += sprintf( output, "unused(%s)", regnames[A]);     
497      if (!ignore_dst) output  += sprintf( output, "DST(%s)", regnames[A]);         
498      else
499      {
500         if (A) output += sprintf(output, "unused(%s)", regnames[A]);
501      }
440502   }
441503   else if (p == 2)
442504   {
r242372r242373
472534
473535int arcompact_handle04_00_dasm(DASM_OPS_32) 
474536{
475   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD", 0);
537   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD", 0,0);
476538}
477539
478540int arcompact_handle04_01_dasm(DASM_OPS_32) 
479541{
480   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADC", 0);
542   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADC", 0,0);
481543}
482544
483545int arcompact_handle04_02_dasm(DASM_OPS_32) 
484546{
485   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB", 0);
547   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB", 0,0);
486548}
487549
488550int arcompact_handle04_03_dasm(DASM_OPS_32) 
489551{
490   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SBC", 0);
552   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SBC", 0,0);
491553}
492554
493555int arcompact_handle04_04_dasm(DASM_OPS_32) 
494556{
495   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "AND", 0);
557   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "AND", 0,0);
496558}
497559
498560int arcompact_handle04_05_dasm(DASM_OPS_32) 
499561{
500   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "OR", 0);
562   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "OR", 0,0);
501563}
502564
503565int arcompact_handle04_06_dasm(DASM_OPS_32) 
504566{
505   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BIC", 0);
567   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BIC", 0,0);
506568}
507569
508570int arcompact_handle04_07_dasm(DASM_OPS_32) 
509571{
510   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "XOR", 0);
572   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "XOR", 0,0);
511573}
512574
513575int arcompact_handle04_08_dasm(DASM_OPS_32) 
514576{
515   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MAX", 0);
577   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MAX", 0,0);
516578}
517579
518580int arcompact_handle04_09_dasm(DASM_OPS_32)
519581{
520   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MIN", 0);
582   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MIN", 0,0);
521583}
522584
523585
524586int arcompact_handle04_0a_dasm(DASM_OPS_32)
525587{
526   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MOV", 1);
588   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MOV", 1,0);
527589}
528590
529591int arcompact_handle04_0b_dasm(DASM_OPS_32)
530592{
531   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "TST", 1);
593   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "TST", 1,0);
532594}
533595
534596int arcompact_handle04_0c_dasm(DASM_OPS_32)
535597{
536   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "CMP", 1);
598   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "CMP", 1,0);
537599}
538600
539601int arcompact_handle04_0d_dasm(DASM_OPS_32)
540602{
541   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RCMP", 1);
603   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RCMP", 1,0);
542604}
543605
544606int arcompact_handle04_0e_dasm(DASM_OPS_32)
545607{
546   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RSUB", 0);
608   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RSUB", 0,0);
547609}
548610
549611int arcompact_handle04_0f_dasm(DASM_OPS_32) 
550612{
551   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BSET", 0);
613   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BSET", 0,0);
552614}
553615
554616int arcompact_handle04_10_dasm(DASM_OPS_32) 
555617{
556   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BCLR", 0);
618   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BCLR", 0,0);
557619}
558620
559621int arcompact_handle04_11_dasm(DASM_OPS_32) 
560622{
561   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BTST", 0);
623   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BTST", 0,0);
562624}
563625
564626int arcompact_handle04_12_dasm(DASM_OPS_32) 
565627{
566   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BXOR", 0);
628   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BXOR", 0,0);
567629}
568630
569631int arcompact_handle04_13_dasm(DASM_OPS_32) 
570632{
571   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BMSK", 0);
633   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BMSK", 0,0);
572634}
573635
574636int arcompact_handle04_14_dasm(DASM_OPS_32) 
575637{
576   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD1", 0);
638   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD1", 0,0);
577639}
578640
579641int arcompact_handle04_15_dasm(DASM_OPS_32) 
580642{
581   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD2", 0);
643   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD2", 0,0);
582644}
583645
584646int arcompact_handle04_16_dasm(DASM_OPS_32) 
585647{
586   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD3", 0);
648   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD3", 0,0);
587649}
588650
589651int arcompact_handle04_17_dasm(DASM_OPS_32) 
590652{
591   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB1", 0);
653   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB1", 0,0);
592654}
593655
594656int arcompact_handle04_18_dasm(DASM_OPS_32) 
595657{
596   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB2", 0);
658   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB2", 0,0);
597659}
598660
599661int arcompact_handle04_19_dasm(DASM_OPS_32) 
600662{
601   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB3", 0);
663   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB3", 0,0);
602664}
603665
604666int arcompact_handle04_1a_dasm(DASM_OPS_32) 
605667{
606   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPY", 0);
668   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPY", 0,0);
607669} // *
608670
609671int arcompact_handle04_1b_dasm(DASM_OPS_32) 
610672{
611   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYH", 0);
673   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYH", 0,0);
612674} // *
613675
614676int arcompact_handle04_1c_dasm(DASM_OPS_32) 
615677{
616   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYHU", 0);
678   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYHU", 0,0);
617679} // *
618680
619681int arcompact_handle04_1d_dasm(DASM_OPS_32) 
620682{
621   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYU", 0);
683   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYU", 0,0);
622684} // *
623685
624686
625687
626688int arcompact_handle04_20_dasm(DASM_OPS_32)
627689{
628   // todo, other bits (in none long immediate mode at least)
690   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "J", 1,1);
691}
629692
630   int size = 4;
631   int C = (op & 0x00000fc0) >> 6;
632   UINT8 condition = op & 0x0000001f;
633693
634   op &= ~0x00000fc0;
635   
636   if (C == LIMM_REG)
637   {
638      UINT32 limm;
639      GET_LIMM_32;
640      size = 8;
641     
642      print("J(%s) %08x (%08x)", conditions[condition], limm, op);
643   }
644   else
645   {
646      print("J(%s) (r%d) (%08x)", conditions[condition], C, op);
647   }
648694
649   return size;
695int arcompact_handle04_21_dasm(DASM_OPS_32)
696{
697   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "J.D", 1,1);
650698}
651699
700int arcompact_handle04_22_dasm(DASM_OPS_32)
701{
702   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "JL", 1,1);
703}
652704
705int arcompact_handle04_23_dasm(DASM_OPS_32)
706{
707   return arcompact_handle04_helper_dasm(output, pc, op, oprom, "JL.D", 1,1);
708}
653709
654int arcompact_handle04_21_dasm(DASM_OPS_32)  { print("Jcc.D (%08x)", op); return 4;}
655int arcompact_handle04_22_dasm(DASM_OPS_32)  { print("JLcc (%08x)", op); return 4;}
656int arcompact_handle04_23_dasm(DASM_OPS_32)  { print("JLcc.D (%08x)", op); return 4;}
657710
658711
659712
660
661713int arcompact_handle04_28_dasm(DASM_OPS_32)  { print("LPcc (%08x)", op); return 4;}
662714int arcompact_handle04_29_dasm(DASM_OPS_32)  { print("FLAG (%08x)", op); return 4;}
663715int arcompact_handle04_2a_dasm(DASM_OPS_32)  { print("LR (%08x)", op); return 4;}
r242372r242373
690742
691743
692744
745// format on these is..
693746
747// 0010 0bbb aa11 0ZZX DBBB CCCC CCAA AAAA
748// note, bits  11 0ZZX are part of the sub-opcode # already - this is a special encoding
749int arcompact_handle04_3x_helper_dasm(char *output, offs_t pc, UINT32 op, const UINT8* oprom, int dsize, int extend)
750{
751   int size = 4;
752   output += sprintf(output, "LD");
753   output += sprintf(output, "%s", datasize[dsize]);
754   output += sprintf(output, "%s", dataextend[extend]);
694755
695int arcompact_handle04_30_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x30) (%08x)", op); return 4;}
696int arcompact_handle04_31_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x31) (%08x)", op); return 4;}
697int arcompact_handle04_32_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x32) (%08x)", op); return 4;}
698int arcompact_handle04_33_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x33) (%08x)", op); return 4;}
699int arcompact_handle04_34_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x34) (%08x)", op); return 4;}
700int arcompact_handle04_35_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x35) (%08x)", op); return 4;}
701int arcompact_handle04_36_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x36) (%08x)", op); return 4;}
702int arcompact_handle04_37_dasm(DASM_OPS_32)  { print("LD r-r (basecase 0x37) (%08x)", op); return 4;}
756   int mode = (op & 0x00c00000) >> 22; op &= ~0x00c00000;
757   int b = (op & 0x07000000) >> 24; op &= ~0x07000000;
758   int B = (op & 0x00007000) >> 12; op &= ~0x00007000;
759   int breg = b | (B << 3);
760   int D = (op & 0x00008000) >> 15;op &= ~0x00008000;
761   int C = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0;
762   int A = (op & 0x0000003f) >> 0; op &= ~0x0000003f;
703763
764   output += sprintf(output, "%s", addressmode[mode]);
765   output += sprintf(output, "%s", cachebit[D]);
704766
767   output  += sprintf( output, "DST(%s)", regnames[A]);
768   output  += sprintf( output, "SRC1(%s)", regnames[breg]);
769   output  += sprintf( output, "SRC2(%s)", regnames[C]);
705770
771   
706772
707773
774   return size;
775   
708776
777
778}
779
780int arcompact_handle04_30_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,0,0); }
781// ZZ value of 0x0 with X of 1 is illegal
782int arcompact_handle04_31_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,0,1); }
783int arcompact_handle04_32_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,1,0); }
784int arcompact_handle04_33_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,1,1); }
785int arcompact_handle04_34_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,2,0); }
786int arcompact_handle04_35_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,2,1); }
787// ZZ value of 0x3 is illegal
788int arcompact_handle04_36_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,3,0); }
789int arcompact_handle04_37_dasm(DASM_OPS_32)  { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,3,1); }
790
791
792
793
794
795
709796int arcompact_handle05_00_dasm(DASM_OPS_32)  { print("ASL a <- b asl c (%08x)", op); return 4;}
710797int arcompact_handle05_01_dasm(DASM_OPS_32)  { print("LSR a <- b lsr c (%08x)", op); return 4;}
711798int arcompact_handle05_02_dasm(DASM_OPS_32)  { print("ASR a <- b asr c (%08x)", op); return 4;}
trunk/src/emu/cpu/e132xs/e132xs.c
r242372r242373
583583UINT32 hyperstone_device::compute_tr()
584584{
585585   UINT64 cycles_since_base = total_cycles() - m_tr_base_cycles;
586   UINT64 clocks_since_base = cycles_since_base >> m_clock_scale;
586   UINT64 clocks_since_base = cycles_since_base >> m_clck_scale;
587587   return m_tr_base_value + (clocks_since_base / m_tr_clocks_per_tick);
588588}
589589
r242372r242373
591591{
592592   UINT32 prevtr = compute_tr();
593593   TPR &= ~0x80000000;
594   m_clock_scale = (TPR >> 26) & m_clock_scale_mask;
595   m_clock_cycles_1 = 1 << m_clock_scale;
596   m_clock_cycles_2 = 2 << m_clock_scale;
597   m_clock_cycles_4 = 4 << m_clock_scale;
598   m_clock_cycles_6 = 6 << m_clock_scale;
594   m_clck_scale = (TPR >> 26) & m_clock_scale_mask;
595   m_clock_cycles_1 = 1 << m_clck_scale;
596   m_clock_cycles_2 = 2 << m_clck_scale;
597   m_clock_cycles_4 = 4 << m_clck_scale;
598   m_clock_cycles_6 = 6 << m_clck_scale;
599599   m_tr_clocks_per_tick = ((TPR >> 16) & 0xff) + 2;
600600   m_tr_base_value = prevtr;
601601   m_tr_base_cycles = total_cycles();
r242372r242373
604604void hyperstone_device::adjust_timer_interrupt()
605605{
606606   UINT64 cycles_since_base = total_cycles() - m_tr_base_cycles;
607   UINT64 clocks_since_base = cycles_since_base >> m_clock_scale;
608   UINT64 cycles_until_next_clock = cycles_since_base - (clocks_since_base << m_clock_scale);
607   UINT64 clocks_since_base = cycles_since_base >> m_clck_scale;
608   UINT64 cycles_until_next_clock = cycles_since_base - (clocks_since_base << m_clck_scale);
609609
610610   if (cycles_until_next_clock == 0)
611      cycles_until_next_clock = (UINT64)(1 << m_clock_scale);
611      cycles_until_next_clock = (UINT64)(1 << m_clck_scale);
612612
613613   /* special case: if we have a change pending, set a timer to fire then */
614614   if (TPR & 0x80000000)
615615   {
616616      UINT64 clocks_until_int = m_tr_clocks_per_tick - (clocks_since_base % m_tr_clocks_per_tick);
617      UINT64 cycles_until_int = (clocks_until_int << m_clock_scale) + cycles_until_next_clock;
617      UINT64 cycles_until_int = (clocks_until_int << m_clck_scale) + cycles_until_next_clock;
618618      m_timer->adjust(cycles_to_attotime(cycles_until_int + 1), 1);
619619   }
620620
r242372r242373
631631      else
632632      {
633633         UINT64 clocks_until_int = mulu_32x32(delta, m_tr_clocks_per_tick);
634         UINT64 cycles_until_int = (clocks_until_int << m_clock_scale) + cycles_until_next_clock;
634         UINT64 cycles_until_int = (clocks_until_int << m_clck_scale) + cycles_until_next_clock;
635635         m_timer->adjust(cycles_to_attotime(cycles_until_int));
636636      }
637637   }
r242372r242373
15361536   m_op = 0;
15371537   m_trap_entry = 0;
15381538   m_clock_scale_mask = 0;
1539   m_clock_scale = 0;
1539   m_clck_scale = 0;
15401540   m_clock_cycles_1 = 0;
15411541   m_clock_cycles_2 = 0;
15421542   m_clock_cycles_4 = 0;
r242372r242373
16851685   save_item(NAME(m_intblock));
16861686   save_item(NAME(m_delay.delay_cmd));
16871687   save_item(NAME(m_tr_clocks_per_tick));
1688   save_item(NAME(m_tr_base_value));
1689   save_item(NAME(m_tr_base_cycles));
1690   save_item(NAME(m_timer_int_pending));
1691   save_item(NAME(m_clck_scale));
1692   save_item(NAME(m_clock_scale_mask));
1693   save_item(NAME(m_clock_cycles_1));
1694   save_item(NAME(m_clock_cycles_2));
1695   save_item(NAME(m_clock_cycles_4));
1696   save_item(NAME(m_clock_cycles_6));
16881697
16891698   // set our instruction counter
16901699   m_icountptr = &m_icount;
r242372r242373
20522061      }
20532062   }
20542063
2055   m_icount -= 36 << m_clock_scale;
2064   m_icount -= 36 << m_clck_scale;
20562065}
20572066
20582067void hyperstone_device::hyperstone_divs(struct hyperstone_device::regs_decode *decode)
r242372r242373
21012110      }
21022111   }
21032112
2104   m_icount -= 36 << m_clock_scale;
2113   m_icount -= 36 << m_clck_scale;
21052114}
21062115
21072116void hyperstone_device::hyperstone_xm(struct hyperstone_device::regs_decode *decode)
r242372r242373
41094118   }
41104119
41114120   if((SREG >= 0xffff8000 && SREG <= 0x7fff) && (DREG >= 0xffff8000 && DREG <= 0x7fff))
4112      m_icount -= 3 << m_clock_scale;
4121      m_icount -= 3 << m_clck_scale;
41134122   else
4114      m_icount -= 5 << m_clock_scale;
4123      m_icount -= 5 << m_clck_scale;
41154124}
41164125
41174126void hyperstone_device::hyperstone_fadd(struct hyperstone_device::regs_decode *decode)
trunk/src/emu/cpu/e132xs/e132xs.h
r242372r242373
267267   UINT32  m_trap_entry;   // entry point to get trap address
268268
269269   UINT8   m_clock_scale_mask;
270   UINT8   m_clock_scale;
270   UINT8   m_clck_scale;
271271   UINT8   m_clock_cycles_1;
272272   UINT8   m_clock_cycles_2;
273273   UINT8   m_clock_cycles_4;
trunk/src/emu/cpu/h8/h8_intc.c
r242372r242373
2222void h8_intc_device::device_start()
2323{
2424   memset(pending_irqs, 0, sizeof(pending_irqs));
25   save_item(NAME(pending_irqs));
26   save_item(NAME(irq_type));
27   save_item(NAME(nmi_input));
28   save_item(NAME(irq_input));
29   save_item(NAME(ier));
30   save_item(NAME(isr));
31   save_item(NAME(iscr));
32   save_item(NAME(icr_filter));
33   save_item(NAME(ipr_filter));
2534}
2635
2736void h8_intc_device::device_reset()
r242372r242373
195204void h8h_intc_device::device_start()
196205{
197206   h8_intc_device::device_start();
207   save_item(NAME(icr));
198208}
199209
200210void h8h_intc_device::device_reset()
trunk/src/emu/cpu/h8/h8_timer16.c
r242372r242373
162162{
163163   intc = owner()->siblingdevice<h8_intc_device>(intc_tag);
164164   channel_active = false;
165   
166   save_item(NAME(tgr_clearing));
167   save_item(NAME(tcr));
168   save_item(NAME(tier));
169   save_item(NAME(ier));
170   save_item(NAME(isr));
171   save_item(NAME(clock_type));
172   save_item(NAME(clock_divider));
173   save_item(NAME(tcnt));
174   save_item(NAME(tgr));
175   save_item(NAME(last_clock_update));
176   save_item(NAME(event_time));
177   save_item(NAME(phase));
178   save_item(NAME(counter_cycle));
179   save_item(NAME(counter_incrementing));
180   save_item(NAME(channel_active));
165181}
166182
167183void h8_timer16_channel_device::device_reset()
r242372r242373
330346      sprintf(tm, "%d", i);
331347      timer_channel[i] = subdevice<h8_timer16_channel_device>(tm);
332348   }
349   
350   save_item(NAME(tstr));
333351}
334352
335353void h8_timer16_device::device_reset()
trunk/src/emu/imagedev/floppy.c
r242372r242373
295295   ready_counter = 0;
296296
297297   setup_characteristics();
298
299   save_item(NAME(cyl));
300   save_item(NAME(subcyl));
298301}
299302
300303void floppy_image_device::device_reset()
trunk/src/mame/drivers/5clown.c
r242372r242373
456456public:
457457   _5clown_state(const machine_config &mconfig, device_type type, const char *tag)
458458      : driver_device(mconfig, type, tag),
459      m_videoram(*this, "videoram"),
460      m_colorram(*this, "colorram"),
461459      m_maincpu(*this, "maincpu"),
462460      m_audiocpu(*this, "audiocpu"),
463461      m_ay8910(*this, "ay8910"),
464462      m_gfxdecode(*this, "gfxdecode"),
465      m_palette(*this, "palette")
463      m_palette(*this, "palette"),
464      m_videoram(*this, "videoram"),
465      m_colorram(*this, "colorram")
466466   {
467467   }
468468
469   required_device<cpu_device> m_maincpu;
470   required_device<cpu_device> m_audiocpu;
471   required_device<ay8910_device> m_ay8910;
472   required_device<gfxdecode_device> m_gfxdecode;
473   required_device<palette_device> m_palette;
474   
475   required_shared_ptr<UINT8> m_videoram;
476   required_shared_ptr<UINT8> m_colorram;
477   
469478   UINT8 m_main_latch_d800;
470479   UINT8 m_snd_latch_0800;
471480   UINT8 m_snd_latch_0a02;
472481   UINT8 m_ay8910_addr;
473   required_shared_ptr<UINT8> m_videoram;
474   required_shared_ptr<UINT8> m_colorram;
475482   tilemap_t *m_bg_tilemap;
476483   int m_mux_data;
484   
477485   DECLARE_WRITE8_MEMBER(fclown_videoram_w);
478486   DECLARE_WRITE8_MEMBER(fclown_colorram_w);
479487   DECLARE_WRITE8_MEMBER(cpu_c048_w);
r242372r242373
490498   DECLARE_WRITE8_MEMBER(fclown_ay8910_w);
491499   DECLARE_DRIVER_INIT(fclown);
492500   TILE_GET_INFO_MEMBER(get_fclown_tile_info);
501   virtual void machine_start();
493502   virtual void video_start();
494503   DECLARE_PALETTE_INIT(_5clown);
495504   UINT32 screen_update_fclown(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
496   required_device<cpu_device> m_maincpu;
497   required_device<cpu_device> m_audiocpu;
498   required_device<ay8910_device> m_ay8910;
499   required_device<gfxdecode_device> m_gfxdecode;
500   required_device<palette_device> m_palette;
501505};
502506
507void _5clown_state::machine_start()
508{   
509   m_main_latch_d800 = m_snd_latch_0800 = m_snd_latch_0a02 = m_ay8910_addr = m_mux_data = 0;
510   
511   save_item(NAME(m_main_latch_d800));
512   save_item(NAME(m_snd_latch_0800));
513   save_item(NAME(m_snd_latch_0a02));
514   save_item(NAME(m_ay8910_addr));
515   save_item(NAME(m_mux_data));
516}
503517
504
505
506518/*************************
507519*     Video Hardware     *
508520*************************/
r242372r242373
12101222*************************/
12111223
12121224/*    YEAR  NAME      PARENT  MACHINE INPUT   INIT    ROT    COMPANY  FULLNAME                      FLAGS... */
1213GAME( 1993, 5clown,   0,      fclown, fclown, _5clown_state, fclown, ROT0, "IGS",   "Five Clown (English, set 1)", GAME_IMPERFECT_SOUND )
1214GAME( 1993, 5clowna,  5clown, fclown, fclown, _5clown_state, fclown, ROT0, "IGS",   "Five Clown (English, set 2)", GAME_IMPERFECT_SOUND )
1215GAME( 1993, 5clownsp, 5clown, fclown, fclown, _5clown_state, fclown, ROT0, "IGS",   "Five Clown (Spanish hack)",   GAME_IMPERFECT_SOUND )
1225GAME( 1993, 5clown,   0,      fclown, fclown, _5clown_state, fclown, ROT0, "IGS",   "Five Clown (English, set 1)", GAME_IMPERFECT_SOUND | GAME_SUPPORTS_SAVE )
1226GAME( 1993, 5clowna,  5clown, fclown, fclown, _5clown_state, fclown, ROT0, "IGS",   "Five Clown (English, set 2)", GAME_IMPERFECT_SOUND | GAME_SUPPORTS_SAVE )
1227GAME( 1993, 5clownsp, 5clown, fclown, fclown, _5clown_state, fclown, ROT0, "IGS",   "Five Clown (Spanish hack)",   GAME_IMPERFECT_SOUND | GAME_SUPPORTS_SAVE )
trunk/src/mame/drivers/f-32.c
r242372r242373
2222public:
2323   mosaicf2_state(const machine_config &mconfig, device_type type, const char *tag)
2424      : driver_device(mconfig, type, tag),
25         m_maincpu(*this, "maincpu") ,
25      m_maincpu(*this, "maincpu") ,
2626      m_videoram(*this, "videoram"){ }
2727
28   /* devices */
29   required_device<e132xn_device>  m_maincpu;
30   
2831   /* memory pointers */
29   required_device<e132xn_device>  m_maincpu;
3032   required_shared_ptr<UINT32> m_videoram;
33   
3134   DECLARE_READ32_MEMBER(f32_input_port_1_r);
3235   UINT32 screen_update_mosaicf2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
3336};
trunk/src/mame/drivers/mjkjidai.c
r242372r242373
282282void mjkjidai_state::machine_start()
283283{
284284   membank("bank1")->configure_entries(0, 4, memregion("maincpu")->base() + 0x8000, 0x4000);
285   
286   save_item(NAME(m_adpcm_pos));
287   save_item(NAME(m_adpcm_end));
288   save_item(NAME(m_keyb));
289   save_item(NAME(m_nmi_enable));
290   save_item(NAME(m_display_enable));
285291}
286292
287293void mjkjidai_state::machine_reset()
r242372r242373
361367ROM_END
362368
363369
364GAME( 1986, mjkjidai, 0, mjkjidai, mjkjidai, driver_device, 0, ROT0, "Sanritsu",  "Mahjong Kyou Jidai (Japan)", GAME_IMPERFECT_GRAPHICS )
370GAME( 1986, mjkjidai, 0, mjkjidai, mjkjidai, driver_device, 0, ROT0, "Sanritsu",  "Mahjong Kyou Jidai (Japan)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
trunk/src/mame/drivers/viper.c
r242372r242373
125125                the game will complain with error RTC BAD then reset. The data inside the RTC can not be hand created
126126                (yet) so to revive the PCB the correct RTC data must be re-programmed to a new RTC and replaced
127127                on the PCB.
128                Regarding the RTC and protection-related checks....
129                "RTC OK" checks 0x0000->0x0945 (i.e. I can clear the contents after 0x0945 and the game will still
130                happily boot). The NVRAM contents are split into chunks, each of which are checksummed.  It is a 16-bit checksum,
131                computed by summing two consecutive bytes as a 16-bit integer, where the final sum must add up to 0xFFFF (mod
132                65536).  The last two bytes in the chunk are used to make the value 0xFFFF.  There doesn't appear to be a
133                complete checksum over all the chunks (I can pick and choose chunks from various NVRAMs, as long as each chunk
134                checksum checks out). The important chunks for booting are the first two.
135                The first chunk goes from 0x0000-0x000F.  This seems to be a game/region identifier, and doesn't like its
136                contents changed (I didn't try changing every byte, but several of the bytes would throw RTC errors, even with a
137                fixed checksum).  I'd guess that the CF verifies this value, since it's different for every game (i.e. Mocap
138                Boxing NVRAM would have a correct checksum, but shouldn't pass Police 911 checks).
139                The second chunk goes from 0x0010-0x0079.  This seems to be a board identifier.  This has (optionally)
140                several fields, each of which are 20 bytes long.  I'm unsure of the first 6 bytes, the following 6
141                bytes are the DS2430A S/N, and the last 8 bytes are a game/region/dongle identifier.  If running
142                without a dongle, only the first 20 byte field is present.  With a dongle, a second 20 byte field will
143                be present.  Moving this second field into the place of the first field (and fixing the checksum)
144                doesn't work, and the second field will be ignored if the first field is valid for the game (and in
145                which case the dongle will be ignored).  For example, Police 911 will boot with a valid first field,
146                with or without the second field, and with or without the dongle plugged in.  If you have both fields,
147                and leave the dongle plugged in, you can switch between Police 911 and Police 911/2 by simply swapping
148                CF cards.
128149       29F002 - Fujitsu 29F002 256k x8 EEPROM stamped '941B01' (PLCC44 @ U25). Earlier revision stamped '941A01'
129150      CN4/CN5 - RCA-type network connection jacks
130151          CN7 - 80 pin connector (unused in all games?)
trunk/src/mame/drivers/wallc.c
r242372r242373
5858public:
5959   wallc_state(const machine_config &mconfig, device_type type, const char *tag)
6060      : driver_device(mconfig, type, tag),
61      m_videoram(*this, "videoram"),
6261      m_maincpu(*this, "maincpu"),
63      m_gfxdecode(*this, "gfxdecode") { }
62      m_gfxdecode(*this, "gfxdecode"),
63      m_videoram(*this, "videoram") { }
6464
65   required_device<cpu_device> m_maincpu;
66   required_device<gfxdecode_device> m_gfxdecode;
67   
6568   required_shared_ptr<UINT8> m_videoram;
69   
6670   tilemap_t *m_bg_tilemap;
71   
6772   DECLARE_WRITE8_MEMBER(wallc_videoram_w);
6873   DECLARE_WRITE8_MEMBER(wallc_coin_counter_w);
6974   DECLARE_DRIVER_INIT(wallc);
r242372r242373
7378   virtual void video_start();
7479   DECLARE_PALETTE_INIT(wallc);
7580   UINT32 screen_update_wallc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
76   required_device<cpu_device> m_maincpu;
77   required_device<gfxdecode_device> m_gfxdecode;
7881};
7982
8083
r242372r242373
143146
144147WRITE8_MEMBER(wallc_state::wallc_videoram_w)
145148{
146   UINT8 *videoram = m_videoram;
147   videoram[offset] = data;
149   m_videoram[offset] = data;
148150   m_bg_tilemap->mark_tile_dirty(offset);
149151}
150152
151153TILE_GET_INFO_MEMBER(wallc_state::get_bg_tile_info)
152154{
153   UINT8 *videoram = m_videoram;
154   SET_TILE_INFO_MEMBER(0, videoram[tile_index] + 0x100, 1, 0);
155   SET_TILE_INFO_MEMBER(0, m_videoram[tile_index] + 0x100, 1, 0);
155156}
156157
157158void wallc_state::video_start()
r242372r242373
487488
488489}
489490
490GAME( 1984, wallc,  0,      wallc,  wallc, wallc_state, wallc,  ROT0, "Midcoin", "Wall Crash (set 1)", 0 )
491GAME( 1984, wallca, wallc,  wallc,  wallc, wallc_state, wallca, ROT0, "Midcoin", "Wall Crash (set 2)", 0 )
492GAME( 1984, brkblast,wallc, wallc,  wallc, wallc_state, wallca, ROT0, "bootleg (Fadesa)", "Brick Blast (bootleg of Wall Crash)", 0 ) // Spanish bootleg board, Fadesa stickers / text on various components
491GAME( 1984, wallc,  0,      wallc,  wallc, wallc_state, wallc,  ROT0, "Midcoin", "Wall Crash (set 1)", GAME_SUPPORTS_SAVE )
492GAME( 1984, wallca, wallc,  wallc,  wallc, wallc_state, wallca, ROT0, "Midcoin", "Wall Crash (set 2)", GAME_SUPPORTS_SAVE )
493GAME( 1984, brkblast,wallc, wallc,  wallc, wallc_state, wallca, ROT0, "bootleg (Fadesa)", "Brick Blast (bootleg of Wall Crash)", GAME_SUPPORTS_SAVE ) // Spanish bootleg board, Fadesa stickers / text on various components
493494
494GAME( 1984, sidampkr,0,     wallc,  wallc, wallc_state, sidam,  ROT270, "Sidam", "unknown Sidam Poker", GAME_NOT_WORKING )
495GAME( 1984, sidampkr,0,     wallc,  wallc, wallc_state, sidam,  ROT270, "Sidam", "unknown Sidam Poker", GAME_NOT_WORKING | GAME_SUPPORTS_SAVE )
trunk/src/mess/drivers/ngen.c
r242372r242373
119119   DECLARE_WRITE8_MEMBER( dma_3_dack_w ){  }
120120   DECLARE_WRITE_LINE_MEMBER(fdc_irq_w);
121121   DECLARE_WRITE_LINE_MEMBER(fdc_drq_w);
122   DECLARE_WRITE8_MEMBER(fdc_control_w);
122123
123124protected:
124125   virtual void machine_reset();
r242372r242373
379380}
380381
381382// returns X-bus module ID (what is the low byte for?)
383// For now, we'll hard code a floppy disk module (or try to)
382384READ16_MEMBER(ngen_state::port00_r)
383385{
384386   if(m_port00 > 0)
385387      m_maincpu->set_input_line(INPUT_LINE_NMI,PULSE_LINE);
386388   if(m_port00 == 0)
387      return 0x4000;  // module ID of 0x40 = dual floppy disk module (need hardware manual to find other module IDs)
389      return 0x0040;  // module ID of 0x40 = dual floppy disk module (need hardware manual to find other module IDs)
388390   else
389391      return 0x0080;  // invalid device?
390392}
r242372r242373
396398
397399WRITE_LINE_MEMBER(ngen_state::fdc_drq_w)
398400{
399   // TODO
401   m_dmac->dreq3_w(state);
400402}
401403
404WRITE8_MEMBER(ngen_state::fdc_control_w)
405{
406   m_fdc->set_floppy(m_fd0->get_device());
407   m_fd0->get_device()->mon_w((~data) & 0x80);
408   m_fdc->dden_w(~data & 0x04);
409}
410
402411WRITE_LINE_MEMBER( ngen_state::dma_hrq_changed )
403412{
404413   m_maincpu->set_input_line(INPUT_LINE_HALT, state ? ASSERT_LINE : CLEAR_LINE);
r242372r242373
474483
475484void ngen_state::machine_reset()
476485{
486   m_port00 = 0;
477487   m_control = 0;
478488   m_viduart->write_dsr(0);
479489   m_viduart->write_cts(0);
490   m_fd0->get_device()->set_rpm(300);
480491}
481492
482493static ADDRESS_MAP_START( ngen_mem, AS_PROGRAM, 16, ngen_state )
r242372r242373
490501static ADDRESS_MAP_START( ngen_io, AS_IO, 16, ngen_state )
491502   AM_RANGE(0x0000, 0x0001) AM_READWRITE(port00_r,port00_w)
492503   AM_RANGE(0x0100, 0x0107) AM_DEVREADWRITE8("fdc",wd2797_t,read,write,0x00ff)  // a guess for now
493   // port 0x0108 is used also, maybe for motor control/side select?
504   AM_RANGE(0x0108, 0x0109) AM_WRITE8(fdc_control_w,0x00ff)
494505ADDRESS_MAP_END
495506
496507static ADDRESS_MAP_START( ngen386_mem, AS_PROGRAM, 32, ngen_state )
r242372r242373
517528SLOT_INTERFACE_END
518529
519530static SLOT_INTERFACE_START( ngen_floppies )
520   SLOT_INTERFACE( "525hd", FLOPPY_525_HD )
531   SLOT_INTERFACE( "525qd", FLOPPY_525_QD )
521532SLOT_INTERFACE_END
522533
523534static MACHINE_CONFIG_START( ngen, ngen_state )
r242372r242373
577588   MCFG_RS232_DCD_HANDLER(DEVWRITELINE("iouart", upd7201_device, dcdb_w))
578589   MCFG_RS232_RI_HANDLER(DEVWRITELINE("iouart", upd7201_device, rib_w))
579590
580   // TODO: SCN2652 MPCC, used for RS-422 cluster communications?
591   // TODO: SCN2652 MPCC (not implemented), used for RS-422 cluster communications?
581592
582593   // video board
583594   MCFG_SCREEN_ADD("screen", RASTER)
r242372r242373
603614   MCFG_CLOCK_SIGNAL_HANDLER(WRITELINE(ngen_state,timer_clk_out))
604615
605616   // floppy disk / hard disk module (WD2797 FDC, WD1010 HDC, plus an 8253 timer for each)
606   MCFG_WD2797x_ADD("fdc", XTAL_20MHz / 10)
617   MCFG_WD2797x_ADD("fdc", XTAL_20MHz / 20)
607618   MCFG_WD_FDC_INTRQ_CALLBACK(WRITELINE(ngen_state,fdc_irq_w))
608   MCFG_WD_FDC_DRQ_CALLBACK(WRITELINE(ngen_state,fdc_drq_w))
619   MCFG_WD_FDC_DRQ_CALLBACK(DEVWRITELINE("maincpu",i80186_cpu_device,drq1_w))
620   MCFG_WD_FDC_FORCE_READY
609621   MCFG_DEVICE_ADD("fdc_timer", PIT8253, 0)
610622   // TODO: WD1010 HDC (not implemented)
611623   MCFG_DEVICE_ADD("hdc_timer", PIT8253, 0)
612   MCFG_FLOPPY_DRIVE_ADD("fdc:0", ngen_floppies, "525hd", floppy_image_device::default_floppy_formats)
624   MCFG_FLOPPY_DRIVE_ADD("fdc:0", ngen_floppies, "525qd", floppy_image_device::default_floppy_formats)
613625
614626MACHINE_CONFIG_END
615627
trunk/src/mess/drivers/vtech1.c
r242372r242373
451451   MCFG_CASSETTE_ADD( "cassette" )
452452   MCFG_CASSETTE_FORMATS(vtech1_cassette_formats)
453453   MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_PLAY)
454   MCFG_CASSETTE_INTERFACE("vtech1_cass")
455
456   MCFG_SOFTWARE_LIST_ADD("cass_list", "vz_cass")
454457MACHINE_CONFIG_END
455458
456459static MACHINE_CONFIG_DERIVED( laser200, laser110 )


Previous 199869 Revisions Next


© 1997-2024 The MAME Team