Changeset 1489228 in buchla-emu
- Timestamp:
- 07/31/2017 05:48:15 PM (7 years ago)
- Branches:
- master
- Children:
- 8967dbc
- Parents:
- c5b6c90
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
emu/fdd.c
rc5b6c90 r1489228 46 46 #define COM_WR_TRA 0xf0 47 47 48 #define COM_LAT_CYC 1049 #define COM_EXE_CYC 1048 #define COM_LAT_CYC 5 49 #define COM_EXE_CYC 5 50 50 51 51 typedef enum { … … 256 256 257 257 rv = *state.dat; 258 size_t addr = (size_t)(state.dat - image);258 int32_t addr = (int32_t)(state.dat - image); 259 259 260 260 if ((addr & (SZ_SEC - 1)) == 0) { 261 ver2("addr 0x%06 zx -> 0x%02x", addr, rv);261 ver2("addr 0x%06x -> 0x%02x", addr, rv); 262 262 } 263 263 else { 264 ver3("addr 0x%06 zx -> 0x%02x", addr, rv);264 ver3("addr 0x%06x -> 0x%02x", addr, rv); 265 265 } 266 266 267 267 ++state.dat; 268 state.cyc = COM_EXE_CYC; 268 ++addr; 269 270 if ((addr & (SZ_SEC - 1)) == 0 && state.com == COM_RD_SEC) { 271 state.step = STEP_IDLE; 272 state.cyc = 0; 273 } 274 else { 275 state.cyc = COM_EXE_CYC; 276 } 277 269 278 break; 270 279 … … 349 358 (state.com == COM_WR_SEC || state.com == COM_WR_SEC_WP)) { 350 359 *state.dat = (uint8_t)val; 351 size_t addr = (size_t)(state.dat - image);360 int32_t addr = (int32_t)(state.dat - image); 352 361 353 362 if ((addr & (SZ_SEC - 1)) == 0) { 354 ver2("addr 0x%06 zx <- 0x%02x", addr, val);363 ver2("addr 0x%06x <- 0x%02x", addr, val); 355 364 } 356 365 else { 357 ver3("addr 0x%06 zx <- 0x%02x", addr, val);366 ver3("addr 0x%06x <- 0x%02x", addr, val); 358 367 } 359 368 360 369 ++state.dat; 361 state.cyc = COM_EXE_CYC; 370 ++addr; 371 372 if ((addr & (SZ_SEC - 1)) == 0) { 373 state.step = STEP_IDLE; 374 state.cyc = 0; 375 } 376 else { 377 state.cyc = COM_EXE_CYC; 378 } 362 379 } 363 380 else {
Note:
See TracChangeset
for help on using the changeset viewer.