Previous 15994 Revisions Next

r3280 Tuesday 16th September, 2008 at 18:04:05 UTC by Wilbert Pol
[TI99] Fixed crashes caused by cassette update
[src/mess/machine]ti99_4x.c

src/mess/machine/ti99_4x.c
r3279r3280
23142314   }
23152315   
23162316   /* we don't take CS2 into account, as CS2 is a write-only unit */
2317   /*if (cassette_input(device_list_find_by_tag( machine->config->devicelist, CASSETTE, "cassette" )) > 0)
2317   /*if (cassette_input(device_list_find_by_tag( machine->config->devicelist, CASSETTE, "cassette1" )) > 0)
23182318      answer |= 8;*/
23192319
23202320   return answer;
r3279r3280
23472347      answer = 4;   /* on systems without handset, the pin is pulled up to avoid spurious interrupts */
23482348
23492349   /* we don't take CS2 into account, as CS2 is a write-only unit */
2350   if (cassette_input(device_list_find_by_tag( machine->config->devicelist, CASSETTE, "cassette" )) > 0)
2351      answer |= 8;
2350   if ( ti99_model != model_99_8 )
2351   {
2352      if (cassette_input(device_list_find_by_tag( machine->config->devicelist, CASSETTE, "cassette1" )) > 0)
2353         answer |= 8;
2354   }
2355   else
2356   {
2357      if (cassette_input(device_list_find_by_tag( machine->config->devicelist, CASSETTE, "cassette" )) > 0)
2358         answer |= 8;
2359   }
23522360
23532361   return answer;
23542362}
r3279r3280
24812489static void ti99_CS_motor(int offset, int data)
24822490{
24832491   running_machine *machine = Machine;
2492   const device_config *img;
24842493
2485   const device_config *img = device_list_find_by_tag( machine->config->devicelist, CASSETTE, ( offset-6 ) ? "cassette2" :  "cassette1" );
2494   if ( ti99_model != model_99_8 )
2495   {
2496      img = device_list_find_by_tag( machine->config->devicelist, CASSETTE, ( offset-6 ) ? "cassette2" :  "cassette1" );
2497   }
2498   else
2499   {
2500      img = device_list_find_by_tag( machine->config->devicelist, CASSETTE, "cassette" );
2501   }
24862502   cassette_change_state(img, data ? CASSETTE_MOTOR_ENABLED : CASSETTE_MOTOR_DISABLED, CASSETTE_MASK_MOTOR);
24872503}
24882504

Previous 15994 Revisions Next


© 1998-2018 The MESS Team