src/mess/machine/c2040.c
| r7261 | r7262 | |
| 11 | 11 | |
| 12 | 12 | TODO: |
| 13 | 13 | |
| 14 | | - 8050 illegal track or sector 0,255 |
| 14 | - 8050 cannot load anything except directory |
| 15 | 15 | - 4040 bumps head before reading directory |
| 16 | - 2040 DOS 1 FDC rom |
| 16 | 17 | - Micropolis 8x50 stepper motor is same as 4040, except it takes 4 pulses to step a track instead of 1 |
| 17 | 18 | - save states |
| 18 | 19 | - remove via_pb_r |
| r7261 | r7262 | |
| 933 | 934 | |
| 934 | 935 | /* stepper motor 1 */ |
| 935 | 936 | int s1 = data & 0x03; |
| 936 | | mpi_step_motor(c2040, 0, mtr1, s1); |
| 937 | mpi_step_motor(c2040, 1, mtr1, s1); |
| 937 | 938 | |
| 938 | 939 | /* stepper motor 0 */ |
| 939 | 940 | int s0 = (data >> 2) & 0x03; |
| r7261 | r7262 | |
| 1120 | 1121 | data |= 0x10; |
| 1121 | 1122 | |
| 1122 | 1123 | /* single/dual sided */ |
| 1123 | | data |= (device->type == C8050) << 6; |
| 1124 | if (device->owner->type == C8050) |
| 1125 | { |
| 1126 | data |= 0x40; |
| 1127 | } |
| 1124 | 1128 | |
| 1125 | 1129 | return data; |
| 1126 | 1130 | } |
| r7261 | r7262 | |
| 1145 | 1149 | c2040_t *c2040 = get_safe_token(device->owner); |
| 1146 | 1150 | |
| 1147 | 1151 | /* drive select */ |
| 1148 | | if ((device->type == C8050) || (device->type == C8250)) |
| 1152 | if ((device->owner->type == C8050) || (device->owner->type == C8250)) |
| 1149 | 1153 | { |
| 1150 | 1154 | c2040->drive = BIT(newdata, 0); |
| 1151 | 1155 | } |
| r7261 | r7262 | |
| 1160 | 1164 | } |
| 1161 | 1165 | |
| 1162 | 1166 | /* side select */ |
| 1163 | | if ((device->type == C8250) || (device->type == SFD1001)) |
| 1167 | if ((device->owner->type == C8250) || (device->owner->type == SFD1001)) |
| 1164 | 1168 | { |
| 1165 | 1169 | c2040->side = !BIT(newdata, 4); |
| 1166 | 1170 | } |
| r7261 | r7262 | |
| 1186 | 1190 | -------------------------------------------------*/ |
| 1187 | 1191 | |
| 1188 | 1192 | static FLOPPY_OPTIONS_START( c2040 ) |
| 1189 | | FLOPPY_OPTION( c2040, "d67", "Commodore 2040/3040 (DOS 1) Disk Image", d67_dsk_identify, d64_dsk_construct, NULL ) |
| 1193 | FLOPPY_OPTION( c2040, "d67", "Commodore 2040/3040 Disk Image", d67_dsk_identify, d64_dsk_construct, NULL ) |
| 1194 | FLOPPY_OPTION( c2040, "g64", "Commodore 2040/3040 GCR Disk Image", g64_dsk_identify, g64_dsk_construct, NULL ) |
| 1190 | 1195 | FLOPPY_OPTIONS_END |
| 1191 | 1196 | |
| 1192 | 1197 | /*------------------------------------------------- |
src/mess/formats/g64_dsk.h
| r7261 | r7262 | |
| 30 | 30 | |
| 31 | 31 | const int C8050_BITRATE[] = |
| 32 | 32 | { |
| 33 | | XTAL_12MHz/3/16, /* tracks 1-39 */ |
| 34 | | XTAL_12MHz/3/15, /* tracks 40-53 */ |
| 35 | | XTAL_12MHz/3/14, /* tracks 54-65 */ |
| 36 | | XTAL_12MHz/3/13 /* tracks 65-84 */ |
| 33 | XTAL_12MHz/2/16, /* tracks 1-39 */ |
| 34 | XTAL_12MHz/2/15, /* tracks 40-53 */ |
| 35 | XTAL_12MHz/2/14, /* tracks 54-65 */ |
| 36 | XTAL_12MHz/2/13 /* tracks 65-84 */ |
| 37 | 37 | }; |
| 38 | 38 | |
| 39 | 39 | /*************************************************************************** |