Previous 15994 Revisions Next

r5533 Sunday 30th August, 2009 at 03:13:17 UTC by Jonathan Gevaryahu
[dectalk] a few fixes to fifo status regs, documented via trial and error a number of the LED error codes, still dies on the FD 00 one.
[src/mess/drivers]dectalk.c

src/mess/drivers/dectalk.c
r5532r5533
2121*  * emulate/simulate the MT8060 dtmf decoder as a 16-key input device?
2222*  * discuss and figure out how to have an external application send data to the two serial ports to be spoken
2323*
24* LED error code list (found by experimentation):
25*    FF 00 - M68k address register check fail (if data registers fail the processor just spins forever and no led code is generated)
26*    FF 01 - ROM check fail @ 0x00000, rom at E8 or E22
27*    FF 02 - ROM check fail @ 0x08000, rom at E7 or E21
28*    FF 03 - ROM check fail @ 0x10000, rom at E6 or E20
29*    FF 04 - ROM check fail @ 0x18000, rom at E5 or E19
30*    FF 05 - ROM check fail @ 0x20000, rom at E4 or E18
31*    FF 06 - ROM check fail @ 0x28000, rom at E3 or E17
32*    FF 07 - ROM check fail @ 0x30000, rom at E2 or E16
33*    FF 08 - ROM check fail @ 0x38000, rom at E1 or E15
34*    FF 0F - ROM check fail at multiple addresses
35*    FE 01 - RAM check fail @ 0x80000-0x83fff, ram at E36 or E49
36*    FE 02 - RAM check fail @ 0x84000-0x87fff, ram at E35 or E48
37*    FE 03 - RAM check fail @ 0x88000-0x8bfff, ram at E34 or E47
38*    FE 04 - RAM check fail @ 0x8c000-0x8ffff, ram at E33 or E46
39*    FE 05 - RAM check fail @ 0x90000-0x93fff, ram at E32 or E44
40*    FD 00 - unknown, probably either duart interface failure, interrupt failure, or duart timer failure
41
2442*******************************************************************************/
2543/*the 68k memory map is such:
26440x000000-0x007fff: E22 low, E8 high
r5532r5533
132150DRIVER_INIT( dectalk )
133151{
134152   dectalk_clear_all_fifos(machine);
135   dectalk.outfifo_writable_latch = 0;
136   dectalk.spc_error_latch = 0;
153   dectalk.outfifo_writable_latch = 0; // on the original dectalk pcb revision, this is a semaphore for the INPUT fifo, later dec hacked on a check for the 3 output fifo chips to see if they're in sync, and set both of these latches if true.
154   dectalk.spc_error_latch = 1; // normally would be 0, but if set to 1 on startup the dectalk should recover as well
137155}
138156
139157/* Machine reset: stuff that needs setting up which IS directly affected by reset */
r5532r5533
216234   {
217235      dectalk_clear_all_fifos(space->machine);
218236      /* write me */ // data&1 also forces the CLR line active on the tms32010, we need to do that here as well
237      // clear the two speech side latches
238      dectalk.spc_error_latch = 0;
239      dectalk.outfifo_writable_latch = 0;
219240   }
220241   if ((data&0x2) == 0x2) // bit 1
221242   {
222   // clear the two speech side latches
223   dectalk.spc_error_latch = 0;
224   dectalk.outfifo_writable_latch = 0;
243      // clear the two speech side latches
244      dectalk.spc_error_latch = 0;
245      dectalk.outfifo_writable_latch = 0;
225246   }
226247   if ((data&0x40) == 0x40) // bit 6
227248   {
r5532r5533
253274/* End 68k i/o handlers */
254275
255276/* Begin tms32010 i/o handlers */
256WRITE16_HANDLER( spc_latch_outfifo_error_stats ) // latch 74ls74 @ E64 upper and lower halves with d0 and fifo status respectively
277WRITE16_HANDLER( spc_latch_outfifo_error_stats ) // latch 74ls74 @ E64 upper and lower halves with d0 and 1 respectively
257278{
258    dectalk.outfifo_writable_latch = (dectalk.outfifo_tail_ptr == ((dectalk.outfifo_head_ptr-1)&0xF)?0:1); // may have polarity backwards
279    dectalk.outfifo_writable_latch = 1; // always set to 1 here.
259280    dectalk.spc_error_latch = data&1;
260281}
261282
r5532r5533
329350ADDRESS_MAP_END
330351
331352static ADDRESS_MAP_START(tms32010_io, ADDRESS_SPACE_IO, 16)
332    AM_RANGE(0, 0) AM_WRITE(spc_latch_outfifo_error_stats) // latch fifo status to be read by outfifo_status_r, and also latch the error bit at D0.
353    AM_RANGE(0, 0) AM_WRITE(spc_latch_outfifo_error_stats) // *set* the outfifo_status_r semaphore, and also latch the error bit at D0.
333354    AM_RANGE(1, 1) AM_READWRITE(spc_infifo_data_r, spc_outfifo_data_w) //read from input fifo, write to sound fifo
334355    AM_RANGE(TMS32010_BIO, TMS32010_BIO) AM_READ(spc_outfifo_writable_r) //read output fifo writable status
335356ADDRESS_MAP_END
r5532r5533
378399
379400ROM_START( dectalk )
380401   ROM_REGION16_BE(0x40000,"maincpu", 0)
381   // dectalk dtc-01 firmware v1.2? (first half: 23Jul84 tag; second half: 02Jul84 tag), all roms are 27128 eproms
402   // dectalk dtc-01 firmware v?.? (probably 1.4 or 2.1) (first half: 23Jul84 tag; second half: 02Jul84 tag), all roms are 27128 eproms
382403   ROM_LOAD16_BYTE("dtc01_e5.123", 0x00000, 0x4000, CRC(03e1eefa) SHA1(e586de03e113683c2534fca1f3f40ba391193044)) // Label: "SP8510123E5" @ E8
383404   ROM_LOAD16_BYTE("dtc01_e5.119", 0x00001, 0x4000, CRC(af20411f) SHA1(7954bb56b7591f8954403a22d34de31c7d5441ac)) // Label: "SP8510119E5" @ E22
384405   ROM_LOAD16_BYTE("dtc01_e5.124", 0x08000, 0x4000, CRC(9edeafcb) SHA1(7724babf4ae5d77c0b4200f608d599058d04b25c)) // Label: "SP8510124E5" @ E7

Previous 15994 Revisions Next


© 1998-2018 The MESS Team