diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..110aa05 --- /dev/null +++ b/.gitignore @@ -0,0 +1,22 @@ +# Build output (SDCC/Z80 toolchain — regenerated by build.bat) +obj/ +bin/ +build/ + +# SDCC-generated files if they ever end up outside obj/ +*.rel +*.lst +*.map +*.noi +*.sym +*.lk +*.ihx +*.adb +*.cdb +*.omf + +# Editor/OS cruft +.vscode/ +*.swp +Thumbs.db +.DS_Store diff --git a/XMPLAY.WMF b/XMPLAY.WMF index 980c271..3309aab 100644 Binary files a/XMPLAY.WMF and b/XMPLAY.WMF differ diff --git a/obj/hdr.asm b/obj/hdr.asm index 817799e..449474a 100644 --- a/obj/hdr.asm +++ b/obj/hdr.asm @@ -74,12 +74,12 @@ _hdr: .db #0x4d ; 77 'M' .db #0x44 ; 68 'D' .db #0x4c ; 76 'L' - .db #0x07 ; 7 + .db #0x0a ; 10 .db 0x00 .db #0x01 ; 1 .db #0x00 ; 0 .db #0x00 ; 0 - .db #0x1e ; 30 + .db #0x1d ; 29 .db 0x00 .db 0x00 .db 0x00 @@ -204,12 +204,7 @@ _hdr: .db 0x00 .db 0x00 .byte #0xff, #0xff, #0xff, #0xff ; 4294967295 - .ascii "XM Player" - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 + .ascii "XM Player v0.1" .db 0x00 .db 0x00 .db 0x00 @@ -291,25 +286,25 @@ _hdr: .db 0x00 .db 0x00 .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 - .db 0x00 + .db #0x12 ; 18 + .db #0x01 ; 1 + .db #0x73 ; 115 's' + .db #0x74 ; 116 't' + .db #0x6f ; 111 'o' + .db #0x70 ; 112 'p' + .db #0x6f ; 111 'o' + .db #0x6e ; 110 'n' + .db #0x65 ; 101 'e' + .db #0x72 ; 114 'r' + .db #0x72 ; 114 'r' + .db #0x6f ; 111 'o' + .db #0x72 ; 114 'r' + .db #0x02 ; 2 + .db #0x30 ; 48 '0' + .db #0x00 ; 0 + .db #0x31 ; 49 '1' + .db #0x00 ; 0 + .db #0x00 ; 0 .db 0x00 .db 0x00 .db 0x00 diff --git a/obj/hdr.bin b/obj/hdr.bin index 8c846cb..0974278 100644 Binary files a/obj/hdr.bin and b/obj/hdr.bin differ diff --git a/obj/hdr.hex b/obj/hdr.hex index 575accb..67feddb 100644 --- a/obj/hdr.hex +++ b/obj/hdr.hex @@ -1,12 +1,12 @@ :200200000000000000000000000000000000000057696C64436F6D6D616E6465724D444CDB -:2002200007000100001E000000000000000000000000000000000000000000000000000098 +:200220000A000100001D000000000000000000000000000000000000000000000000000096 :20024000584D20584D5A53334D000000000000000000000000000000000000000000000007 :2002600000000000000000000000000000000000000000000000000000000000000000007E :2002800000000000000000000000000000000000000000000000000000000000000000005E -:2002A00000FFFFFFFF584D20506C6179657200000000000000000000000000000000000010 +:2002A00000FFFFFFFF584D20506C617965722076302E3100000000000000000000000000EB :2002C00000000000000300000000000000000000000000000000000000000000000000001B :2002E0000000000000000000000000000000000000000000000000000000000000000000FE -:200300000000000000000000000000000000000000000000000000000000000000000000DD +:2003000000000000120173746F706F6E6572726F720230003100000000000000000000009A :200320000000000000000000000000000000000000000000000000000000000000000000BD :2003400000000000000000000000000000000000000000000000000000000000000000009D :2003600000000000000000000000000000000000000000000000000000000000000000007D diff --git a/obj/hdr.lst b/obj/hdr.lst index 4131236..26debb9 100644 --- a/obj/hdr.lst +++ b/obj/hdr.lst @@ -74,12 +74,12 @@ 0000001D 4D 74 .db #0x4d ; 77 'M' 0000001E 44 75 .db #0x44 ; 68 'D' 0000001F 4C 76 .db #0x4c ; 76 'L' - 00000020 07 77 .db #0x07 ; 7 + 00000020 0A 77 .db #0x0a ; 10 00000021 00 78 .db 0x00 00000022 01 79 .db #0x01 ; 1 00000023 00 80 .db #0x00 ; 0 00000024 00 81 .db #0x00 ; 0 - 00000025 1E 82 .db #0x1e ; 30 + 00000025 1D 82 .db #0x1d ; 29 00000026 00 83 .db 0x00 00000027 00 84 .db 0x00 00000028 00 85 .db 0x00 @@ -204,345 +204,340 @@ 0000009F 00 204 .db 0x00 000000A0 00 205 .db 0x00 000000A1 FF FF FF FF 206 .byte #0xff, #0xff, #0xff, #0xff ; 4294967295 - 000000A5 58 4D 20 50 6C 61 79 207 .ascii "XM Player" - 65 72 - 000000AE 00 208 .db 0x00 - 000000AF 00 209 .db 0x00 - 000000B0 00 210 .db 0x00 - 000000B1 00 211 .db 0x00 - 000000B2 00 212 .db 0x00 - 000000B3 00 213 .db 0x00 - 000000B4 00 214 .db 0x00 - 000000B5 00 215 .db 0x00 - 000000B6 00 216 .db 0x00 - 000000B7 00 217 .db 0x00 - 000000B8 00 218 .db 0x00 - 000000B9 00 219 .db 0x00 - 000000BA 00 220 .db 0x00 - 000000BB 00 221 .db 0x00 - 000000BC 00 222 .db 0x00 - 000000BD 00 223 .db 0x00 - 000000BE 00 224 .db 0x00 - 000000BF 00 225 .db 0x00 - 000000C0 00 226 .db 0x00 - 000000C1 00 227 .db 0x00 - 000000C2 00 228 .db 0x00 - 000000C3 00 229 .db 0x00 - 000000C4 00 230 .db 0x00 - 000000C5 03 231 .db #0x03 ; 3 - 000000C6 00 232 .db 0x00 - 000000C7 00 233 .db 0x00 - 000000C8 00 234 .db 0x00 - 000000C9 00 235 .db 0x00 - 000000CA 00 236 .db 0x00 - 000000CB 00 237 .db 0x00 - 000000CC 00 238 .db 0x00 - 000000CD 00 239 .db 0x00 - 000000CE 00 240 .db 0x00 - 000000CF 00 241 .db 0x00 - 000000D0 00 242 .db 0x00 - 000000D1 00 243 .db 0x00 - 000000D2 00 244 .db 0x00 - 000000D3 00 245 .db 0x00 - 000000D4 00 246 .db 0x00 - 000000D5 00 247 .db 0x00 - 000000D6 00 248 .db 0x00 - 000000D7 00 249 .db 0x00 - 000000D8 00 250 .db 0x00 - 000000D9 00 251 .db 0x00 - 000000DA 00 252 .db 0x00 - 000000DB 00 253 .db 0x00 - 000000DC 00 254 .db 0x00 - 000000DD 00 255 .db 0x00 - 000000DE 00 256 .db 0x00 - 000000DF 00 257 .db 0x00 - 000000E0 00 258 .db 0x00 - 000000E1 00 259 .db 0x00 - 000000E2 00 260 .db 0x00 - 000000E3 00 261 .db 0x00 - 000000E4 00 262 .db 0x00 - 000000E5 00 263 .db 0x00 - 000000E6 00 264 .db 0x00 - 000000E7 00 265 .db 0x00 - 000000E8 00 266 .db 0x00 - 000000E9 00 267 .db 0x00 - 000000EA 00 268 .db 0x00 - 000000EB 00 269 .db 0x00 - 000000EC 00 270 .db 0x00 - 000000ED 00 271 .db 0x00 - 000000EE 00 272 .db 0x00 - 000000EF 00 273 .db 0x00 - 000000F0 00 274 .db 0x00 - 000000F1 00 275 .db 0x00 - 000000F2 00 276 .db 0x00 - 000000F3 00 277 .db 0x00 - 000000F4 00 278 .db 0x00 - 000000F5 00 279 .db 0x00 - 000000F6 00 280 .db 0x00 - 000000F7 00 281 .db 0x00 - 000000F8 00 282 .db 0x00 - 000000F9 00 283 .db 0x00 - 000000FA 00 284 .db 0x00 - 000000FB 00 285 .db 0x00 - 000000FC 00 286 .db 0x00 - 000000FD 00 287 .db 0x00 - 000000FE 00 288 .db 0x00 - 000000FF 00 289 .db 0x00 - 00000100 00 290 .db 0x00 - 00000101 00 291 .db 0x00 - 00000102 00 292 .db 0x00 - 00000103 00 293 .db 0x00 - 00000104 00 294 .db 0x00 - 00000105 00 295 .db 0x00 - 00000106 00 296 .db 0x00 - 00000107 00 297 .db 0x00 - 00000108 00 298 .db 0x00 - 00000109 00 299 .db 0x00 - 0000010A 00 300 .db 0x00 - 0000010B 00 301 .db 0x00 - 0000010C 00 302 .db 0x00 - 0000010D 00 303 .db 0x00 - 0000010E 00 304 .db 0x00 - 0000010F 00 305 .db 0x00 - 00000110 00 306 .db 0x00 - 00000111 00 307 .db 0x00 - 00000112 00 308 .db 0x00 - 00000113 00 309 .db 0x00 - 00000114 00 310 .db 0x00 - 00000115 00 311 .db 0x00 - 00000116 00 312 .db 0x00 - 00000117 00 313 .db 0x00 - 00000118 00 314 .db 0x00 - 00000119 00 315 .db 0x00 - 0000011A 00 316 .db 0x00 - 0000011B 00 317 .db 0x00 - 0000011C 00 318 .db 0x00 - 0000011D 00 319 .db 0x00 - 0000011E 00 320 .db 0x00 - 0000011F 00 321 .db 0x00 - 00000120 00 322 .db 0x00 - 00000121 00 323 .db 0x00 - 00000122 00 324 .db 0x00 - 00000123 00 325 .db 0x00 - 00000124 00 326 .db 0x00 - 00000125 00 327 .db 0x00 - 00000126 00 328 .db 0x00 - 00000127 00 329 .db 0x00 - 00000128 00 330 .db 0x00 - 00000129 00 331 .db 0x00 - 0000012A 00 332 .db 0x00 - 0000012B 00 333 .db 0x00 - 0000012C 00 334 .db 0x00 - 0000012D 00 335 .db 0x00 - 0000012E 00 336 .db 0x00 - 0000012F 00 337 .db 0x00 - 00000130 00 338 .db 0x00 - 00000131 00 339 .db 0x00 - 00000132 00 340 .db 0x00 - 00000133 00 341 .db 0x00 - 00000134 00 342 .db 0x00 - 00000135 00 343 .db 0x00 - 00000136 00 344 .db 0x00 - 00000137 00 345 .db 0x00 - 00000138 00 346 .db 0x00 - 00000139 00 347 .db 0x00 - 0000013A 00 348 .db 0x00 - 0000013B 00 349 .db 0x00 - 0000013C 00 350 .db 0x00 - 0000013D 00 351 .db 0x00 - 0000013E 00 352 .db 0x00 - 0000013F 00 353 .db 0x00 - 00000140 00 354 .db 0x00 - 00000141 00 355 .db 0x00 - 00000142 00 356 .db 0x00 - 00000143 00 357 .db 0x00 - 00000144 00 358 .db 0x00 - 00000145 00 359 .db 0x00 - 00000146 00 360 .db 0x00 - 00000147 00 361 .db 0x00 - 00000148 00 362 .db 0x00 - 00000149 00 363 .db 0x00 - 0000014A 00 364 .db 0x00 - 0000014B 00 365 .db 0x00 - 0000014C 00 366 .db 0x00 - 0000014D 00 367 .db 0x00 - 0000014E 00 368 .db 0x00 - 0000014F 00 369 .db 0x00 - 00000150 00 370 .db 0x00 - 00000151 00 371 .db 0x00 - 00000152 00 372 .db 0x00 - 00000153 00 373 .db 0x00 - 00000154 00 374 .db 0x00 - 00000155 00 375 .db 0x00 - 00000156 00 376 .db 0x00 - 00000157 00 377 .db 0x00 - 00000158 00 378 .db 0x00 - 00000159 00 379 .db 0x00 - 0000015A 00 380 .db 0x00 - 0000015B 00 381 .db 0x00 - 0000015C 00 382 .db 0x00 - 0000015D 00 383 .db 0x00 - 0000015E 00 384 .db 0x00 - 0000015F 00 385 .db 0x00 - 00000160 00 386 .db 0x00 - 00000161 00 387 .db 0x00 - 00000162 00 388 .db 0x00 - 00000163 00 389 .db 0x00 - 00000164 00 390 .db 0x00 - 00000165 00 391 .db 0x00 - 00000166 00 392 .db 0x00 - 00000167 00 393 .db 0x00 - 00000168 00 394 .db 0x00 - 00000169 00 395 .db 0x00 - 0000016A 00 396 .db 0x00 - 0000016B 00 397 .db 0x00 - 0000016C 00 398 .db 0x00 - 0000016D 00 399 .db 0x00 - 0000016E 00 400 .db 0x00 - 0000016F 00 401 .db 0x00 - 00000170 00 402 .db 0x00 - 00000171 00 403 .db 0x00 - 00000172 00 404 .db 0x00 - 00000173 00 405 .db 0x00 - 00000174 00 406 .db 0x00 - 00000175 00 407 .db 0x00 - 00000176 00 408 .db 0x00 - 00000177 00 409 .db 0x00 - 00000178 00 410 .db 0x00 - 00000179 00 411 .db 0x00 - 0000017A 00 412 .db 0x00 - 0000017B 00 413 .db 0x00 - 0000017C 00 414 .db 0x00 - 0000017D 00 415 .db 0x00 - 0000017E 00 416 .db 0x00 - 0000017F 00 417 .db 0x00 - 00000180 00 418 .db 0x00 - 00000181 00 419 .db 0x00 - 00000182 00 420 .db 0x00 - 00000183 00 421 .db 0x00 - 00000184 00 422 .db 0x00 - 00000185 00 423 .db 0x00 - 00000186 00 424 .db 0x00 - 00000187 00 425 .db 0x00 - 00000188 00 426 .db 0x00 - 00000189 00 427 .db 0x00 - 0000018A 00 428 .db 0x00 - 0000018B 00 429 .db 0x00 - 0000018C 00 430 .db 0x00 - 0000018D 00 431 .db 0x00 - 0000018E 00 432 .db 0x00 - 0000018F 00 433 .db 0x00 - 00000190 00 434 .db 0x00 - 00000191 00 435 .db 0x00 - 00000192 00 436 .db 0x00 - 00000193 00 437 .db 0x00 - 00000194 00 438 .db 0x00 - 00000195 00 439 .db 0x00 - 00000196 00 440 .db 0x00 - 00000197 00 441 .db 0x00 - 00000198 00 442 .db 0x00 - 00000199 00 443 .db 0x00 - 0000019A 00 444 .db 0x00 - 0000019B 00 445 .db 0x00 - 0000019C 00 446 .db 0x00 - 0000019D 00 447 .db 0x00 - 0000019E 00 448 .db 0x00 - 0000019F 00 449 .db 0x00 - 000001A0 00 450 .db 0x00 - 000001A1 00 451 .db 0x00 - 000001A2 00 452 .db 0x00 - 000001A3 00 453 .db 0x00 - 000001A4 00 454 .db 0x00 - 000001A5 00 455 .db 0x00 - 000001A6 00 456 .db 0x00 - 000001A7 00 457 .db 0x00 - 000001A8 00 458 .db 0x00 - 000001A9 00 459 .db 0x00 - 000001AA 00 460 .db 0x00 - 000001AB 00 461 .db 0x00 - 000001AC 00 462 .db 0x00 - 000001AD 00 463 .db 0x00 - 000001AE 00 464 .db 0x00 - 000001AF 00 465 .db 0x00 - 000001B0 00 466 .db 0x00 - 000001B1 00 467 .db 0x00 - 000001B2 00 468 .db 0x00 - 000001B3 00 469 .db 0x00 - 000001B4 00 470 .db 0x00 - 000001B5 00 471 .db 0x00 - 000001B6 00 472 .db 0x00 - 000001B7 00 473 .db 0x00 - 000001B8 00 474 .db 0x00 - 000001B9 00 475 .db 0x00 - 000001BA 00 476 .db 0x00 - 000001BB 00 477 .db 0x00 - 000001BC 00 478 .db 0x00 - 000001BD 00 479 .db 0x00 - 000001BE 00 480 .db 0x00 - 000001BF 00 481 .db 0x00 - 000001C0 00 482 .db 0x00 - 000001C1 00 483 .db 0x00 - 000001C2 00 484 .db 0x00 - 000001C3 00 485 .db 0x00 - 000001C4 00 486 .db 0x00 - 000001C5 00 487 .db 0x00 - 000001C6 00 488 .db 0x00 - 000001C7 00 489 .db 0x00 - 000001C8 00 490 .db 0x00 - 000001C9 00 491 .db 0x00 - 000001CA 00 492 .db 0x00 - 000001CB 00 493 .db 0x00 - 000001CC 00 494 .db 0x00 - 000001CD 00 495 .db 0x00 - 000001CE 00 496 .db 0x00 - 000001CF 00 497 .db 0x00 - 000001D0 00 498 .db 0x00 - 000001D1 00 499 .db 0x00 - 000001D2 00 500 .db 0x00 - 000001D3 00 501 .db 0x00 - 000001D4 00 502 .db 0x00 - 000001D5 00 503 .db 0x00 - 000001D6 00 504 .db 0x00 - 000001D7 00 505 .db 0x00 - 000001D8 00 506 .db 0x00 - 000001D9 00 507 .db 0x00 - 000001DA 00 508 .db 0x00 - 000001DB 00 509 .db 0x00 - 000001DC 00 510 .db 0x00 - 000001DD 00 511 .db 0x00 - 000001DE 00 512 .db 0x00 - 000001DF 00 513 .db 0x00 - 000001E0 00 514 .db 0x00 - 000001E1 00 515 .db 0x00 - 000001E2 00 516 .db 0x00 - 000001E3 00 517 .db 0x00 - 000001E4 00 518 .db 0x00 - 000001E5 00 519 .db 0x00 - 000001E6 00 520 .db 0x00 - 000001E7 00 521 .db 0x00 - 000001E8 00 522 .db 0x00 - 000001E9 00 523 .db 0x00 - 000001EA 00 524 .db 0x00 - 000001EB 00 525 .db 0x00 - 000001EC 00 526 .db 0x00 - 000001ED 00 527 .db 0x00 - 000001EE 00 528 .db 0x00 - 000001EF 00 529 .db 0x00 - 000001F0 00 530 .db 0x00 - 000001F1 00 531 .db 0x00 - 000001F2 00 532 .db 0x00 - 000001F3 00 533 .db 0x00 - 000001F4 00 534 .db 0x00 - 000001F5 00 535 .db 0x00 - 000001F6 00 536 .db 0x00 - 000001F7 00 537 .db 0x00 - 000001F8 00 538 .db 0x00 - 000001F9 00 539 .db 0x00 - 000001FA 00 540 .db 0x00 - 000001FB 00 541 .db 0x00 - 000001FC 00 542 .db 0x00 - 000001FD 00 543 .db 0x00 - 000001FE 00 544 .db 0x00 - 000001FF 00 545 .db 0x00 - 546 .area _INITIALIZER - 547 .area _CABS (ABS) + 000000A5 58 4D 20 50 6C 61 79 207 .ascii "XM Player v0.1" + 65 72 20 76 30 2E 31 + 000000B3 00 208 .db 0x00 + 000000B4 00 209 .db 0x00 + 000000B5 00 210 .db 0x00 + 000000B6 00 211 .db 0x00 + 000000B7 00 212 .db 0x00 + 000000B8 00 213 .db 0x00 + 000000B9 00 214 .db 0x00 + 000000BA 00 215 .db 0x00 + 000000BB 00 216 .db 0x00 + 000000BC 00 217 .db 0x00 + 000000BD 00 218 .db 0x00 + 000000BE 00 219 .db 0x00 + 000000BF 00 220 .db 0x00 + 000000C0 00 221 .db 0x00 + 000000C1 00 222 .db 0x00 + 000000C2 00 223 .db 0x00 + 000000C3 00 224 .db 0x00 + 000000C4 00 225 .db 0x00 + 000000C5 03 226 .db #0x03 ; 3 + 000000C6 00 227 .db 0x00 + 000000C7 00 228 .db 0x00 + 000000C8 00 229 .db 0x00 + 000000C9 00 230 .db 0x00 + 000000CA 00 231 .db 0x00 + 000000CB 00 232 .db 0x00 + 000000CC 00 233 .db 0x00 + 000000CD 00 234 .db 0x00 + 000000CE 00 235 .db 0x00 + 000000CF 00 236 .db 0x00 + 000000D0 00 237 .db 0x00 + 000000D1 00 238 .db 0x00 + 000000D2 00 239 .db 0x00 + 000000D3 00 240 .db 0x00 + 000000D4 00 241 .db 0x00 + 000000D5 00 242 .db 0x00 + 000000D6 00 243 .db 0x00 + 000000D7 00 244 .db 0x00 + 000000D8 00 245 .db 0x00 + 000000D9 00 246 .db 0x00 + 000000DA 00 247 .db 0x00 + 000000DB 00 248 .db 0x00 + 000000DC 00 249 .db 0x00 + 000000DD 00 250 .db 0x00 + 000000DE 00 251 .db 0x00 + 000000DF 00 252 .db 0x00 + 000000E0 00 253 .db 0x00 + 000000E1 00 254 .db 0x00 + 000000E2 00 255 .db 0x00 + 000000E3 00 256 .db 0x00 + 000000E4 00 257 .db 0x00 + 000000E5 00 258 .db 0x00 + 000000E6 00 259 .db 0x00 + 000000E7 00 260 .db 0x00 + 000000E8 00 261 .db 0x00 + 000000E9 00 262 .db 0x00 + 000000EA 00 263 .db 0x00 + 000000EB 00 264 .db 0x00 + 000000EC 00 265 .db 0x00 + 000000ED 00 266 .db 0x00 + 000000EE 00 267 .db 0x00 + 000000EF 00 268 .db 0x00 + 000000F0 00 269 .db 0x00 + 000000F1 00 270 .db 0x00 + 000000F2 00 271 .db 0x00 + 000000F3 00 272 .db 0x00 + 000000F4 00 273 .db 0x00 + 000000F5 00 274 .db 0x00 + 000000F6 00 275 .db 0x00 + 000000F7 00 276 .db 0x00 + 000000F8 00 277 .db 0x00 + 000000F9 00 278 .db 0x00 + 000000FA 00 279 .db 0x00 + 000000FB 00 280 .db 0x00 + 000000FC 00 281 .db 0x00 + 000000FD 00 282 .db 0x00 + 000000FE 00 283 .db 0x00 + 000000FF 00 284 .db 0x00 + 00000100 00 285 .db 0x00 + 00000101 00 286 .db 0x00 + 00000102 00 287 .db 0x00 + 00000103 00 288 .db 0x00 + 00000104 12 289 .db #0x12 ; 18 + 00000105 01 290 .db #0x01 ; 1 + 00000106 73 291 .db #0x73 ; 115 's' + 00000107 74 292 .db #0x74 ; 116 't' + 00000108 6F 293 .db #0x6f ; 111 'o' + 00000109 70 294 .db #0x70 ; 112 'p' + 0000010A 6F 295 .db #0x6f ; 111 'o' + 0000010B 6E 296 .db #0x6e ; 110 'n' + 0000010C 65 297 .db #0x65 ; 101 'e' + 0000010D 72 298 .db #0x72 ; 114 'r' + 0000010E 72 299 .db #0x72 ; 114 'r' + 0000010F 6F 300 .db #0x6f ; 111 'o' + 00000110 72 301 .db #0x72 ; 114 'r' + 00000111 02 302 .db #0x02 ; 2 + 00000112 30 303 .db #0x30 ; 48 '0' + 00000113 00 304 .db #0x00 ; 0 + 00000114 31 305 .db #0x31 ; 49 '1' + 00000115 00 306 .db #0x00 ; 0 + 00000116 00 307 .db #0x00 ; 0 + 00000117 00 308 .db 0x00 + 00000118 00 309 .db 0x00 + 00000119 00 310 .db 0x00 + 0000011A 00 311 .db 0x00 + 0000011B 00 312 .db 0x00 + 0000011C 00 313 .db 0x00 + 0000011D 00 314 .db 0x00 + 0000011E 00 315 .db 0x00 + 0000011F 00 316 .db 0x00 + 00000120 00 317 .db 0x00 + 00000121 00 318 .db 0x00 + 00000122 00 319 .db 0x00 + 00000123 00 320 .db 0x00 + 00000124 00 321 .db 0x00 + 00000125 00 322 .db 0x00 + 00000126 00 323 .db 0x00 + 00000127 00 324 .db 0x00 + 00000128 00 325 .db 0x00 + 00000129 00 326 .db 0x00 + 0000012A 00 327 .db 0x00 + 0000012B 00 328 .db 0x00 + 0000012C 00 329 .db 0x00 + 0000012D 00 330 .db 0x00 + 0000012E 00 331 .db 0x00 + 0000012F 00 332 .db 0x00 + 00000130 00 333 .db 0x00 + 00000131 00 334 .db 0x00 + 00000132 00 335 .db 0x00 + 00000133 00 336 .db 0x00 + 00000134 00 337 .db 0x00 + 00000135 00 338 .db 0x00 + 00000136 00 339 .db 0x00 + 00000137 00 340 .db 0x00 + 00000138 00 341 .db 0x00 + 00000139 00 342 .db 0x00 + 0000013A 00 343 .db 0x00 + 0000013B 00 344 .db 0x00 + 0000013C 00 345 .db 0x00 + 0000013D 00 346 .db 0x00 + 0000013E 00 347 .db 0x00 + 0000013F 00 348 .db 0x00 + 00000140 00 349 .db 0x00 + 00000141 00 350 .db 0x00 + 00000142 00 351 .db 0x00 + 00000143 00 352 .db 0x00 + 00000144 00 353 .db 0x00 + 00000145 00 354 .db 0x00 + 00000146 00 355 .db 0x00 + 00000147 00 356 .db 0x00 + 00000148 00 357 .db 0x00 + 00000149 00 358 .db 0x00 + 0000014A 00 359 .db 0x00 + 0000014B 00 360 .db 0x00 + 0000014C 00 361 .db 0x00 + 0000014D 00 362 .db 0x00 + 0000014E 00 363 .db 0x00 + 0000014F 00 364 .db 0x00 + 00000150 00 365 .db 0x00 + 00000151 00 366 .db 0x00 + 00000152 00 367 .db 0x00 + 00000153 00 368 .db 0x00 + 00000154 00 369 .db 0x00 + 00000155 00 370 .db 0x00 + 00000156 00 371 .db 0x00 + 00000157 00 372 .db 0x00 + 00000158 00 373 .db 0x00 + 00000159 00 374 .db 0x00 + 0000015A 00 375 .db 0x00 + 0000015B 00 376 .db 0x00 + 0000015C 00 377 .db 0x00 + 0000015D 00 378 .db 0x00 + 0000015E 00 379 .db 0x00 + 0000015F 00 380 .db 0x00 + 00000160 00 381 .db 0x00 + 00000161 00 382 .db 0x00 + 00000162 00 383 .db 0x00 + 00000163 00 384 .db 0x00 + 00000164 00 385 .db 0x00 + 00000165 00 386 .db 0x00 + 00000166 00 387 .db 0x00 + 00000167 00 388 .db 0x00 + 00000168 00 389 .db 0x00 + 00000169 00 390 .db 0x00 + 0000016A 00 391 .db 0x00 + 0000016B 00 392 .db 0x00 + 0000016C 00 393 .db 0x00 + 0000016D 00 394 .db 0x00 + 0000016E 00 395 .db 0x00 + 0000016F 00 396 .db 0x00 + 00000170 00 397 .db 0x00 + 00000171 00 398 .db 0x00 + 00000172 00 399 .db 0x00 + 00000173 00 400 .db 0x00 + 00000174 00 401 .db 0x00 + 00000175 00 402 .db 0x00 + 00000176 00 403 .db 0x00 + 00000177 00 404 .db 0x00 + 00000178 00 405 .db 0x00 + 00000179 00 406 .db 0x00 + 0000017A 00 407 .db 0x00 + 0000017B 00 408 .db 0x00 + 0000017C 00 409 .db 0x00 + 0000017D 00 410 .db 0x00 + 0000017E 00 411 .db 0x00 + 0000017F 00 412 .db 0x00 + 00000180 00 413 .db 0x00 + 00000181 00 414 .db 0x00 + 00000182 00 415 .db 0x00 + 00000183 00 416 .db 0x00 + 00000184 00 417 .db 0x00 + 00000185 00 418 .db 0x00 + 00000186 00 419 .db 0x00 + 00000187 00 420 .db 0x00 + 00000188 00 421 .db 0x00 + 00000189 00 422 .db 0x00 + 0000018A 00 423 .db 0x00 + 0000018B 00 424 .db 0x00 + 0000018C 00 425 .db 0x00 + 0000018D 00 426 .db 0x00 + 0000018E 00 427 .db 0x00 + 0000018F 00 428 .db 0x00 + 00000190 00 429 .db 0x00 + 00000191 00 430 .db 0x00 + 00000192 00 431 .db 0x00 + 00000193 00 432 .db 0x00 + 00000194 00 433 .db 0x00 + 00000195 00 434 .db 0x00 + 00000196 00 435 .db 0x00 + 00000197 00 436 .db 0x00 + 00000198 00 437 .db 0x00 + 00000199 00 438 .db 0x00 + 0000019A 00 439 .db 0x00 + 0000019B 00 440 .db 0x00 + 0000019C 00 441 .db 0x00 + 0000019D 00 442 .db 0x00 + 0000019E 00 443 .db 0x00 + 0000019F 00 444 .db 0x00 + 000001A0 00 445 .db 0x00 + 000001A1 00 446 .db 0x00 + 000001A2 00 447 .db 0x00 + 000001A3 00 448 .db 0x00 + 000001A4 00 449 .db 0x00 + 000001A5 00 450 .db 0x00 + 000001A6 00 451 .db 0x00 + 000001A7 00 452 .db 0x00 + 000001A8 00 453 .db 0x00 + 000001A9 00 454 .db 0x00 + 000001AA 00 455 .db 0x00 + 000001AB 00 456 .db 0x00 + 000001AC 00 457 .db 0x00 + 000001AD 00 458 .db 0x00 + 000001AE 00 459 .db 0x00 + 000001AF 00 460 .db 0x00 + 000001B0 00 461 .db 0x00 + 000001B1 00 462 .db 0x00 + 000001B2 00 463 .db 0x00 + 000001B3 00 464 .db 0x00 + 000001B4 00 465 .db 0x00 + 000001B5 00 466 .db 0x00 + 000001B6 00 467 .db 0x00 + 000001B7 00 468 .db 0x00 + 000001B8 00 469 .db 0x00 + 000001B9 00 470 .db 0x00 + 000001BA 00 471 .db 0x00 + 000001BB 00 472 .db 0x00 + 000001BC 00 473 .db 0x00 + 000001BD 00 474 .db 0x00 + 000001BE 00 475 .db 0x00 + 000001BF 00 476 .db 0x00 + 000001C0 00 477 .db 0x00 + 000001C1 00 478 .db 0x00 + 000001C2 00 479 .db 0x00 + 000001C3 00 480 .db 0x00 + 000001C4 00 481 .db 0x00 + 000001C5 00 482 .db 0x00 + 000001C6 00 483 .db 0x00 + 000001C7 00 484 .db 0x00 + 000001C8 00 485 .db 0x00 + 000001C9 00 486 .db 0x00 + 000001CA 00 487 .db 0x00 + 000001CB 00 488 .db 0x00 + 000001CC 00 489 .db 0x00 + 000001CD 00 490 .db 0x00 + 000001CE 00 491 .db 0x00 + 000001CF 00 492 .db 0x00 + 000001D0 00 493 .db 0x00 + 000001D1 00 494 .db 0x00 + 000001D2 00 495 .db 0x00 + 000001D3 00 496 .db 0x00 + 000001D4 00 497 .db 0x00 + 000001D5 00 498 .db 0x00 + 000001D6 00 499 .db 0x00 + 000001D7 00 500 .db 0x00 + 000001D8 00 501 .db 0x00 + 000001D9 00 502 .db 0x00 + 000001DA 00 503 .db 0x00 + 000001DB 00 504 .db 0x00 + 000001DC 00 505 .db 0x00 + 000001DD 00 506 .db 0x00 + 000001DE 00 507 .db 0x00 + 000001DF 00 508 .db 0x00 + 000001E0 00 509 .db 0x00 + 000001E1 00 510 .db 0x00 + 000001E2 00 511 .db 0x00 + 000001E3 00 512 .db 0x00 + 000001E4 00 513 .db 0x00 + 000001E5 00 514 .db 0x00 + 000001E6 00 515 .db 0x00 + 000001E7 00 516 .db 0x00 + 000001E8 00 517 .db 0x00 + 000001E9 00 518 .db 0x00 + 000001EA 00 519 .db 0x00 + 000001EB 00 520 .db 0x00 + 000001EC 00 521 .db 0x00 + 000001ED 00 522 .db 0x00 + 000001EE 00 523 .db 0x00 + 000001EF 00 524 .db 0x00 + 000001F0 00 525 .db 0x00 + 000001F1 00 526 .db 0x00 + 000001F2 00 527 .db 0x00 + 000001F3 00 528 .db 0x00 + 000001F4 00 529 .db 0x00 + 000001F5 00 530 .db 0x00 + 000001F6 00 531 .db 0x00 + 000001F7 00 532 .db 0x00 + 000001F8 00 533 .db 0x00 + 000001F9 00 534 .db 0x00 + 000001FA 00 535 .db 0x00 + 000001FB 00 536 .db 0x00 + 000001FC 00 537 .db 0x00 + 000001FD 00 538 .db 0x00 + 000001FE 00 539 .db 0x00 + 000001FF 00 540 .db 0x00 + 541 .area _INITIALIZER + 542 .area _CABS (ABS) diff --git a/obj/hdr.rel b/obj/hdr.rel index 1330980..aa22ad8 100644 --- a/obj/hdr.rel +++ b/obj/hdr.rel @@ -18,9 +18,9 @@ T 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 T 0C 00 00 00 00 00 00 00 57 69 6C 64 43 6F 6D 6D R 00 00 00 00 -T 18 00 00 00 61 6E 64 65 72 4D 44 4C 07 00 01 00 +T 18 00 00 00 61 6E 64 65 72 4D 44 4C 0A 00 01 00 R 00 00 00 00 -T 24 00 00 00 00 1E 00 00 00 00 00 00 00 00 00 00 +T 24 00 00 00 00 1D 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 T 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 @@ -42,7 +42,7 @@ T 90 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 T 9C 00 00 00 00 00 00 00 00 FF FF FF FF 58 4D 20 R 00 00 00 00 -T A8 00 00 00 50 6C 61 79 65 72 00 00 00 00 00 00 +T A8 00 00 00 50 6C 61 79 65 72 20 76 30 2E 31 00 R 00 00 00 00 T B4 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 @@ -56,11 +56,11 @@ T E4 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 T F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 -T FC 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 +T FC 00 00 00 00 00 00 00 00 00 00 00 12 01 73 74 R 00 00 00 00 -T 08 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 +T 08 01 00 00 6F 70 6F 6E 65 72 72 6F 72 02 30 00 R 00 00 00 00 -T 14 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 +T 14 01 00 00 31 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 T 20 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 R 00 00 00 00 diff --git a/obj/out.asm b/obj/out.asm index d0245a3..58d7085 100644 --- a/obj/out.asm +++ b/obj/out.asm @@ -16,11 +16,16 @@ .globl _put_time .globl _put_dec3 .globl _put_hex2 + .globl _xm_set_status_attr .globl _xm_draw_static_labels .globl _copy_file_name .globl _error_playback .globl _error_oom + .globl _stop_on_error .globl _error_esp + .globl _wait_for_manual_exit + .globl _leave_playing_and_exit + .globl _unload_and_exit .globl _about .globl _wait_frames .globl _wait_esc_key @@ -37,10 +42,12 @@ .globl _esp_rd_reg32 .globl _esp_rd_reg8 .globl _esp_cmd - .globl _wc_set_freq_14mhz .globl _wc_exit + .globl _wc_prm_pl + .globl _wc_gadrw .globl _wc_prsrw_attr .globl _wc_prsrw + .globl _wc_key_space .globl _wc_key_pgdn .globl _wc_key_pgup .globl _wc_key_esc @@ -49,6 +56,7 @@ .globl _wc_prwow .globl _strlen .globl _state_esp + .globl _bar_attr_ofs .globl _last_track_status .globl _xm_handle .globl _total_samples @@ -62,10 +70,9 @@ .globl _fs_buf .globl _win_about .globl _win_xm - .globl _err_playback - .globl _err_out_of_mem - .globl _err_no_esp .globl _esp_wait_busy + .globl _xm_set_status + .globl _xm_set_status_code ;-------------------------------------------------------- ; special function registers ;-------------------------------------------------------- @@ -146,6 +153,10 @@ _xm_handle:: .ds 1 _last_track_status:: .ds 1 +_status_buf: + .ds 24 +_status_code_buf: + .ds 24 _hexbuf: .ds 2 _decbuf: @@ -153,7 +164,9 @@ _decbuf: _timebuf: .ds 5 _barbuf: - .ds 34 + .ds 32 +_bar_attr_ofs:: + .ds 2 ;-------------------------------------------------------- ; ram data ;-------------------------------------------------------- @@ -181,26 +194,15 @@ _state_esp:: ; code ;-------------------------------------------------------- .area _CODE -;src/wc_api.c:34: void wc_exit(u8 rc) __naked +;src/wc_api.c:47: void wc_exit(u8 rc) __naked ; --------------------------------- ; Function wc_exit ; --------------------------------- _wc_exit:: -;src/wc_api.c:40: __endasm; +;src/wc_api.c:53: __endasm; ld sp, (_ret_sp) ret -;src/wc_api.c:41: } -;src/wc_api.c:55: void wc_set_freq_14mhz() __naked -; --------------------------------- -; Function wc_set_freq_14mhz -; --------------------------------- -_wc_set_freq_14mhz:: -;src/wc_api.c:62: __endasm; - ld b, #0x00 ; type: Z80 frequency - ld c, #0x02 ; %10 = 14 MHz - ld a, #0x0E - jp 0x6006 -;src/wc_api.c:63: } +;src/wc_api.c:54: } ;src/esp32.c:18: void esp_cmd(u8 cmd) ; --------------------------------- ; Function esp_cmd @@ -507,9 +509,8 @@ _esp_send_dma:: out (_SPI_CTRL), a ;src/esp32.c:119: esp_wr_end(); call _esp_wr_end -;src/esp32.c:120: esp_wait_busy(60000); - ld de, #0xea60 - ld hl, #0x0000 +;src/esp32.c:120: esp_wait_busy(100); // 2s - esp32 consuming one DMA'd chunk should be near-instant + ld hl, #0x0064 call _esp_wait_busy ;src/esp32.c:121: } pop hl @@ -535,7 +536,7 @@ _esp_rd_end:: out (_SPI_CTRL), a ;src/esp32.c:129: } ret -;src/esp32.c:131: u32 esp_wait_status(u8 status, u32 timeout) +;src/esp32.c:139: u8 esp_wait_status(u8 status, u16 max_frames) ; --------------------------------- ; Function esp_wait_status ; --------------------------------- @@ -543,186 +544,160 @@ _esp_wait_status:: push ix ld ix, #0 add ix, sp - ld c, a -;src/esp32.c:133: while (--timeout) if (esp_rd_reg8(ESP_REG_STATUS) == status) break; - ld e, 4 (ix) - ld d, 5 (ix) - ld l, 6 (ix) - ld h, 7 (ix) + ld hl, #-5 + add hl, sp + ld sp, hl + ld -1 (ix), a + ld -3 (ix), e + ld -2 (ix), d +;src/esp32.c:141: u16 start = *(u16*)_TMN; + ld hl, #0x6009 + ld a, (hl) + ld -5 (ix), a + inc hl + ld a, (hl) + ld -4 (ix), a +;src/esp32.c:143: while ((u16)(*(u16*)_TMN - start) < max_frames) 00103$: - ld a, e - add a, #0xff - ld e, a - ld a, d - adc a, #0xff - ld d, a + ld hl, (#0x6009) ld a, l - adc a, #0xff - ld l, a + sub a, -5 (ix) + ld c, a ld a, h - adc a, #0xff - ld h, a - or a, l - or a, d - or a, e - jr z, 00105$ - push hl - push bc - push de + sbc a, -4 (ix) + ld b, a + ld a, c + sub a, -3 (ix) + ld a, b + sbc a, -2 (ix) + jr nc, 00105$ +;src/esp32.c:145: if (esp_rd_reg8(ESP_REG_STATUS) == status) ld a, #0x01 call _esp_rd_reg8 - pop de - pop bc - pop hl - sub a, c + sub a, -1 (ix) jr nz, 00103$ +;src/esp32.c:146: return 1; + ld a, #0x01 + jp 00106$ 00105$: -;src/esp32.c:135: return timeout; -;src/esp32.c:136: } +;src/esp32.c:149: return 0; + xor a, a +00106$: +;src/esp32.c:150: } + ld sp, ix pop ix ret -;src/esp32.c:138: u32 esp_wait_busy(u32 timeout) +;src/esp32.c:152: u8 esp_wait_busy(u16 max_frames) ; --------------------------------- ; Function esp_wait_busy ; --------------------------------- _esp_wait_busy:: -;src/esp32.c:140: while (--timeout) if (esp_rd_reg8(ESP_REG_STATUS) != ESP_ST_BUSY) break; + push ix + ld ix, #0 + add ix, sp + push af + push af + ld -2 (ix), l + ld -1 (ix), h +;src/esp32.c:154: u16 start = *(u16*)_TMN; + ld hl, #0x6009 + ld a, (hl) + ld -4 (ix), a + inc hl + ld a, (hl) + ld -3 (ix), a +;src/esp32.c:156: while ((u16)(*(u16*)_TMN - start) < max_frames) 00103$: - ld a, e - add a, #0xff - ld e, a - ld a, d - adc a, #0xff - ld d, a + ld hl, (#0x6009) ld a, l - adc a, #0xff - ld l, a + sub a, -4 (ix) + ld c, a ld a, h - adc a, #0xff - ld h, a - or a, l - or a, d - or a, e - ret z - push hl - push de + sbc a, -3 (ix) + ld b, a + ld a, c + sub a, -2 (ix) + ld a, b + sbc a, -1 (ix) + jr nc, 00105$ +;src/esp32.c:158: if (esp_rd_reg8(ESP_REG_STATUS) != ESP_ST_BUSY) ld a, #0x01 call _esp_rd_reg8 - pop de - pop hl cp a, #0x02 jr z, 00103$ -;src/esp32.c:142: return timeout; -;src/esp32.c:143: } +;src/esp32.c:159: return 1; + ld a, #0x01 + jp 00106$ +00105$: +;src/esp32.c:162: return 0; + xor a, a +00106$: +;src/esp32.c:163: } + ld sp, ix + pop ix ret -;src/esp32.c:145: int esp_create_obj(u32 size, u8 type) +;src/esp32.c:165: int esp_create_obj(u32 size, u8 type) ; --------------------------------- ; Function esp_create_obj ; --------------------------------- _esp_create_obj:: -;src/esp32.c:147: esp_wr_reg32(ESP_REG_DATA_SIZE, size); +;src/esp32.c:167: esp_wr_reg32(ESP_REG_DATA_SIZE, size); push hl push de ld a, #0x03 call _esp_wr_reg32 -;src/esp32.c:148: esp_wr_reg8(ESP_REG_OBJ_TYPE, type); +;src/esp32.c:168: esp_wr_reg8(ESP_REG_OBJ_TYPE, type); ld iy, #2 add iy, sp ld l, 0 (iy) ld a, #0x02 call _esp_wr_reg8 -;src/esp32.c:149: esp_cmd(ESP_CMD_MAKE_OBJECT); +;src/esp32.c:169: esp_cmd(ESP_CMD_MAKE_OBJECT); ld a, #0xe0 call _esp_cmd -;src/esp32.c:150: esp_wait_busy(20000); - ld de, #0x4e20 - ld hl, #0x0000 +;src/esp32.c:170: esp_wait_busy(100); // 2s - object allocation should be near-instant + ld hl, #0x0064 call _esp_wait_busy -;src/esp32.c:153: return esp_rd_reg8(ESP_REG_OBJ_HANDLE); +;src/esp32.c:173: return esp_rd_reg8(ESP_REG_OBJ_HANDLE); ld a, #0x0b call _esp_rd_reg8 ld e, a ld d, #0x00 -;src/esp32.c:154: } +;src/esp32.c:174: } pop hl inc sp jp (hl) -;src/main.c:143: bool esp_init() +;src/main.c:101: bool esp_init() ; --------------------------------- ; Function esp_init ; --------------------------------- _esp_init:: -;src/main.c:145: esp_cmd(ESP_CMD_NOP); +;src/main.c:103: esp_cmd(ESP_CMD_NOP); xor a, a call _esp_cmd -;src/main.c:146: esp_rd_end(); +;src/main.c:104: esp_rd_end(); call _esp_rd_end -;src/main.c:147: esp_wr_end(); +;src/main.c:105: esp_wr_end(); call _esp_wr_end -;src/main.c:151: return true; +;src/main.c:109: return true; ld a, #0x01 -;src/main.c:152: } +;src/main.c:110: } ret -_err_no_esp: - .db #0x01 ; 1 - .db #0x00 ; 0 - .db #0x18 ; 24 - .db #0x0a ; 10 - .db #0x20 ; 32 - .db #0x05 ; 5 - .db #0x2f ; 47 - .db #0x00 ; 0 - .dw #0x0000 - .db #0x00 ; 0 - .db #0x00 ; 0 - .dw __str_0 - .dw __str_1 - .dw __str_2 -_err_out_of_mem: - .db #0x01 ; 1 - .db #0x00 ; 0 - .db #0xff ; 255 - .db #0xff ; 255 - .db #0x20 ; 32 - .db #0x05 ; 5 - .db #0x2f ; 47 - .db #0x00 ; 0 - .dw #0x0000 - .db #0x00 ; 0 - .db #0x00 ; 0 - .dw __str_0 - .dw __str_1 - .dw __str_3 -_err_playback: - .db #0x01 ; 1 - .db #0x00 ; 0 - .db #0xff ; 255 - .db #0xff ; 255 - .db #0x20 ; 32 - .db #0x05 ; 5 - .db #0x2f ; 47 - .db #0x00 ; 0 - .dw #0x0000 - .db #0x00 ; 0 - .db #0x00 ; 0 - .dw __str_0 - .dw __str_1 - .dw __str_4 _win_xm: .db #0x81 ; 129 .db #0x00 ; 0 .db #0x19 ; 25 .db #0x0a ; 10 .db #0x28 ; 40 - .db #0x0b ; 11 - .db #0x4f ; 79 'O' + .db #0x0c ; 12 + .db #0x70 ; 112 'p' .db #0x00 ; 0 .dw #0x0000 .db #0x00 ; 0 .db #0x00 ; 0 - .dw __str_5 + .dw __str_0 + .dw __str_1 .dw __str_1 - .dw __str_6 _win_about: .db #0x01 ; 1 .db #0x00 ; 0 @@ -735,54 +710,26 @@ _win_about: .dw #0x0000 .db #0x00 ; 0 .db #0x00 ; 0 - .dw __str_7 + .dw __str_2 .dw __str_1 - .dw __str_8 + .dw __str_3 __str_0: .db 0x0e - .ascii " Error! " + .ascii " XM/XMZ/S3M Player v0.1 " .db 0x00 __str_1: .db 0x00 __str_2: .db 0x0e - .db 0x0c - .db 0x01 - .ascii "No ESP32 detected!" + .ascii " About " .db 0x00 __str_3: .db 0x0e .db 0x0c .db 0x01 - .ascii "Out of memory (file too big)" + .ascii "XM Player v0.1" .db 0x00 -__str_4: - .db 0x0e - .db 0x0c - .db 0x01 - .ascii "Playback error (bad file?)" - .db 0x00 -__str_5: - .db 0x0e - .ascii " XM/XMZ/S3M Player " - .db 0x00 -__str_6: - .db 0x0e - .db 0x0c - .db 0x01 - .ascii "Playing..." - .db 0x00 -__str_7: - .db 0x0e - .ascii " About " - .db 0x00 -__str_8: - .db 0x0e - .db 0x0c - .db 0x01 - .ascii "XM Player v1.0" - .db 0x00 -;src/main.c:156: bool play_xm() +;src/main.c:114: bool play_xm() ; --------------------------------- ; Function play_xm ; --------------------------------- @@ -793,21 +740,19 @@ _play_xm:: ld hl, #-20 add hl, sp ld sp, hl -;src/main.c:158: esp_cmd(ESP_CMD_TRACK_STOP); +;src/main.c:116: esp_cmd(ESP_CMD_TRACK_STOP); ld a, #0xa2 call _esp_cmd -;src/main.c:159: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 +;src/main.c:117: esp_wait_busy(100); // 2s - both should be near-instant + ld hl, #0x0064 call _esp_wait_busy -;src/main.c:160: esp_cmd(ESP_CMD_KILL_OBJECTS); +;src/main.c:118: esp_cmd(ESP_CMD_KILL_OBJECTS); ld a, #0xe4 call _esp_cmd -;src/main.c:161: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 +;src/main.c:119: esp_wait_busy(100); + ld hl, #0x0064 call _esp_wait_busy -;src/main.c:164: switch (file_ext) +;src/main.c:122: switch (file_ext) ld a, (_file_ext) dec a jr z, 00101$ @@ -815,20 +760,20 @@ _play_xm:: sub a, #0x02 jr z, 00102$ jp 00103$ -;src/main.c:166: case EXT_XMZ: obj_type = OBJ_TYPE_ZIP; break; +;src/main.c:124: case EXT_XMZ: obj_type = OBJ_TYPE_ZIP; break; 00101$: ld a, #0x08 jp 00104$ -;src/main.c:167: case EXT_S3M: obj_type = OBJ_TYPE_S3M; break; +;src/main.c:125: case EXT_S3M: obj_type = OBJ_TYPE_S3M; break; 00102$: ld a, #0x0c jp 00104$ -;src/main.c:168: default: obj_type = OBJ_TYPE_XM; break; +;src/main.c:126: default: obj_type = OBJ_TYPE_XM; break; 00103$: ld a, #0x05 -;src/main.c:169: } +;src/main.c:127: } 00104$: -;src/main.c:171: xm_handle = esp_create_obj(filesize, obj_type); +;src/main.c:129: xm_handle = esp_create_obj(filesize, obj_type); push af inc sp ld de, (_filesize) @@ -836,46 +781,46 @@ _play_xm:: call _esp_create_obj ld hl, #_xm_handle ld (hl), e -;src/main.c:172: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); +;src/main.c:130: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); ld a, #0x01 call _esp_rd_reg8 ld (#_last_esp_status), a -;src/main.c:173: if (last_esp_status != ESP_ST_READY) +;src/main.c:131: if (last_esp_status != ESP_ST_READY) ld a, (_last_esp_status) dec a jr z, 00106$ -;src/main.c:174: return false; +;src/main.c:132: return false; xor a, a - jp 00116$ + jp 00118$ 00106$: -;src/main.c:176: u32 sz = filesize; +;src/main.c:134: u32 sz = filesize; ld hl, #12 add hl, sp ex de, hl ld hl, #_filesize ld bc, #4 ldir -;src/main.c:177: u32 offs = 0; +;src/main.c:135: u32 offs = 0; xor a, a ld -4 (ix), a ld -3 (ix), a ld -2 (ix), a ld -1 (ix), a -;src/main.c:179: while (sz) +;src/main.c:137: while (sz) 00107$: ld a, -5 (ix) or a, -6 (ix) or a, -7 (ix) or a, -8 (ix) jp z, 00109$ -;src/main.c:181: u32 s = min(sz, FS_BUF_SIZE); +;src/main.c:139: u32 s = min(sz, FS_BUF_SIZE); ld a, -7 (ix) sub a, #0x10 ld a, -6 (ix) sbc a, #0x00 ld a, -5 (ix) sbc a, #0x00 - jr nc, 00118$ + jr nc, 00120$ ld hl, #0 add hl, sp ex de, hl @@ -883,14 +828,14 @@ _play_xm:: add hl, sp ld bc, #4 ldir - jp 00119$ -00118$: + jp 00121$ +00120$: ld -20 (ix), #0x00 ld -19 (ix), #0x10 xor a, a ld -18 (ix), a ld -17 (ix), a -00119$: +00121$: ld hl, #5 add hl, sp ex de, hl @@ -898,7 +843,7 @@ _play_xm:: add hl, sp ld bc, #4 ldir -;src/main.c:182: u8 sec = (s + 511) >> 9; +;src/main.c:140: u8 sec = (s + 511) >> 9; ld a, -15 (ix) add a, #0xff ld a, -14 (ix) @@ -916,14 +861,14 @@ _play_xm:: srl e rr b rr c -;src/main.c:184: wc_load512((u16)fs_buf, sec); +;src/main.c:142: wc_load512((u16)fs_buf, sec); ld -9 (ix), c ld a, c push af inc sp ld hl, #_fs_buf call _wc_load512 -;src/main.c:186: esp_wr_reg32(ESP_REG_DATA_SIZE, s); +;src/main.c:144: esp_wr_reg32(ESP_REG_DATA_SIZE, s); ld hl, #0x0 push hl ld l, -15 (ix) @@ -931,7 +876,7 @@ _play_xm:: push hl ld a, #0x03 call _esp_wr_reg32 -;src/main.c:187: esp_wr_reg32(ESP_REG_DATA_OFFSET, offs); +;src/main.c:145: esp_wr_reg32(ESP_REG_DATA_OFFSET, offs); ld l, -2 (ix) ld h, -1 (ix) push hl @@ -940,19 +885,14 @@ _play_xm:: push hl ld a, #0x07 call _esp_wr_reg32 -;src/main.c:188: esp_cmd(ESP_CMD_WRITE_OBJECT); +;src/main.c:146: esp_cmd(ESP_CMD_WRITE_OBJECT); ld a, #0xe1 call _esp_cmd -;src/main.c:189: esp_wait_status(ESP_ST_DATA_M2S, 2000); - ld hl, #0x0000 - push hl - ld hl, #0x07d0 - push hl +;src/main.c:147: esp_wait_status(ESP_ST_DATA_M2S, 100); // 2s - near-instant state transition + ld de, #0x0064 ld a, #0x03 call _esp_wait_status - pop af - pop af -;src/main.c:190: esp_send_dma((u16)fs_buf, *(u8*)_PAGE2, 512, sec); +;src/main.c:148: esp_send_dma((u16)fs_buf, *(u8*)_PAGE2, 512, sec); ld a, -9 (ix) ld -11 (ix), a ld -10 (ix), #0x00 @@ -968,7 +908,7 @@ _play_xm:: inc sp ld hl, #_fs_buf call _esp_send_dma -;src/main.c:192: offs += s; +;src/main.c:150: offs += s; ld e, -15 (ix) ld d, -14 (ix) ld l, -4 (ix) @@ -979,10 +919,10 @@ _play_xm:: ld a, -2 (ix) adc a, -13 (ix) ld -2 (ix), a - jr nc, 00197$ + jr nc, 00207$ inc -1 (ix) -00197$: -;src/main.c:193: sz -= s; +00207$: +;src/main.c:151: sz -= s; ld a, -8 (ix) sub a, -15 (ix) ld -8 (ix), a @@ -997,265 +937,630 @@ _play_xm:: ld -5 (ix), a jp 00107$ 00109$: -;src/main.c:196: if (file_ext == EXT_XMZ) +;src/main.c:154: if (file_ext == EXT_XMZ) ld a, (_file_ext) dec a jr nz, 00113$ -;src/main.c:201: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); +;src/main.c:159: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); ld a, (_xm_handle) ld l, a ld a, #0x0b call _esp_wr_reg8 -;src/main.c:202: esp_wr_reg8(ESP_REG_OBJ_TYPE, OBJ_TYPE_XM); +;src/main.c:160: esp_wr_reg8(ESP_REG_OBJ_TYPE, OBJ_TYPE_XM); ld l, #0x05 ld a, #0x02 call _esp_wr_reg8 -;src/main.c:203: esp_wr_reg32(ESP_REG_DATA_SIZE, filesize); +;src/main.c:161: esp_wr_reg32(ESP_REG_DATA_SIZE, filesize); ld hl, (_filesize + 2) push hl ld hl, (_filesize) push hl ld a, #0x03 call _esp_wr_reg32 -;src/main.c:204: esp_cmd(ESP_CMD_UNZIP); +;src/main.c:162: esp_cmd(ESP_CMD_UNZIP); ld a, #0xf2 call _esp_cmd -;src/main.c:205: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 +;src/main.c:163: esp_wait_busy(250); // 5s - decompression time scales with file size + ld hl, #0x00fa call _esp_wait_busy -;src/main.c:207: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); +;src/main.c:165: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); ld a, #0x01 call _esp_rd_reg8 ld (#_last_esp_status), a -;src/main.c:208: if (last_esp_status != ESP_ST_READY) +;src/main.c:166: if (last_esp_status != ESP_ST_READY) ld a, (_last_esp_status) dec a jr z, 00113$ -;src/main.c:209: return false; +;src/main.c:167: return false; xor a, a - jp 00116$ + jp 00118$ 00113$: -;src/main.c:212: esp_cmd(ESP_CMD_TRACK_INIT); +;src/main.c:170: esp_cmd(ESP_CMD_TRACK_INIT); ld a, #0xa0 call _esp_cmd -;src/main.c:220: esp_wait_busy(1000000); - ld de, #0x4240 - ld hl, #0x000f +;src/main.c:176: esp_wait_busy(400); + ld hl, #0x0190 call _esp_wait_busy -;src/main.c:222: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); +;src/main.c:178: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); ld a, #0x01 call _esp_rd_reg8 ld (#_last_esp_status), a -;src/main.c:223: if (last_esp_status != ESP_ST_READY) +;src/main.c:179: if (last_esp_status != ESP_ST_READY) ld a, (_last_esp_status) dec a jr z, 00115$ -;src/main.c:224: return false; +;src/main.c:180: return false; xor a, a - jp 00116$ + jp 00118$ 00115$: -;src/main.c:229: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); +;src/main.c:185: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); ld a, (_xm_handle) ld l, a ld a, #0x0b call _esp_wr_reg8 -;src/main.c:230: esp_wr_reg8(ESP_REG_TRACK_MAX_LOOP_COUNT, 1); +;src/main.c:186: esp_wr_reg8(ESP_REG_TRACK_MAX_LOOP_COUNT, 1); ld l, #0x01 ld a, #0x3a call _esp_wr_reg8 -;src/main.c:231: esp_cmd(ESP_CMD_TRACK_SET_PARAMS); +;src/main.c:187: esp_cmd(ESP_CMD_TRACK_SET_PARAMS); ld a, #0xa6 call _esp_cmd -;src/main.c:232: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 +;src/main.c:188: esp_wait_busy(100); // 2s - both should be near-instant + ld hl, #0x0064 call _esp_wait_busy -;src/main.c:234: esp_cmd(ESP_CMD_TRACK_PLAY); +;src/main.c:190: esp_cmd(ESP_CMD_TRACK_PLAY); ld a, #0xa1 call _esp_cmd -;src/main.c:235: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 +;src/main.c:191: esp_wait_busy(100); + ld hl, #0x0064 call _esp_wait_busy -;src/main.c:237: return true; +;src/main.c:193: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); ld a, #0x01 -00116$: -;src/main.c:238: } + call _esp_rd_reg8 + ld (#_last_esp_status), a +;src/main.c:194: if (last_esp_status != ESP_ST_READY) + ld a, (_last_esp_status) + dec a + jr z, 00117$ +;src/main.c:195: return false; + xor a, a + jp 00118$ +00117$: +;src/main.c:197: return true; + ld a, #0x01 +00118$: +;src/main.c:198: } ld sp, ix pop ix ret -;src/main.c:241: void wait_esc_key() +;src/main.c:201: void wait_esc_key() ; --------------------------------- ; Function wait_esc_key ; --------------------------------- _wait_esc_key:: -;src/main.c:243: while (1) +;src/main.c:203: while (1) 00104$: -;src/main.c:247: __endasm; +;src/main.c:207: __endasm; halt -;src/main.c:249: if (wc_key_esc()) +;src/main.c:209: if (wc_key_esc()) call _wc_key_esc or a, a jr z, 00104$ -;src/main.c:250: break; -;src/main.c:252: } +;src/main.c:210: break; +;src/main.c:212: } ret -;src/main.c:254: void wait_frames(u8 n) +;src/main.c:214: void wait_frames(u8 n) ; --------------------------------- ; Function wait_frames ; --------------------------------- _wait_frames:: ld c, a -;src/main.c:256: while (n--) +;src/main.c:216: while (n--) 00101$: ld a, c dec c or a, a ret z -;src/main.c:260: __endasm; +;src/main.c:220: __endasm; halt -;src/main.c:262: } +;src/main.c:222: } jp 00101$ -;src/main.c:264: void about() +;src/main.c:224: void about() ; --------------------------------- ; Function about ; --------------------------------- _about:: -;src/main.c:266: wc_prwow(&win_about); +;src/main.c:226: wc_prwow(&win_about); ld hl, #_win_about call _wc_prwow -;src/main.c:267: wait_esc_key(); +;src/main.c:227: wait_esc_key(); call _wait_esc_key -;src/main.c:268: wc_rresb(&win_about); +;src/main.c:228: wc_rresb(&win_about); ld hl, #_win_about call _wc_rresb -;src/main.c:269: wc_exit(WC_EXIT); +;src/main.c:229: wc_exit(WC_EXIT); xor a, a -;src/main.c:270: } +;src/main.c:230: } jp _wc_exit -;src/main.c:272: void error_esp() +;src/main.c:235: void unload_and_exit(WC_EXIT_SIGNAL sig) +; --------------------------------- +; Function unload_and_exit +; --------------------------------- +_unload_and_exit:: + dec sp + ld iy, #0 + add iy, sp + ld 0 (iy), a +;src/main.c:237: esp_cmd(ESP_CMD_TRACK_STOP); + ld a, #0xa2 + call _esp_cmd +;src/main.c:238: esp_wait_busy(100); // 2s - both should be near-instant + ld hl, #0x0064 + call _esp_wait_busy +;src/main.c:239: esp_cmd(ESP_CMD_KILL_OBJECTS); + ld a, #0xe4 + call _esp_cmd +;src/main.c:240: esp_wait_busy(100); + ld hl, #0x0064 + call _esp_wait_busy +;src/main.c:241: wc_rresb(&win_xm); + ld hl, #_win_xm + call _wc_rresb +;src/main.c:242: wc_exit(sig); + ld hl, #0 + add hl, sp + ld a, (hl) + inc sp + jp _wc_exit +;src/main.c:243: } + inc sp + ret +;src/main.c:247: void leave_playing_and_exit() +; --------------------------------- +; Function leave_playing_and_exit +; --------------------------------- +_leave_playing_and_exit:: +;src/main.c:249: wc_rresb(&win_xm); + ld hl, #_win_xm + call _wc_rresb +;src/main.c:250: wc_exit(WC_EXIT); + xor a, a +;src/main.c:251: } + jp _wc_exit +;src/main.c:257: void wait_for_manual_exit() +; --------------------------------- +; Function wait_for_manual_exit +; --------------------------------- +_wait_for_manual_exit:: +;src/main.c:259: while (1) +00108$: +;src/main.c:263: __endasm; + halt +;src/main.c:265: if (wc_key_pgdn()) + call _wc_key_pgdn + or a, a + jr z, 00102$ +;src/main.c:266: unload_and_exit(WC_NEXT_FILE); + ld a, #0x02 + call _unload_and_exit +00102$: +;src/main.c:268: if (wc_key_pgup()) + call _wc_key_pgup + or a, a + jr z, 00104$ +;src/main.c:269: unload_and_exit(WC_PREV_FILE); + ld a, #0x04 + call _unload_and_exit +00104$: +;src/main.c:271: if (wc_key_esc()) + call _wc_key_esc + or a, a + jr z, 00108$ +;src/main.c:272: unload_and_exit(WC_EXIT); + xor a, a + call _unload_and_exit +;src/main.c:274: } + jp 00108$ +;src/main.c:280: void error_esp() ; --------------------------------- ; Function error_esp ; --------------------------------- _error_esp:: -;src/main.c:274: wc_prwow(&err_no_esp); - ld hl, #_err_no_esp - call _wc_prwow -;src/main.c:275: wait_esc_key(); +;src/main.c:285: xm_set_status_code("No ESP32 found", state_esp); + ld a, (_state_esp) + push af + inc sp + ld hl, #___str_4 + call _xm_set_status_code +;src/main.c:286: wait_esc_key(); call _wait_esc_key -;src/main.c:276: wc_rresb(&err_no_esp); - ld hl, #_err_no_esp +;src/main.c:287: wc_rresb(&win_xm); + ld hl, #_win_xm call _wc_rresb -;src/main.c:277: wc_exit(WC_EXIT); +;src/main.c:288: wc_exit(WC_EXIT); xor a, a -;src/main.c:278: } +;src/main.c:289: } jp _wc_exit -;src/main.c:280: void error_oom() +___str_4: + .ascii "No ESP32 found" + .db 0x00 +;src/main.c:299: u8 stop_on_error() +; --------------------------------- +; Function stop_on_error +; --------------------------------- +_stop_on_error:: +;src/main.c:301: return wc_prm_pl(1) == 2; + ld a, #0x01 + call _wc_prm_pl + cp a, #0x02 + ld a, #0x01 + ret z + xor a, a +;src/main.c:302: } + ret +;src/main.c:304: void error_oom() ; --------------------------------- ; Function error_oom ; --------------------------------- _error_oom:: -;src/main.c:282: wc_prwow(&err_out_of_mem); - ld hl, #_err_out_of_mem - call _wc_prwow -;src/main.c:283: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance +;src/main.c:306: xm_set_status_code("File too large", last_esp_status); + ld a, (_last_esp_status) + push af + inc sp + ld hl, #___str_5 + call _xm_set_status_code +;src/main.c:308: if (stop_on_error()) + call _stop_on_error + or a, a + jr z, 00102$ +;src/main.c:309: wait_for_manual_exit(); + call _wait_for_manual_exit +00102$: +;src/main.c:311: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance ld a, #0x32 call _wait_frames -;src/main.c:284: wc_rresb(&err_out_of_mem); - ld hl, #_err_out_of_mem +;src/main.c:312: wc_rresb(&win_xm); + ld hl, #_win_xm call _wc_rresb -;src/main.c:285: wc_exit(WC_NEXT_FILE); +;src/main.c:313: wc_exit(WC_NEXT_FILE); ld a, #0x02 -;src/main.c:286: } +;src/main.c:314: } jp _wc_exit -;src/main.c:288: void error_playback() +___str_5: + .ascii "File too large" + .db 0x00 +;src/main.c:316: void error_playback() ; --------------------------------- ; Function error_playback ; --------------------------------- _error_playback:: -;src/main.c:290: wc_prwow(&err_playback); - ld hl, #_err_playback - call _wc_prwow -;src/main.c:291: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance +;src/main.c:318: xm_set_status_code("Playback error", last_esp_status); + ld a, (_last_esp_status) + push af + inc sp + ld hl, #___str_6 + call _xm_set_status_code +;src/main.c:320: if (stop_on_error()) + call _stop_on_error + or a, a + jr z, 00102$ +;src/main.c:321: wait_for_manual_exit(); + call _wait_for_manual_exit +00102$: +;src/main.c:323: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance ld a, #0x32 call _wait_frames -;src/main.c:292: wc_rresb(&err_playback); - ld hl, #_err_playback +;src/main.c:324: wc_rresb(&win_xm); + ld hl, #_win_xm call _wc_rresb -;src/main.c:293: wc_exit(WC_NEXT_FILE); +;src/main.c:325: wc_exit(WC_NEXT_FILE); ld a, #0x02 -;src/main.c:294: } +;src/main.c:326: } jp _wc_exit -;src/main.c:301: void copy_file_name() +___str_6: + .ascii "Playback error" + .db 0x00 +;src/main.c:333: void copy_file_name() ; --------------------------------- ; Function copy_file_name ; --------------------------------- _copy_file_name:: -;src/main.c:303: u8 *src = (u8*)p_file_name; +;src/main.c:335: u8 *src = (u8*)p_file_name; ld bc, (_p_file_name) -;src/main.c:306: while (src[i] && i < sizeof(file_name) - 1) +;src/main.c:338: while (src[i] && i < sizeof(file_name) - 1) ld e, #0x00 00102$: ld l, e ld h, #0x00 add hl, bc ld d, (hl) -;src/main.c:308: file_name[i] = src[i]; +;src/main.c:340: file_name[i] = src[i]; ld a, #<(_file_name) add a, e ld l, a ld a, #>(_file_name) adc a, #0x00 ld h, a -;src/main.c:306: while (src[i] && i < sizeof(file_name) - 1) +;src/main.c:338: while (src[i] && i < sizeof(file_name) - 1) ld a, d or a, a jr z, 00104$ ld a, e sub a, #0x20 jr nc, 00104$ -;src/main.c:308: file_name[i] = src[i]; +;src/main.c:340: file_name[i] = src[i]; ld (hl), d -;src/main.c:309: i++; +;src/main.c:341: i++; inc e jp 00102$ 00104$: -;src/main.c:311: file_name[i] = 0; +;src/main.c:343: file_name[i] = 0; ld (hl), #0x00 -;src/main.c:312: } +;src/main.c:344: } ret -;src/main.c:320: void xm_draw_static_labels() +;src/main.c:377: void xm_draw_static_labels() ; --------------------------------- ; Function xm_draw_static_labels ; --------------------------------- _xm_draw_static_labels:: -;src/main.c:322: wc_prsrw_attr(&win_xm, "File:", ROW_FILE, 1, 5, ATTR_CAPTION); - ld a, #0x45 - push af - inc sp +;src/main.c:379: wc_prsrw(&win_xm, "File:", ROW_FILE, 1, 5); ld hl, #0x0005 push hl - ld hl, #0x101 + ld hl, #0x102 push hl - ld de, #___str_9 + ld de, #___str_7 ld hl, #_win_xm - call _wc_prsrw_attr -;src/main.c:323: wc_prsrw(&win_xm, file_name, ROW_FILE, 7, strlen(file_name)); + call _wc_prsrw +;src/main.c:380: wc_prsrw_attr(&win_xm, file_name, ROW_FILE, 7, strlen(file_name), ATTR_VALUE); ld hl, #_file_name call _strlen + ld a, #0x71 + push af + inc sp push de - ld hl, #0x701 + ld hl, #0x702 push hl ld de, #_file_name ld hl, #_win_xm + call _wc_prsrw_attr +;src/main.c:381: wc_prsrw(&win_xm, "Status:", ROW_STATUS, 1, 7); + ld hl, #0x0007 + push hl + ld hl, #0x103 + push hl + ld de, #___str_8 + ld hl, #_win_xm call _wc_prsrw -;src/main.c:324: } +;src/main.c:384: wc_prsrw(&win_xm, HINT_TEXT, ROW_HINT, 2, sizeof(HINT_TEXT) - 1); + ld hl, #0x0024 + push hl + ld hl, #0x20a + push hl + ld de, #___str_9 + ld hl, #_win_xm + call _wc_prsrw +;src/main.c:385: } ret -___str_9: +___str_7: .ascii "File:" .db 0x00 -;src/main.c:333: void put_hex2(char *dst, u8 val) +___str_8: + .ascii "Status:" + .db 0x00 +___str_9: + .ascii "PgUp/PgDn:Track Esc:Stop Space:Leave" + .db 0x00 +;src/main.c:391: void xm_set_status_attr(const char *msg, u8 attr) +; --------------------------------- +; Function xm_set_status_attr +; --------------------------------- +_xm_set_status_attr:: + push ix + ld ix, #0 + add ix, sp + push af +;src/main.c:395: while (msg[i] && i < STATUS_VALUE_WIDTH) + ld e, #0x00 +00102$: + ld a, e + add a, l + ld c, a + ld a, #0x00 + adc a, h + ld b, a + ld a, (bc) + ld c, a + or a, a + jr z, 00119$ + ld a, e + sub a, #0x18 + jr nc, 00119$ +;src/main.c:397: status_buf[i] = msg[i]; + ld a, #<(_status_buf) + add a, e + ld -2 (ix), a + ld a, #>(_status_buf) + adc a, #0x00 + ld -1 (ix), a + push hl + ld l, -2 (ix) + ld h, -1 (ix) + ld (hl), c + pop hl +;src/main.c:398: i++; + inc e + jp 00102$ +;src/main.c:400: while (i < STATUS_VALUE_WIDTH) +00119$: +00105$: + ld a, e + sub a, #0x18 + jr nc, 00107$ +;src/main.c:401: status_buf[i++] = ' '; + ld hl, #_status_buf + ld d, #0x00 + add hl, de + inc e + ld (hl), #0x20 + jp 00105$ +00107$: +;src/main.c:403: wc_prsrw_attr(&win_xm, status_buf, ROW_STATUS, STATUS_VALUE_X, STATUS_VALUE_WIDTH, attr); + ld hl, #_win_xm + ld a, 4 (ix) + push af + inc sp + ld de, #0x0018 + push de + ld de, #0x903 + push de + ld de, #_status_buf + call _wc_prsrw_attr +;src/main.c:404: } + ld sp, ix + pop ix + pop hl + inc sp + jp (hl) +;src/main.c:406: void xm_set_status(const char *msg) +; --------------------------------- +; Function xm_set_status +; --------------------------------- +_xm_set_status:: +;src/main.c:408: xm_set_status_attr(msg, ATTR_VALUE); + ld a, #0x71 + push af + inc sp + call _xm_set_status_attr +;src/main.c:409: } + ret +;src/main.c:416: void xm_set_status_code(const char *msg, u8 code) +; --------------------------------- +; Function xm_set_status_code +; --------------------------------- +_xm_set_status_code:: + push ix + ld ix, #0 + add ix, sp + dec sp + ex de, hl +;src/main.c:421: while (msg[i] && i < sizeof(status_code_buf) - 7) + ld c, #0x00 +00102$: + ld l, c + ld h, #0x00 + add hl, de + ld b, (hl) +;src/main.c:423: status_code_buf[i] = msg[i]; + ld a, #<(_status_code_buf) + add a, c + ld l, a + ld a, #>(_status_code_buf) + adc a, #0x00 + ld h, a +;src/main.c:424: i++; + ld a, c + inc a + ld -1 (ix), a +;src/main.c:421: while (msg[i] && i < sizeof(status_code_buf) - 7) + ld a, b + or a, a + jr z, 00104$ + ld a, c + sub a, #0x11 + jr nc, 00104$ +;src/main.c:423: status_code_buf[i] = msg[i]; + ld (hl), b +;src/main.c:424: i++; + ld c, -1 (ix) + jp 00102$ +00104$: +;src/main.c:427: status_code_buf[i++] = ' '; + ld c, -1 (ix) + ld (hl), #0x20 +;src/main.c:428: status_code_buf[i++] = '('; + ld l, c + inc c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld (hl), #0x28 +;src/main.c:429: status_code_buf[i++] = '0'; + ld l, c + inc c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld (hl), #0x30 +;src/main.c:430: status_code_buf[i++] = 'x'; + ld l, c + inc c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld (hl), #0x78 +;src/main.c:431: status_code_buf[i++] = hexch[(code >> 4) & 0xF]; + ld l, c + inc c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld a, 4 (ix) + rlca + rlca + rlca + rlca + and a, #0xf + add a, #<(_xm_set_status_code_hexch_10000_129) + ld e, a + ld a, #0x00 + adc a, #>(_xm_set_status_code_hexch_10000_129) + ld d, a + ld a, (de) + ld (hl), a +;src/main.c:432: status_code_buf[i++] = hexch[code & 0xF]; + ld l, c + inc c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld a, 4 (ix) + and a, #0x0f + add a, #<(_xm_set_status_code_hexch_10000_129) + ld e, a + ld a, #0x00 + adc a, #>(_xm_set_status_code_hexch_10000_129) + ld d, a + ld a, (de) + ld (hl), a +;src/main.c:433: status_code_buf[i++] = ')'; + ld l, c + inc c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld (hl), #0x29 +;src/main.c:434: status_code_buf[i] = 0; + ld l, c + ld h, #0x00 + ld de, #_status_code_buf + add hl, de + ld (hl), #0x00 +;src/main.c:436: xm_set_status_attr(status_code_buf, ATTR_ERROR); + ld a, #0x72 + push af + inc sp + ld hl, #_status_code_buf + call _xm_set_status_attr +;src/main.c:437: } + inc sp + pop ix + pop hl + inc sp + jp (hl) +_xm_set_status_code_hexch_10000_129: + .ascii "0123456789ABCDEF" + .db 0x00 +;src/main.c:450: void put_hex2(char *dst, u8 val) ; --------------------------------- ; Function put_hex2 ; --------------------------------- @@ -1264,8 +1569,8 @@ _put_hex2:: ld ix, #0 add ix, sp ex de, hl -;src/main.c:336: dst[0] = hexch[(val >> 4) & 0xF]; - ld bc, #_put_hex2_hexch_10000_106+0 +;src/main.c:453: dst[0] = hexch[(val >> 4) & 0xF]; + ld bc, #_put_hex2_hexch_10000_132+0 ld a, 4 (ix) rlca rlca @@ -1277,7 +1582,7 @@ _put_hex2:: add hl, bc ld a, (hl) ld (de), a -;src/main.c:337: dst[1] = hexch[val & 0xF]; +;src/main.c:454: dst[1] = hexch[val & 0xF]; inc de ld a, 4 (ix) and a, #0x0f @@ -1286,15 +1591,15 @@ _put_hex2:: add hl, bc ld a, (hl) ld (de), a -;src/main.c:338: } +;src/main.c:455: } pop ix pop hl inc sp jp (hl) -_put_hex2_hexch_10000_106: +_put_hex2_hexch_10000_132: .ascii "0123456789ABCDEF" .db 0x00 -;src/main.c:340: void put_dec3(char *dst, u16 val) +;src/main.c:457: void put_dec3(char *dst, u16 val) ; --------------------------------- ; Function put_dec3 ; --------------------------------- @@ -1305,7 +1610,7 @@ _put_dec3:: push af ld c, l ld b, h -;src/main.c:342: dst[0] = '0' + (val / 100) % 10; +;src/main.c:459: dst[0] = '0' + (val / 100) % 10; pop hl push de push bc @@ -1320,7 +1625,7 @@ _put_dec3:: ld a, e add a, #0x30 ld (bc), a -;src/main.c:343: dst[1] = '0' + (val / 10) % 10; +;src/main.c:460: dst[1] = '0' + (val / 10) % 10; ld l, c ld h, b inc hl @@ -1338,7 +1643,7 @@ _put_dec3:: ld a, e add a, #0x30 ld (hl), a -;src/main.c:344: dst[2] = '0' + val % 10; +;src/main.c:461: dst[2] = '0' + val % 10; inc bc inc bc push bc @@ -1350,11 +1655,11 @@ _put_dec3:: ld a, e add a, #0x30 ld (bc), a -;src/main.c:345: } +;src/main.c:462: } ld sp, ix pop ix ret -;src/main.c:347: void put_time(char *dst, u32 sec) +;src/main.c:464: void put_time(char *dst, u32 sec) ; --------------------------------- ; Function put_time ; --------------------------------- @@ -1363,7 +1668,7 @@ _put_time:: ld ix, #0 add ix, sp push hl -;src/main.c:349: u8 m = (sec / 60) % 100; +;src/main.c:466: u8 m = (sec / 60) % 100; ld hl, #0x0000 push hl ld l, #0x3c @@ -1383,7 +1688,7 @@ _put_time:: pop af pop af ld c, e -;src/main.c:350: u8 s = sec % 60; +;src/main.c:467: u8 s = sec % 60; push bc ld hl, #0x0000 push hl @@ -1397,7 +1702,7 @@ _put_time:: pop af pop af pop bc -;src/main.c:352: dst[0] = '0' + (m / 10) % 10; +;src/main.c:469: dst[0] = '0' + (m / 10) % 10; ld d, c push de ld l, #0x0a @@ -1412,7 +1717,7 @@ _put_time:: pop hl push hl ld (hl), a -;src/main.c:353: dst[1] = '0' + m % 10; +;src/main.c:470: dst[1] = '0' + m % 10; pop bc push bc inc bc @@ -1426,13 +1731,13 @@ _put_time:: pop bc add a, #0x30 ld (bc), a -;src/main.c:354: dst[2] = ':'; +;src/main.c:471: dst[2] = ':'; pop hl push hl inc hl inc hl ld (hl), #0x3a -;src/main.c:355: dst[3] = '0' + (s / 10) % 10; +;src/main.c:472: dst[3] = '0' + (s / 10) % 10; pop bc push bc inc bc @@ -1451,7 +1756,7 @@ _put_time:: pop bc add a, #0x30 ld (bc), a -;src/main.c:356: dst[4] = '0' + s % 10; +;src/main.c:473: dst[4] = '0' + s % 10; ld a, -2 (ix) add a, #0x04 ld c, a @@ -1466,76 +1771,127 @@ _put_time:: pop bc add a, #0x30 ld (bc), a -;src/main.c:357: } +;src/main.c:474: } ld sp, ix pop ix pop hl pop af pop af jp (hl) -;src/main.c:359: void xm_draw_stats_labels() +;src/main.c:503: void xm_draw_stats_labels() ; --------------------------------- ; Function xm_draw_stats_labels ; --------------------------------- _xm_draw_stats_labels:: -;src/main.c:361: wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); +;src/main.c:507: wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); ld hl, #0x0009 push hl - ld hl, #0x103 - push hl - ld de, #___str_11 - ld hl, #_win_xm - call _wc_prsrw -;src/main.c:362: wc_prsrw(&win_xm, " Row:#", ROW_STATS, 12, 7); - ld hl, #0x0007 - push hl - ld hl, #0xc03 + ld hl, #0x104 push hl ld de, #___str_12 ld hl, #_win_xm call _wc_prsrw -;src/main.c:363: wc_prsrw(&win_xm, " BPM:", ROW_STATS, 21, 6); - ld hl, #0x0006 +;src/main.c:508: wc_prsrw(&win_xm, " Row:#", ROW_STATS, 12, 7); + ld hl, #0x0007 push hl - ld hl, #0x1503 + ld hl, #0xc04 push hl ld de, #___str_13 ld hl, #_win_xm call _wc_prsrw -;src/main.c:365: wc_prsrw(&win_xm, "Time:", ROW_TIME, 1, 5); - ld hl, #0x0005 +;src/main.c:509: wc_prsrw(&win_xm, " BPM:", ROW_STATS, 21, 6); + ld hl, #0x0006 push hl - ld hl, #0x105 + ld hl, #0x1504 push hl ld de, #___str_14 ld hl, #_win_xm call _wc_prsrw -;src/main.c:366: wc_prsrw(&win_xm, " / ", ROW_TIME, 12, 3); - ld hl, #0x0003 +;src/main.c:511: wc_prsrw(&win_xm, "Time:", ROW_TIME, 1, 5); + ld hl, #0x0005 push hl - ld hl, #0xc05 + ld hl, #0x106 push hl ld de, #___str_15 ld hl, #_win_xm call _wc_prsrw -;src/main.c:367: } +;src/main.c:512: wc_prsrw(&win_xm, " / ", ROW_TIME, 12, 3); + ld hl, #0x0003 + push hl + ld hl, #0xc06 + push hl + ld de, #___str_16 + ld hl, #_win_xm + call _wc_prsrw +;src/main.c:514: for (i = 0; i < BAR_WIDTH; i++) + ld de, #_barbuf+0 + ld c, #0x00 +00103$: +;src/main.c:515: barbuf[i] = ' '; + ld l, c + ld h, #0x00 + add hl, de + ld (hl), #0x20 +;src/main.c:514: for (i = 0; i < BAR_WIDTH; i++) + inc c + ld a, c + sub a, #0x20 + jr c, 00103$ +;src/main.c:516: wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); +;src/main.c:507: wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); +;src/main.c:516: wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); + ld hl, #0x0020 + push hl + ld hl, #0x408 + push hl + ld hl, #_win_xm + call _wc_prsrw +;src/main.c:518: bar_attr_ofs = (wc_gadrw(&win_xm, ROW_BAR, BAR_X) & 0x3FFF) | 0x0080; + ld hl, #0x408 + push hl + ld hl, #_win_xm + call _wc_gadrw + ld a, d + and a, #0x3f + ld d, a + set 7, e + ld (_bar_attr_ofs), de +;src/main.c:520: for (i = 0; i < BAR_WIDTH; i++) + ld c, #0x00 +00105$: +;src/main.c:521: *(volatile u8*)(0xC000 + bar_attr_ofs + i) = ATTR_BAR_EMPTY; + ld hl, (_bar_attr_ofs) + ld e, l + ld a, h + add a, #0xc0 + ld d, a + ld l, c + ld h, #0x00 + add hl, de + ld (hl), #0x07 +;src/main.c:520: for (i = 0; i < BAR_WIDTH; i++) + inc c + ld a, c + sub a, #0x20 + jr c, 00105$ +;src/main.c:522: } ret -___str_11: +___str_12: .ascii "Pattern:#" .db 0x00 -___str_12: +___str_13: .ascii " Row:#" .db 0x00 -___str_13: +___str_14: .ascii " BPM:" .db 0x00 -___str_14: +___str_15: .ascii "Time:" .db 0x00 -___str_15: +___str_16: .ascii " / " .db 0x00 -;src/main.c:386: void draw_progress_bar(u32 samples, u32 total) +;src/main.c:524: void draw_progress_bar(u32 samples, u32 total) ; --------------------------------- ; Function draw_progress_bar ; --------------------------------- @@ -1546,85 +1902,83 @@ _draw_progress_bar:: ld c, e ld b, d ex de, hl -;src/main.c:390: if (total) +;src/main.c:528: if (total) ld a, 7 (ix) or a, 6 (ix) or a, 5 (ix) or a, 4 (ix) jr z, 00104$ -;src/main.c:392: filled = (u16)(((u32)samples * BAR_WIDTH) / total); - push de - push bc - ld de, #0x0022 - ld hl, #0x0000 - call __mullong - pop af - pop af +;src/main.c:530: filled = (u16)(((u32)samples * BAR_WIDTH) / total); + ld l, c + ld h, b + ld a, #0x05 +00146$: + add hl, hl + rl e + rl d + dec a + jr nz, 00146$ ld c, 6 (ix) ld b, 7 (ix) push bc ld c, 4 (ix) ld b, 5 (ix) push bc + ex de, hl call __divulong pop af pop af -;src/main.c:393: if (filled > BAR_WIDTH) +;src/main.c:531: if (filled > BAR_WIDTH) ld c,e ld b,d - ld a, #0x22 + ld a, #0x20 cp a, e ld a, #0x00 sbc a, d - jr nc, 00121$ -;src/main.c:394: filled = BAR_WIDTH; - ld bc, #0x0022 - jp 00121$ + jr nc, 00120$ +;src/main.c:532: filled = BAR_WIDTH; + ld bc, #0x0020 + jp 00120$ 00104$: -;src/main.c:397: filled = 0; // total length unknown (measurement timed out) - show empty +;src/main.c:535: filled = 0; // total length unknown (measurement timed out) - show empty ld bc, #0x0000 -;src/main.c:399: for (i = 0; i < BAR_WIDTH; i++) -00121$: +;src/main.c:537: for (i = 0; i < BAR_WIDTH; i++) +00120$: ld de, #0x0000 00107$: -;src/main.c:400: barbuf[i] = (i < filled) ? BAR_FILLED_CH : BAR_EMPTY_CH; - ld hl, #_barbuf +;src/main.c:538: *(volatile u8*)(0xC000 + bar_attr_ofs + i) = (i < filled) ? ATTR_BAR_FILLED : ATTR_BAR_EMPTY; + ld hl, (_bar_attr_ofs) + ld a, h + add a, #0xc0 + ld h, a add hl, de ld a, e sub a, c ld a, d sbc a, b jr nc, 00111$ - ld a, #0x3d + ld a, #0x40 jp 00112$ 00111$: - ld a, #0x2d + ld a, #0x07 00112$: ld (hl), a -;src/main.c:399: for (i = 0; i < BAR_WIDTH; i++) +;src/main.c:537: for (i = 0; i < BAR_WIDTH; i++) inc de ld l, e ld h, d ld a, l - sub a, #0x22 + sub a, #0x20 ld a, h sbc a, #0x00 jr c, 00107$ -;src/main.c:402: wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); - ld hl, #0x0022 - push hl - ld hl, #0x106 - push hl - ld de, #_barbuf - ld hl, #_win_xm - call _wc_prsrw -;src/main.c:403: } +;src/main.c:539: } pop ix pop hl pop af pop af jp (hl) -;src/main.c:405: void xm_update_info() +;src/main.c:541: void xm_update_info() ; --------------------------------- ; Function xm_update_info ; --------------------------------- @@ -1635,55 +1989,53 @@ _xm_update_info:: ld hl, #-8 add hl, sp ld sp, hl -;src/main.c:411: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); +;src/main.c:547: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); ld a, (_xm_handle) ld l, a ld a, #0x0b call _esp_wr_reg8 -;src/main.c:412: esp_cmd(ESP_CMD_TRACK_GET_INFO); +;src/main.c:548: esp_cmd(ESP_CMD_TRACK_GET_INFO); ld a, #0xa8 call _esp_cmd -;src/main.c:413: esp_wait_busy(2000); - ld de, #0x07d0 - ld hl, #0x0000 +;src/main.c:549: esp_wait_busy(50); // 1s - a plain info read should be near-instant + ld hl, #0x0032 call _esp_wait_busy -;src/main.c:418: status = esp_rd_reg8(ESP_REG_TRACK_STATUS); +;src/main.c:554: status = esp_rd_reg8(ESP_REG_TRACK_STATUS); ld a, #0x28 call _esp_rd_reg8 ld -1 (ix), a -;src/main.c:419: if (last_track_status == TRACK_OBJ_ST_PLAYING && status == TRACK_OBJ_ST_STOPPED) +;src/main.c:555: if (last_track_status == TRACK_OBJ_ST_PLAYING && status == TRACK_OBJ_ST_STOPPED) ld a, (_last_track_status) sub a, #0x21 jr nz, 00102$ ld a, -1 (ix) sub a, #0x20 jr nz, 00102$ -;src/main.c:421: esp_cmd(ESP_CMD_KILL_OBJECTS); +;src/main.c:557: esp_cmd(ESP_CMD_KILL_OBJECTS); ld a, #0xe4 call _esp_cmd -;src/main.c:422: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 +;src/main.c:558: esp_wait_busy(100); + ld hl, #0x0064 call _esp_wait_busy -;src/main.c:423: wc_rresb(&win_xm); +;src/main.c:559: wc_rresb(&win_xm); ld hl, #_win_xm call _wc_rresb -;src/main.c:424: wc_exit(WC_NEXT_FILE); +;src/main.c:560: wc_exit(WC_NEXT_FILE); ld a, #0x02 call _wc_exit 00102$: -;src/main.c:426: last_track_status = status; +;src/main.c:562: last_track_status = status; ld a, -1 (ix) ld (#_last_track_status), a -;src/main.c:428: pattern = esp_rd_reg8(ESP_REG_TRACK_PATTERN); +;src/main.c:564: pattern = esp_rd_reg8(ESP_REG_TRACK_PATTERN); ld a, #0x2b call _esp_rd_reg8 ld -6 (ix), a -;src/main.c:429: row = esp_rd_reg8(ESP_REG_TRACK_ROW); +;src/main.c:565: row = esp_rd_reg8(ESP_REG_TRACK_ROW); ld a, #0x2c call _esp_rd_reg8 ld -5 (ix), a -;src/main.c:430: esp_rd_regs(ESP_REG_TRACK_BPM, &bpm, 2); +;src/main.c:566: esp_rd_regs(ESP_REG_TRACK_BPM, &bpm, 2); ld a, #0x02 push af inc sp @@ -1692,68 +2044,77 @@ _xm_update_info:: ex de, hl ld a, #0x31 call _esp_rd_regs -;src/main.c:431: samples = esp_rd_reg32(ESP_REG_TRACK_SAMPLES); +;src/main.c:567: samples = esp_rd_reg32(ESP_REG_TRACK_SAMPLES); ld a, #0x2d call _esp_rd_reg32 ld -4 (ix), e ld -3 (ix), d ld -2 (ix), l ld -1 (ix), h -;src/main.c:433: if (!total_samples) +;src/main.c:569: if (!total_samples) ld a, (_total_samples+3) ld iy, #_total_samples or a, 2 (iy) or a, 1 (iy) or a, 0 (iy) jr nz, 00105$ -;src/main.c:434: total_samples = esp_rd_reg32(ESP_REG_TRACK_TOTAL_SAMPLES); +;src/main.c:570: total_samples = esp_rd_reg32(ESP_REG_TRACK_TOTAL_SAMPLES); ld a, #0x36 call _esp_rd_reg32 ld (_total_samples), de ld (_total_samples + 2), hl 00105$: -;src/main.c:436: put_hex2(hexbuf, pattern); +;src/main.c:572: put_hex2(hexbuf, pattern); ld a, -6 (ix) push af inc sp ld hl, #_hexbuf call _put_hex2 -;src/main.c:437: wc_prsrw(&win_xm, hexbuf, ROW_STATS, 10, 2); +;src/main.c:573: wc_prsrw_attr(&win_xm, hexbuf, ROW_STATS, 10, 2, ATTR_VALUE); + ld a, #0x71 + push af + inc sp ld hl, #0x0002 push hl - ld hl, #0xa03 + ld hl, #0xa04 push hl ld de, #_hexbuf ld hl, #_win_xm - call _wc_prsrw -;src/main.c:439: put_hex2(hexbuf, row); + call _wc_prsrw_attr +;src/main.c:575: put_hex2(hexbuf, row); ld a, -5 (ix) push af inc sp ld hl, #_hexbuf call _put_hex2 -;src/main.c:440: wc_prsrw(&win_xm, hexbuf, ROW_STATS, 19, 2); +;src/main.c:576: wc_prsrw_attr(&win_xm, hexbuf, ROW_STATS, 19, 2, ATTR_VALUE); + ld a, #0x71 + push af + inc sp ld hl, #0x0002 push hl - ld hl, #0x1303 + ld hl, #0x1304 push hl ld de, #_hexbuf ld hl, #_win_xm - call _wc_prsrw -;src/main.c:442: put_dec3(decbuf, bpm); + call _wc_prsrw_attr +;src/main.c:578: put_dec3(decbuf, bpm); pop de push de ld hl, #_decbuf call _put_dec3 -;src/main.c:443: wc_prsrw(&win_xm, decbuf, ROW_STATS, 27, 3); +;src/main.c:579: wc_prsrw_attr(&win_xm, decbuf, ROW_STATS, 27, 3, ATTR_VALUE); + ld a, #0x71 + push af + inc sp ld hl, #0x0003 push hl - ld hl, #0x1b03 + ld hl, #0x1b04 push hl ld de, #_decbuf ld hl, #_win_xm - call _wc_prsrw -;src/main.c:445: put_time(timebuf, samples / 44100UL); + call _wc_prsrw_attr +;src/main.c:581: put_time(timebuf, samples / 44100UL); ld hl, #0x0000 push hl ld hl, #0xac44 @@ -1768,15 +2129,18 @@ _xm_update_info:: push de ld hl, #_timebuf call _put_time -;src/main.c:446: wc_prsrw(&win_xm, timebuf, ROW_TIME, 7, 5); +;src/main.c:582: wc_prsrw_attr(&win_xm, timebuf, ROW_TIME, 7, 5, ATTR_VALUE); + ld a, #0x71 + push af + inc sp ld hl, #0x0005 push hl - ld hl, #0x705 + ld hl, #0x706 push hl ld de, #_timebuf ld hl, #_win_xm - call _wc_prsrw -;src/main.c:448: put_time(timebuf, total_samples / 44100UL); + call _wc_prsrw_attr +;src/main.c:584: put_time(timebuf, total_samples / 44100UL); ld hl, #0x0000 push hl ld hl, #0xac44 @@ -1789,15 +2153,18 @@ _xm_update_info:: push de ld hl, #_timebuf call _put_time -;src/main.c:449: wc_prsrw(&win_xm, timebuf, ROW_TIME, 15, 5); +;src/main.c:585: wc_prsrw_attr(&win_xm, timebuf, ROW_TIME, 15, 5, ATTR_VALUE); + ld a, #0x71 + push af + inc sp ld hl, #0x0005 push hl - ld hl, #0xf05 + ld hl, #0xf06 push hl ld de, #_timebuf ld hl, #_win_xm - call _wc_prsrw -;src/main.c:451: draw_progress_bar(samples, total_samples); + call _wc_prsrw_attr +;src/main.c:587: draw_progress_bar(samples, total_samples); ld hl, (_total_samples + 2) push hl ld hl, (_total_samples) @@ -1807,184 +2174,150 @@ _xm_update_info:: ld l, -2 (ix) ld h, -1 (ix) call _draw_progress_bar -;src/main.c:453: } +;src/main.c:589: } ld sp, ix pop ix ret -;src/main.c:455: void main_start() +;src/main.c:591: void main_start() ; --------------------------------- ; Function main_start ; --------------------------------- _main_start:: dec sp -;src/main.c:463: wc_set_freq_14mhz(); - call _wc_set_freq_14mhz -;src/main.c:465: copy_file_name(); +;src/main.c:595: copy_file_name(); call _copy_file_name -;src/main.c:467: if (state_esp == 0xFF) +;src/main.c:607: wc_prwow(&win_xm); + ld hl, #_win_xm + call _wc_prwow +;src/main.c:608: xm_draw_static_labels(); + call _xm_draw_static_labels +;src/main.c:609: xm_set_status("Loading, please wait..."); + ld hl, #___str_17 + call _xm_set_status +;src/main.c:611: if (state_esp == 0xFF) ld a, (_state_esp) inc a jr nz, 00102$ -;src/main.c:468: state_esp = esp_init() ? 1 : 2; +;src/main.c:612: state_esp = esp_init() ? 1 : 2; call _esp_init or a, a ld a, #0x01 - jr nz, 00124$ + jr nz, 00126$ ld a, #0x02 -00124$: +00126$: ld (#_state_esp), a 00102$: -;src/main.c:470: if (state_esp != 1) +;src/main.c:614: if (state_esp != 1) ld a, (_state_esp) dec a jr z, 00104$ -;src/main.c:472: error_esp(); +;src/main.c:616: error_esp(); inc sp jp _error_esp -;src/main.c:473: return; - jp 00121$ +;src/main.c:617: return; + jp 00123$ 00104$: -;src/main.c:476: total_samples = 0; +;src/main.c:620: total_samples = 0; xor a, a ld (_total_samples+0), a ld (_total_samples+1), a ld (_total_samples+2), a ld (_total_samples+3), a -;src/main.c:478: if (!play_xm()) +;src/main.c:622: if (!play_xm()) call _play_xm or a, a jr nz, 00109$ -;src/main.c:480: if (last_esp_status == ESP_ERR_OUT_OF_MEMORY) +;src/main.c:624: if (last_esp_status == ESP_ERR_OUT_OF_MEMORY) ld a, (_last_esp_status) sub a, #0x99 jr nz, 00106$ -;src/main.c:481: error_oom(); +;src/main.c:625: error_oom(); inc sp jp _error_oom - jp 00121$ + jp 00123$ 00106$: -;src/main.c:483: error_playback(); +;src/main.c:627: error_playback(); inc sp -;src/main.c:484: return; +;src/main.c:628: return; jp _error_playback 00109$: -;src/main.c:490: wc_prwow(&win_xm); - ld hl, #_win_xm - call _wc_prwow -;src/main.c:491: xm_draw_static_labels(); - call _xm_draw_static_labels -;src/main.c:492: xm_draw_stats_labels(); +;src/main.c:631: xm_set_status("Playing"); + ld hl, #___str_18 + call _xm_set_status +;src/main.c:632: xm_draw_stats_labels(); call _xm_draw_stats_labels -;src/main.c:493: last_track_status = TRACK_OBJ_ST_PLAYING; +;src/main.c:633: last_track_status = TRACK_OBJ_ST_PLAYING; ld hl, #_last_track_status ld (hl), #0x21 -;src/main.c:494: xm_update_info(); +;src/main.c:634: xm_update_info(); call _xm_update_info -;src/main.c:496: frame_ctr = 0; +;src/main.c:636: frame_ctr = 0; ld iy, #0 add iy, sp ld 0 (iy), #0x00 -;src/main.c:499: while (1) -00119$: -;src/main.c:503: __endasm; +;src/main.c:639: while (1) +00121$: +;src/main.c:643: __endasm; halt -;src/main.c:505: if (++frame_ctr >= 10) // ~5 updates/sec at 50Hz +;src/main.c:645: if (++frame_ctr >= 10) // ~5 updates/sec at 50Hz ld iy, #0 add iy, sp inc 0 (iy) ld a, 0 (iy) sub a, #0x0a jr c, 00111$ -;src/main.c:507: frame_ctr = 0; +;src/main.c:647: frame_ctr = 0; ld 0 (iy), #0x00 -;src/main.c:508: xm_update_info(); +;src/main.c:648: xm_update_info(); call _xm_update_info 00111$: -;src/main.c:511: if (wc_key_pgdn()) // PgDn - unload and go to next file +;src/main.c:651: if (wc_key_pgdn()) // PgDn - unload and go to next file call _wc_key_pgdn or a, a jr z, 00113$ -;src/main.c:513: esp_cmd(ESP_CMD_TRACK_STOP); - ld a, #0xa2 - call _esp_cmd -;src/main.c:514: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 - call _esp_wait_busy -;src/main.c:515: esp_cmd(ESP_CMD_KILL_OBJECTS); - ld a, #0xe4 - call _esp_cmd -;src/main.c:516: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 - call _esp_wait_busy -;src/main.c:517: wc_rresb(&win_xm); - ld hl, #_win_xm - call _wc_rresb -;src/main.c:518: wc_exit(WC_NEXT_FILE); +;src/main.c:652: unload_and_exit(WC_NEXT_FILE); ld a, #0x02 - call _wc_exit + call _unload_and_exit 00113$: -;src/main.c:521: if (wc_key_pgup()) // PgUp - unload and go to previous file +;src/main.c:654: if (wc_key_pgup()) // PgUp - unload and go to previous file call _wc_key_pgup or a, a jr z, 00115$ -;src/main.c:523: esp_cmd(ESP_CMD_TRACK_STOP); - ld a, #0xa2 - call _esp_cmd -;src/main.c:524: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 - call _esp_wait_busy -;src/main.c:525: esp_cmd(ESP_CMD_KILL_OBJECTS); - ld a, #0xe4 - call _esp_cmd -;src/main.c:526: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 - call _esp_wait_busy -;src/main.c:527: wc_rresb(&win_xm); - ld hl, #_win_xm - call _wc_rresb -;src/main.c:528: wc_exit(WC_PREV_FILE); +;src/main.c:655: unload_and_exit(WC_PREV_FILE); ld a, #0x04 - call _wc_exit + call _unload_and_exit 00115$: -;src/main.c:531: if (wc_key_esc()) // Esc - unload and exit +;src/main.c:657: if (wc_key_esc()) // Esc - unload and exit call _wc_key_esc or a, a - jr z, 00119$ -;src/main.c:533: esp_cmd(ESP_CMD_TRACK_STOP); - ld a, #0xa2 - call _esp_cmd -;src/main.c:534: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 - call _esp_wait_busy -;src/main.c:535: esp_cmd(ESP_CMD_KILL_OBJECTS); - ld a, #0xe4 - call _esp_cmd -;src/main.c:536: esp_wait_busy(10000); - ld de, #0x2710 - ld hl, #0x0000 - call _esp_wait_busy -;src/main.c:537: wc_rresb(&win_xm); - ld hl, #_win_xm - call _wc_rresb -;src/main.c:538: wc_exit(WC_EXIT); + jr z, 00117$ +;src/main.c:658: unload_and_exit(WC_EXIT); xor a, a - call _wc_exit - jp 00119$ -00121$: -;src/main.c:541: } + call _unload_and_exit +00117$: +;src/main.c:660: if (wc_key_space()) // Space - leave the track playing, just exit + call _wc_key_space + or a, a + jr z, 00121$ +;src/main.c:661: leave_playing_and_exit(); + call _leave_playing_and_exit + jp 00121$ +00123$: +;src/main.c:663: } inc sp ret -;src/main.c:544: void main() +___str_17: + .ascii "Loading, please wait..." + .db 0x00 +___str_18: + .ascii "Playing" + .db 0x00 +;src/main.c:666: void main() ; --------------------------------- ; Function main ; --------------------------------- _main:: -;src/main.c:554: __endasm; +;src/main.c:676: __endasm; ld (_ret_sp), sp ld (_call_type), a ld (_p_file_name), bc @@ -1992,24 +2325,24 @@ _main:: ld (_file_ext), a ld (_filesize), hl ld (_filesize + 2), de -;src/main.c:556: switch (call_type) +;src/main.c:678: switch (call_type) ld a, (_call_type+0) or a, a jp z, _main_start ld a, (_call_type) sub a, #0x03 jp z, _about -;src/main.c:558: case WC_CALL_EXT: -;src/main.c:559: main_start(); -;src/main.c:560: break; -;src/main.c:562: case WC_CALL_MENU: -;src/main.c:563: about(); -;src/main.c:564: break; -;src/main.c:566: default: -;src/main.c:567: wc_exit(WC_EXIT); +;src/main.c:680: case WC_CALL_EXT: +;src/main.c:681: main_start(); +;src/main.c:682: break; +;src/main.c:684: case WC_CALL_MENU: +;src/main.c:685: about(); +;src/main.c:686: break; +;src/main.c:688: default: +;src/main.c:689: wc_exit(WC_EXIT); xor a, a -;src/main.c:568: } -;src/main.c:569: } +;src/main.c:690: } +;src/main.c:691: } jp _wc_exit .area _CODE .area _INITIALIZER diff --git a/obj/out.bin b/obj/out.bin index 2752770..0195211 100644 Binary files a/obj/out.bin and b/obj/out.bin differ diff --git a/obj/out.hex b/obj/out.hex index 75338e6..0221df7 100644 --- a/obj/out.hex +++ b/obj/out.hex @@ -1,119 +1,127 @@ -:20800300ED7B00B8C906000E023E0EC306604F3E13D3773E01D357AFD357DB5779D357AF39 -:20802300D3573E03D377C94F3E13D3773E02D35779D357DB57DB57DB574F3E03D37779C916 -:20804300DDE5DD210000DD39F5F54F3E13D3773E02D35779D357DB57DB57DB574FDB5757F8 -:2080630059DB57DD77FCAFDD77FDDD77FEDD77FFDD7EFCDD77FEAFDD77FFDD77FCDD77FD31 -:20808300DD6EFEDB57DD77FCAFDD77FDDD77FEDD77FFDD7EFCDD77FFAFDD77FCDD77FDDD96 -:2080A30077FEDD66FF3E03D377DDF9DDE1C94F3E13D3773E02D35779D357DB57DB57FD21A5 -:2080C3000200FD39FD4E00790DB72807DB571213C3CA803E03D377E133E9474D3E13D37793 -:2080E3003E01D35778D357DB5779D3573E03D377C94F3E13D3773E01D35779D357DB57FD24 -:20810300210200FD39FD7E00D357FD7E01D357FD7E02D357FD7E03D3573E03D377E1F1F11B -:20812300E93E13D3773E07D357DB573E03D377C97D01AF1AED797C01AF1BED79FD21020049 -:20814300FD39FD7E0001AF1CED79FD7E01FD4E02FD23CB39CB1F3D01AF26ED79FD7E023D2F -:2081630001AF28ED793E13D3773E03D357DB57DB573E8201AF27ED793E27DBAF0738F93EF2 -:2081830003D377CD24811160EA210000CDE181E1F1F133E93E13D3773E08D357DB573E0315 -:2081A300D377C9DDE5DD210000DD394FDD5E04DD5605DD6E06DD66077BC6FF5F7ACEFF5735 -:2081C3007DCEFF6F7CCEFF67B5B2B3280EE5C5D53E01CD2A80D1C1E19120DDDDE1C97BC6E5 -:2081E300FF5F7ACEFF577DCEFF6F7CCEFF67B5B2B3C8E5D53E01CD2A80D1E1FE0228DFC943 -:20820300E5D53E03CDF480FD210200FD39FD6E003E02CDDD803EE0CD118011204E210000D8 -:20822300CDE1813E0BCD2A805F1600E133E9AFCD1180CD9781CD24813E01C90100180A202B -:20824300052F00000000009882A282A3820100FFFF20052F00000000009882A282B98201B7 -:2082630000FFFF20052F00000000009882A282D9828100190A280B4F0000000000F782A2CF -:20828300820C830100160A24054F00000000001A83A28223830E204572726F722120000051 -:2082A3000E0C014E6F20455350333220646574656374656421000E0C014F7574206F66208B -:2082C3006D656D6F7279202866696C6520746F6F2062696729000E0C01506C617962616356 -:2082E3006B206572726F7220286261642066696C653F29000E20584D2F584D5A2F53334D2C -:2083030020506C6179657220000E0C01506C6179696E672E2E2E000E2041626F75742000EB -:208323000E0C01584D20506C617965722076312E3000DDE5DD210000DD3921ECFF39F93E76 -:20834300A2CD1180111027210000CDE1813EE4CD1180111027210000CDE1813A06B83D280D -:208363000A3A06B8D6022808C378833E08C37A833E0CC37A833E05F533ED5B02B82A04B8CF -:20838300CD03822130B8733E01CD2A803208B83A08B83D2804AFC36385210C0039EB210233 -:2083A300B8010400EDB0AFDD77FCDD77FDDD77FEDD77FFDD7EFBDDB6FADDB6F9DDB6F8CAA7 -:2083C300D284DD7EF9D610DD7EFADE00DD7EFBDE00301121000039EB210C0039010400EDC5 -:2083E300B0C3F683DD36EC00DD36ED10AFDD77EEDD77EF21050039EB21000039010400EDB5 -:20840300B0DD7EF1C6FFDD7EF2CE01473E00CE005F3E00CE005748435ACB3BCB18CB19DDD8 -:2084230071F779F5332100A8CD3D8B210000E5DD6EF1DD66F2E53E03CDF480DD6EFEDD6668 -:20844300FFE5DD6EFCDD66FDE53E07CDF4803EE1CD1180210000E521D007E53E03CDA681AE -:20846300F1F1DD7EF7DD77F5DD36F6003A0260DD77F7DD6EF52600E5210002E5DD7EF7F5F2 -:20848300332100A8CD3381DD5EF1DD56F2DD6EFCDD66FD19DD75FCDD74FDDD7EFEDD8EF318 -:2084A300DD77FE3003DD34FFDD7EF8DD96F1DD77F8DD7EF9DD9EF2DD77F9DD7EFADD9EF350 -:2084C300DD77FADD7EFBDD9EF4DD77FBC3B6833A06B83D203D3A30B86F3E0BCDDD802E0572 -:2084E3003E02CDDD802A04B8E52A02B8E53E03CDF4803EF2CD1180111027210000CDE181D3 -:208503003E01CD2A803208B83A08B83D2804AFC363853EA0CD1180114042210F00CDE181C5 -:208523003E01CD2A803208B83A08B83D2804AFC363853A30B86F3E0BCDDD802E013E3ACD5B -:20854300DD803EA6CD1180111027210000CDE1813EA1CD1180111027210000CDE1813E01CD -:20856300DDF9DDE1C976CD0B8CB728F9C94F790DB7C876C37185218682CD948BCD688521AD -:208583008682CDF28BAFC30380213E82CD948BCD6885213E82CDF28BAFC30380215082CD2A -:2085A300948B3E32CD7085215082CDF28B3E02C30380216282CD948B3E32CD70852162827C -:2085C300CDF28B3E02C30380ED4B09B81E006B260009563E0B836F3EB8CE00677AB7280AF8 -:2085E3007BD6203005721CC3D1853600C93E45F533210500E5210101E5111A86217482CDD9 -:20860300AB8B210BB8CDFF8BD5210107E5110BB8217482CD5E8BC946696C653A00DDE5DD40 -:20862300210000DD39EB014C86DD7E0407070707E60F6F2600097E1213DD7E04E60F6F26A8 -:2086430000097E12DDE1E133E93031323334353637383941424344454600DDE5DD21000061 -:20866300DD39F54D44E1D5C5116400DD6EFEDD66FFCD0E8BEB110A00CD598BC17BC630028F -:20868300696023E5C5110A00DD6EFEDD66FFCD0E8BEB110A00CD598BC1E17BC630770303EE -:2086A300C5110A00DD6EFEDD66FFCD598BC17BC63002DDF9DDE1C9DDE5DD210000DD39E54F -:2086C300210000E52E3CE5DD5E04DD5605DD6E06DD6607CDE6B8F1F1010000C50E64C5CD19 -:2086E3005FB8F1F14BC5210000E52E3CE5DD5E04DD5605DD6E06DD6607CD5FB8F1F1C1512F -:20870300D52E0A7ACD098B7B2E0ACD528B7BD1C630E1E577C1C503C5D52E0A7ACD528B7B98 -:20872300D1C1C63002E1E52323363AC1C5030303C5D52E0A7BCD098B7B2E0ACD528B7BD14A -:20874300C1C63002DD7EFEC6044FDD7EFFCE0047C52E0A7BCD528B7BC1C63002DDF9DDE192 -:20876300E1F1F1E9210900E5210301E511BD87217482CD5E8B210700E521030CE511C7878E -:20878300217482CD5E8B210600E5210315E511CF87217482CD5E8B210500E5210501E51183 -:2087A300D687217482CD5E8B210300E521050CE511DC87217482CD5E8BC9506174746572F2 -:2087C3006E3A23002020526F773A2300202042504D3A0054696D653A00202F2000DDE5DDC6 -:2087E300210000DD394B42EBDD7E07DDB606DDB605DDB6042830D5C5112200210000CD6921 -:20880300B9F1F1DD4E06DD4607C5DD4E04DD4605C5CDE6B8F1F14B423E22BB3E009A300978 -:20882300012200C32C88010000110000213CB8197B917A9830053E3DC340883E2D77136BA2 -:20884300627DD6227CDE0038E3212200E5210601E5113CB8217482CD5E8BDDE1E1F1F1E958 -:20886300DDE5DD210000DD3921F8FF39F93A30B86F3E0BCDDD803EA8CD118011D007210084 -:2088830000CDE1813E28CD2A80DD77FF3A31B8D6212020DD7EFFD62020193EE4CD11801102 -:2088A3001027210000CDE181217482CDF28B3E02CD0380DD7EFF3231B83E2BCD2A80DD7794 -:2088C300FA3E2CCD2A80DD77FB3E02F53321010039EB3E31CDB1803E2DCD4380DD73FCDD2C -:2088E30072FDDD75FEDD74FF3A2FB8FD212CB8FDB602FDB601FDB600200C3E36CD4380ED0A -:20890300532CB8222EB8DD7EFAF5332132B8CD2086210200E521030AE51132B8217482CD20 -:208923005E8BDD7EFBF5332132B8CD2086210200E5210313E51132B8217482CD5E8BD1D5BD -:208943002134B8CD5D86210300E521031BE51134B8217482CD5E8B210000E52144ACE5DD87 -:208963005EFCDD56FDDD6EFEDD66FFCDE6B8F1E3D52137B8CDBA86210500E5210507E51180 -:2089830037B8217482CD5E8B210000E52144ACE5ED5B2CB82A2EB8CDE6B8F1E3D52137B8BC -:2089A300CDBA86210500E521050FE51137B8217482CD5E8B2A2EB8E52A2CB8E5DD5EFCDDB9 -:2089C30056FDDD6EFEDD66FFCDE087DDF9DDE1C93BCD0880CDCB853A5EB83C200DCD31823F -:2089E300B73E0120023E02325EB83A5EB83D280733C38C85C3DE8AAF322CB8322DB8322EAA -:208A0300B8322FB8CD3583B720123A08B8D699200733C39F85C3DE8A33C3B585217482CD2B -:208A2300948BCDF085CD67872131B83621CD6388FD210000FD39FD36000076FD210000FDE6 -:208A430039FD3400FD7E00D60A3807FD360000CD6388CDA18BB728273EA2CD11801110279F -:208A6300210000CDE1813EE4CD1180111027210000CDE181217482CDF28B3E02CD0380CDCD -:208A8300158CB728273EA2CD1180111027210000CDE1813EE4CD1180111027210000CDE1BF -:208AA30081217482CDF28B3E04CD0380CD0B8CB728883EA2CD1180111027210000CDE1819E -:208AC3003EE4CD1180111027210000CDE181217482CDF28BAFCD0380C33D8A33C9ED730035 -:208AE300B83207B8ED4309B8083206B82202B8ED5304B83A07B8B7CAD3893A07B8D603CA97 -:068B03007985AFC3038079 -:01BA4C00FFFA -:03800000C3E08A50 -:208B09005D6F2600547BE680B220110610ED6A17933001833FED6A10F65FEBC906097D6CD0 -:208B29002600CB1DED6AED523001193F1710F5CB10505FC9DDE5DD210000DD39DD46043E55 -:208B490030CD0660DDE1E133E95D6FCD0B8BEBC9CD0E8BEBC9DDE5E5D5DD210000DD39DD84 -:208B6900460BDD4E0ADD5608DD5E09DD6E00DD6601D9DD6E02DD6603E5DDE1D93E03CD065C -:188B890060D1E1DDE1E133333333E9DDE5E5DDE13E01CD0660DDE1C910 -:20B85F00DDE5DD210000DD39010000DD7E07073838DDCB0426DDCB0516DDCB0616DDCB0711 -:20B87F00167BDD96047ADD9E057DDD9E067CDD9E073012DDCB073EDDCB061EDDCB051EDD08 -:20B89F00CB041E1804044818C27BDD96047ADD9E057DDD9E067CDD9E0738147BDD96045FD5 -:20B8BF007ADD9E05577DDD9E066F7CDD9E0767DDCB073EDDCB061EDDCB051EDDCB041E797F -:20B8DF000DB720C5DDE1C9DDE5DD210000DD39F5F5AFDD77FCDD77FDDD77FEDD77FF06203E -:20B8FF007C07E6014FCB23CB12ED6ADDCBFC26DDCBFD16DDCBFE16DDCBFF16CB412804DD3B -:20B91F00CBFCC6DD7EFCDD9604DD7EFDDD9E05DD7EFEDD9E06DD7EFFDD9E073826DD7EFC6A -:20B93F00DD9604DD77FCDD7EFDDD9E05DD77FDDD7EFEDD9E06DD77FEDD7EFFDD9E07DD779C -:0AB95F00FFCBC3109BDDF9DDE1C949 -:208BA100DDE53E1ACD0660DDE1C9DDE5E5D5DD210000DD39DD460BDD4E0ADD5608DD5E096E -:208BC100DD6E00DD6601D9DD6E02DD6603DD7E0CF5E5DDE1D93E03CD0660F108D9E5DDE1D8 -:208BE100D93E04CD0660D1E1DDE1E13333333333E9DDE5E5DDE13E02CD0660DDE1C9AF4798 -:1E8C01004FEDB121FFFFED42EBC9DDE53E17CD0660DDE1C9DDE53E19CD0660DDE1C9C2 -:20B96900DDE5DD210000DD39F5F5F5DD73FCDD72FDDD75FEDD74FF4D44DD5E04DD56056960 -:20B9890060CD1F8C4B42DD71FEDD70FFDD7E06DD77FADD7E07DD77FBE1D1D5E5C5DD6EFACB -:20B9A900DD66FBCD1F8CEBC1094D44DD71FEDD70FFDD5EFDDD6605C52E00550608293001BA -:20B9C9001910FAC109DD75FEDD74FFDD5E04DD66FD2E005506082930011910FA4D44DD5E78 -:20B9E900FCDD6605C52E005506082930011910FAC1DD7505DD740609DD7505DD7406AFED65 -:20BA0900423E0017DD7707DD5EFCDD66042E005506082930011910FADD75FCDD74FDDD36F0 -:20BA29000400DD7EFCDD86045FDD7EFDDD8E0557DD7EFEDD8E066FDD7EFFDD8E0767DDF97B -:03BA4900DDE1C973 -:178C1F004D44AF6FB00610200406087929CB111730011910F7EBC9FD +:20800300ED7B00B8C94F3E13D3773E01D357AFD357DB5779D357AFD3573E03D377C94F3EB9 +:2080230013D3773E02D35779D357DB57DB57DB574F3E03D37779C9DDE5DD210000DD39F556 +:20804300F54F3E13D3773E02D35779D357DB57DB57DB574FDB575759DB57DD77FCAFDD77E5 +:20806300FDDD77FEDD77FFDD7EFCDD77FEAFDD77FFDD77FCDD77FDDD6EFEDB57DD77FCAF95 +:20808300DD77FDDD77FEDD77FFDD7EFCDD77FFAFDD77FCDD77FDDD77FEDD66FF3E03D377CE +:2080A300DDF9DDE1C94F3E13D3773E02D35779D357DB57DB57FD210200FD39FD4E00790DDE +:2080C300B72807DB571213C3C1803E03D377E133E9474D3E13D3773E01D35778D357DB5768 +:2080E30079D3573E03D377C94F3E13D3773E01D35779D357DB57FD210200FD39FD7E00D3BA +:2081030057FD7E01D357FD7E02D357FD7E03D3573E03D377E1F1F1E93E13D3773E07D357CF +:20812300DB573E03D377C97D01AF1AED797C01AF1BED79FD210200FD39FD7E0001AF1CEDD2 +:2081430079FD7E01FD4E02FD23CB39CB1F3D01AF26ED79FD7E023D01AF28ED793E13D377C0 +:208163003E03D357DB57DB573E8201AF27ED793E27DBAF0738F93E03D377CD1B8121640090 +:20818300CDE881E1F1F133E93E13D3773E08D357DB573E03D377C9DDE5DD210000DD39213F +:2081A300FBFF39F9DD77FFDD73FDDD72FE2109607EDD77FB237EDD77FC2A09607DDD96FBDD +:2081C3004F7CDD9EFC4779DD96FD78DD9EFE300F3E01CD2180DD96FF20DF3E01C3E381AFC7 +:2081E300DDF9DDE1C9DDE5DD210000DD39F5F5DD75FEDD74FF2109607EDD77FC237EDD7772 +:20820300FD2A09607DDD96FC4F7CDD9EFD4779DD96FE78DD9EFF300E3E01CD2180FE022866 +:20822300E03E01C32A82AFDDF9DDE1C9E5D53E03CDEB80FD210200FD39FD6E003E02CDD4CC +:20824300803EE0CD0880216400CDE8813E0BCD21805F1600E133E9AFCD0880CD8B81CD1B7F +:20826300813E01C98100190A280C7000000000008B82A582A5820100160A24054F00000036 +:208283000000A682A582AF820E20584D2F584D5A2F53334D20506C617965722076302E31A6 +:2082A3002000000E2041626F757420000E0C01584D20506C617965722076302E3100DDE51E +:2082C300DD210000DD3921ECFF39F93EA2CD0880216400CDE8813EE4CD0880216400CDE8A8 +:2082E300813A06B83D280A3A06B8D6022808C3FE823E08C300833E0CC300833E05F533EDDC +:208303005B02B82A04B8CD2F822130B8733E01CD21803208B83A08B83D2804AFC3E8842164 +:208323000C0039EB2102B8010400EDB0AFDD77FCDD77FDDD77FEDD77FFDD7EFBDDB6FADDD8 +:20834300B6F9DDB6F8CA5184DD7EF9D610DD7EFADE00DD7EFBDE00301121000039EB210CED +:208363000039010400EDB0C37C83DD36EC00DD36ED10AFDD77EEDD77EF21050039EB2100AF +:208383000039010400EDB0DD7EF1C6FFDD7EF2CE01473E00CE005F3E00CE005748435ACB0D +:2083A3003BCB18CB19DD71F779F5332100A8CD0E8D210000E5DD6EF1DD66F2E53E03CDEB4C +:2083C30080DD6EFEDD66FFE5DD6EFCDD66FDE53E07CDEB803EE1CD08801164003E03CD9A30 +:2083E30081DD7EF7DD77F5DD36F6003A0260DD77F7DD6EF52600E5210002E5DD7EF7F533A1 +:208403002100A8CD2A81DD5EF1DD56F2DD6EFCDD66FD19DD75FCDD74FDDD7EFEDD8EF3DDF7 +:2084230077FE3003DD34FFDD7EF8DD96F1DD77F8DD7EF9DD9EF2DD77F9DD7EFADD9EF3DDD0 +:2084430077FADD7EFBDD9EF4DD77FBC33C833A06B83D203A3A30B86F3E0BCDD4802E053E17 +:2084630002CDD4802A04B8E52A02B8E53E03CDEB803EF2CD088021FA00CDE8813E01CD21C6 +:20848300803208B83A08B83D2804AFC3E8843EA0CD0880219001CDE8813E01CD2180320824 +:2084A300B83A08B83D2804AFC3E8843A30B86F3E0BCDD4802E013E3ACDD4803EA6CD0880C4 +:2084C300216400CDE8813EA1CD0880216400CDE8813E01CD21803208B83A08B83D2804AF3E +:2084E300C3E8843E01DDF9DDE1C976CD108EB728F9C94F790DB7C876C3F684217982CD65D7 +:208503008DCDED84217982CDF78DAFC303803BFD210000FD39FD77003EA2CD08802164006E +:20852300CDE8813EE4CD0880216400CDE881216782CDF78D210000397E33C3038033C92107 +:208543006782CDF78DAFC3038076CD818DB728053E02CD1185CD1A8EB728053E04CD118513 +:20856300CD108EB728E3AFCD1185C34C853A8EB8F533218885CD1987CDED84216782CDF7D6 +:208583008DAFC303804E6F20455350333220666F756E64003E01CD728DFE023E01C8AFC966 +:2085A3003A08B8F53321C785CD1987CD9785B72803CD4C853E32CDF584216782CDF78D3E04 +:2085C30002C3038046696C6520746F6F206C61726765003A08B8F53321FA85CD1987CD97A0 +:2085E30085B72803CD4C853E32CDF584216782CDF78D3E02C30380506C61796261636B2095 +:208603006572726F7200ED4B09B81E006B260009563E0B836F3EB8CE00677AB7280A7BD60C +:20862300203005721CC30F863600C9210500E5210201E5117A86216782CD2F8D210BB8CD94 +:20864300048E3E71F533D5210207E5110BB8216782CDB08D210700E5210301E51180862193 +:208663006782CD2F8D212400E5210A02E5118886216782CD2F8DC946696C653A00537461EC +:208683007475733A00506755702F5067446E3A547261636B204573633A53746F7020537000 +:2086A3006163653A4C6561766500DDE5DD210000DD39F51E007B854F3E008C470A4FB728E6 +:2086C3001F7BD618301A3E3283DD77FE3EB8CE00DD77FFE5DD6EFEDD66FF71E11CC3B8868A +:2086E3007BD618300C2132B81600191C3620C3E386216782DD7E04F533111800D51103094E +:20870300D51132B8CDB08DDDF9DDE1E133E93E71F533CDAD86C9DDE5DD210000DD393BEB4F +:208723000E0069260019463E4A816F3EB8CE0067793CDD77FF78B7280C79D611300770DD48 +:208743004EFFC32587DD4EFF3620690C2600114AB8193628690C2600114AB8193630690C13 +:208763002600114AB8193678690C2600114AB819DD7E0407070707E60FC6C05F3E00CE8747 +:20878300571A77690C2600114AB819DD7E04E60FC6C05F3E00CE87571A77690C2600114A7D +:2087A300B8193629692600114AB81936003E72F533214AB8CDAD8633DDE1E133E930313219 +:2087C3003334353637383941424344454600DDE5DD210000DD39EB01FD87DD7E04070707CD +:2087E30007E60F6F2600097E1213DD7E04E60F6F2600097E12DDE1E133E9303132333435CD +:208803003637383941424344454600DDE5DD210000DD39F54D44E1D5C5116400DD6EFEDD70 +:2088230066FFCDD58CEB110A00CD2A8DC17BC63002696023E5C5110A00DD6EFEDD66FFCDDB +:20884300D58CEB110A00CD2A8DC1E17BC630770303C5110A00DD6EFEDD66FFCD2A8DC17B6F +:20886300C63002DDF9DDE1C9DDE5DD210000DD39E5210000E52E3CE5DD5E04DD5605DD6ECE +:2088830006DD6607CD16B9F1F1010000C50E64C5CD8FB8F1F14BC5210000E52E3CE5DD5E74 +:2088A30004DD5605DD6E06DD6607CD8FB8F1F1C151D52E0A7ACDD08C7B2E0ACD238D7BD1AA +:2088C300C630E1E577C1C503C5D52E0A7ACD238D7BD1C1C63002E1E52323363AC1C5030303 +:2088E30003C5D52E0A7BCDD08C7B2E0ACD238D7BD1C1C63002DD7EFEC6044FDD7EFFCE002D +:2089030047C52E0A7BCD238D7BC1C63002DDF9DDE1E1F1F1E9210900E5210401E511B78939 +:20892300216782CD2F8D210700E521040CE511C189216782CD2F8D210600E5210415E51154 +:20894300C989216782CD2F8D210500E5210601E511D089216782CD2F8D210300E521060CDE +:20896300E511D689216782CD2F8D116CB80E006926001936200C79D62038F4212000E521DD +:208983000804E5216782CD2F8D210804E5216782CD8B8D7AE63F57CBFBED538CB80E002AD7 +:2089A3008CB85D7CC6C0576926001936070C79D62038ECC95061747465726E3A23002020F2 +:2089C300526F773A2300202042504D3A0054696D653A00202F2000DDE5DD210000DD394B4D +:2089E30042EBDD7E07DDB606DDB605DDB604283069603E0529CB13CB123D20F8DD4E06DD72 +:208A03004607C5DD4E04DD4605C5EBCD16B9F1F14B423E20BB3E009A3009012000C3268A71 +:208A23000100001100002A8CB87CC6C067197B917A9830053E40C33E8A3E0777136B627DBC +:208A4300D6207CDE0038DFDDE1E1F1F1E9DDE5DD210000DD3921F8FF39F93A30B86F3E0B48 +:208A6300CDD4803EA8CD0880213200CDE8813E28CD2180DD77FF3A31B8D621201DDD7EFF36 +:208A8300D62020163EE4CD0880216400CDE881216782CDF78D3E02CD0380DD7EFF3231B815 +:208AA3003E2BCD2180DD77FA3E2CCD2180DD77FB3E02F53321010039EB3E31CDA8803E2DEA +:208AC300CD3A80DD73FCDD72FDDD75FEDD74FF3A2FB8FD212CB8FDB602FDB601FDB6002075 +:208AE3000C3E36CD3A80ED532CB8222EB8DD7EFAF5332162B8CDD1873E71F533210200E584 +:208B030021040AE51162B8216782CDB08DDD7EFBF5332162B8CDD1873E71F533210200E542 +:208B2300210413E51162B8216782CDB08DD1D52164B8CD0E883E71F533210300E521041B70 +:208B4300E51164B8216782CDB08D210000E52144ACE5DD5EFCDD56FDDD6EFEDD66FFCD161B +:208B6300B9F1E3D52167B8CD6B883E71F533210500E5210607E51167B8216782CDB08D2136 +:208B83000000E52144ACE5ED5B2CB82A2EB8CD16B9F1E3D52167B8CD6B883E71F533210579 +:208BA30000E521060FE51167B8216782CDB08D2A2EB8E52A2CB8E5DD5EFCDD56FDDD6EFED6 +:208BC300DD66FFCDDA89DDF9DDE1C93BCD0986216782CD658DCD2E8621878CCD11873A8E81 +:208BE300B83C200DCD5A82B73E0120023E02328EB83A8EB83D280733C37085C3858CAF324C +:208C03002CB8322DB8322EB8322FB8CDC182B720123A08B8D699200733C3A385C3858C3377 +:208C2300C3D685219F8CCD1187CD18892131B83621CD508AFD210000FD39FD36000076FDF2 +:208C4300210000FD39FD3400FD7E00D60A3807FD360000CD508ACD818DB728053E02CD1138 +:208C630085CD1A8EB728053E04CD1185CD108EB72804AFCD1185CD048DB728C2CD4285C3B8 +:208C8300418C33C94C6F6164696E672C20706C6561736520776169742E2E2E00506C61798F +:208CA300696E6700ED7300B83207B8ED4309B8083206B82202B8ED5304B83A07B8B7CACE61 +:0D8CC3008B3A07B8D603CAFE84AFC3038006 +:01B99900FFAE +:03800000C3A78C87 +:208CD0005D6F2600547BE680B220110610ED6A17933001833FED6A10F65FEBC906097D6C08 +:208CF0002600CB1DED6AED523001193F1710F5CB10505FC9DDE53E10CD0660DDE1C9DDE53C +:208D1000DD210000DD39DD46043E30CD0660DDE1E133E95D6FCDD28CEBC9CDD58CEBC9DD42 +:208D3000E5E5D5DD210000DD39DD460BDD4E0ADD5608DD5E09DD6E00DD6601D9DD6E02DDFC +:208D50006603E5DDE1D93E03CD0660D1E1DDE1E133333333E9DDE5E5DDE13E01CD0660DDF0 +:118D7000E1C908DDE53E53CD066020023EFFDDE1C9D4 +:20B88F00DDE5DD210000DD39010000DD7E07073838DDCB0426DDCB0516DDCB0616DDCB07E1 +:20B8AF00167BDD96047ADD9E057DDD9E067CDD9E073012DDCB073EDDCB061EDDCB051EDDD8 +:20B8CF00CB041E1804044818C27BDD96047ADD9E057DDD9E067CDD9E0738147BDD96045FA5 +:20B8EF007ADD9E05577DDD9E066F7CDD9E0767DDCB073EDDCB061EDDCB051EDDCB041E794F +:20B90F000DB720C5DDE1C9DDE5DD210000DD39F5F5AFDD77FCDD77FDDD77FEDD77FF06200D +:20B92F007C07E6014FCB23CB12ED6ADDCBFC26DDCBFD16DDCBFE16DDCBFF16CB412804DD0A +:20B94F00CBFCC6DD7EFCDD9604DD7EFDDD9E05DD7EFEDD9E06DD7EFFDD9E073826DD7EFC3A +:20B96F00DD9604DD77FCDD7EFDDD9E05DD77FDDD7EFEDD9E06DD77FEDD7EFFDD9E07DD776C +:0AB98F00FFCBC3109BDDF9DDE1C919 +:208D8100DDE53E1ACD0660DDE1C9DDE5E5DD210000DD39DD5606DD5E07DD6E00DD6601E554 +:208DA100DDE13E05CD0660EBE1DDE1E13333E9DDE5E5D5DD210000DD39DD460BDD4E0ADDF4 +:208DC1005608DD5E09DD6E00DD6601D9DD6E02DD6603DD7E0CF5E5DDE1D93E03CD0660F1B8 +:208DE10008D9E5DDE1D93E04CD0660D1E1DDE1E13333333333E9DDE5E5DDE13E02CD06608F +:208E0100DDE1C9AF474FEDB121FFFFED42EBC9DDE53E17CD0660DDE1C9DDE53E19CD0660C8 +:038E2100DDE1C9C7 :00000001FF diff --git a/obj/out.lst b/obj/out.lst index 55f9d12..e0062bd 100644 --- a/obj/out.lst +++ b/obj/out.lst @@ -16,2019 +16,2356 @@ 16 .globl _put_time 17 .globl _put_dec3 18 .globl _put_hex2 - 19 .globl _xm_draw_static_labels - 20 .globl _copy_file_name - 21 .globl _error_playback - 22 .globl _error_oom - 23 .globl _error_esp - 24 .globl _about - 25 .globl _wait_frames - 26 .globl _wait_esc_key - 27 .globl _play_xm - 28 .globl _esp_init - 29 .globl _esp_create_obj - 30 .globl _esp_wait_status - 31 .globl _esp_rd_end - 32 .globl _esp_send_dma - 33 .globl _esp_wr_end - 34 .globl _esp_wr_reg32 - 35 .globl _esp_wr_reg8 - 36 .globl _esp_rd_regs - 37 .globl _esp_rd_reg32 - 38 .globl _esp_rd_reg8 - 39 .globl _esp_cmd - 40 .globl _wc_set_freq_14mhz - 41 .globl _wc_exit - 42 .globl _wc_prsrw_attr - 43 .globl _wc_prsrw - 44 .globl _wc_key_pgdn - 45 .globl _wc_key_pgup - 46 .globl _wc_key_esc - 47 .globl _wc_load512 - 48 .globl _wc_rresb - 49 .globl _wc_prwow - 50 .globl _strlen - 51 .globl _state_esp - 52 .globl _last_track_status - 53 .globl _xm_handle - 54 .globl _total_samples - 55 .globl _file_name - 56 .globl _p_file_name - 57 .globl _last_esp_status - 58 .globl _call_type - 59 .globl _file_ext - 60 .globl _filesize - 61 .globl _ret_sp - 62 .globl _fs_buf - 63 .globl _win_about - 64 .globl _win_xm - 65 .globl _err_playback - 66 .globl _err_out_of_mem - 67 .globl _err_no_esp - 68 .globl _esp_wait_busy - 69 ;-------------------------------------------------------- - 70 ; special function registers - 71 ;-------------------------------------------------------- - 00000057 72 _SPI_DATA = 0x0057 - 00000077 73 _SPI_CTRL = 0x0077 - 000000FE 74 _BORDER = 0x00fe - 000000AF 75 _TS_VCONFIG = 0x00af - 000000AF 76 _TS_STATUS = 0x00af - 000001AF 77 _TS_VPAGE = 0x01af - 000002AF 78 _TS_GXOFFSL = 0x02af - 000003AF 79 _TS_GXOFFSH = 0x03af - 000004AF 80 _TS_GYOFFSL = 0x04af - 000005AF 81 _TS_GYOFFSH = 0x05af - 000006AF 82 _TS_TSCONFIG = 0x06af - 000007AF 83 _TS_PALSEL = 0x07af - 00000FAF 84 _TS_BORDER = 0x0faf - 000010AF 85 _TS_PAGE0 = 0x10af - 000011AF 86 _TS_PAGE1 = 0x11af - 000012AF 87 _TS_PAGE2 = 0x12af - 000013AF 88 _TS_PAGE3 = 0x13af - 000015AF 89 _TS_FMADDR = 0x15af - 000016AF 90 _TS_TMPAGE = 0x16af - 000017AF 91 _TS_T0GPAGE = 0x17af - 000018AF 92 _TS_T1GPAGE = 0x18af - 000019AF 93 _TS_SGPAGE = 0x19af - 00001AAF 94 _TS_DMASADDRL = 0x1aaf - 00001BAF 95 _TS_DMASADDRH = 0x1baf - 00001CAF 96 _TS_DMASADDRX = 0x1caf - 00001DAF 97 _TS_DMADADDRL = 0x1daf - 00001EAF 98 _TS_DMADADDRH = 0x1eaf - 00001FAF 99 _TS_DMADADDRX = 0x1faf - 000020AF 100 _TS_SYSCONFIG = 0x20af - 000021AF 101 _TS_MEMCONFIG = 0x21af - 000022AF 102 _TS_HSINT = 0x22af - 000023AF 103 _TS_VSINTL = 0x23af - 000024AF 104 _TS_VSINTH = 0x24af - 000025AF 105 _TS_DMAWPD = 0x25af - 000026AF 106 _TS_DMALEN = 0x26af - 000027AF 107 _TS_DMACTR = 0x27af - 000027AF 108 _TS_DMASTATUS = 0x27af - 000028AF 109 _TS_DMANUM = 0x28af - 000029AF 110 _TS_FDDVIRT = 0x29af - 00002AAF 111 _TS_INTMASK = 0x2aaf - 00002BAF 112 _TS_CACHECONF = 0x2baf - 00002CAF 113 _TS_DMANUMH = 0x2caf - 00002DAF 114 _TS_DMAWPA = 0x2daf - 000040AF 115 _TS_T0XOFFSL = 0x40af - 000041AF 116 _TS_T0XOFFSH = 0x41af - 000042AF 117 _TS_T0YOFFSL = 0x42af - 000043AF 118 _TS_T0YOFFSH = 0x43af - 000044AF 119 _TS_T1XOFFSL = 0x44af - 000045AF 120 _TS_T1XOFFSH = 0x45af - 000046AF 121 _TS_T1YOFFSL = 0x46af - 000047AF 122 _TS_T1YOFFSH = 0x47af - 123 ;-------------------------------------------------------- - 124 ; ram data - 125 ;-------------------------------------------------------- - 126 .area _DATA - 00000000 127 _fs_buf:: - 00000000 128 .ds 4096 - 00001000 129 _ret_sp:: - 00001000 130 .ds 2 - 00001002 131 _filesize:: - 00001002 132 .ds 4 - 00001006 133 _file_ext:: - 00001006 134 .ds 1 - 00001007 135 _call_type:: - 00001007 136 .ds 1 - 00001008 137 _last_esp_status:: - 00001008 138 .ds 1 - 00001009 139 _p_file_name:: - 00001009 140 .ds 2 - 0000100B 141 _file_name:: - 0000100B 142 .ds 33 - 0000102C 143 _total_samples:: - 0000102C 144 .ds 4 - 00001030 145 _xm_handle:: - 00001030 146 .ds 1 - 00001031 147 _last_track_status:: - 00001031 148 .ds 1 - 00001032 149 _hexbuf: - 00001032 150 .ds 2 - 00001034 151 _decbuf: - 00001034 152 .ds 3 - 00001037 153 _timebuf: - 00001037 154 .ds 5 - 0000103C 155 _barbuf: - 0000103C 156 .ds 34 - 157 ;-------------------------------------------------------- - 158 ; ram data - 159 ;-------------------------------------------------------- - 160 .area _INITIALIZED - 00000000 161 _state_esp:: - 00000000 162 .ds 1 - 163 ;-------------------------------------------------------- - 164 ; absolute ram data - 165 ;-------------------------------------------------------- - 166 .area _DABS (ABS) - 167 .area _DABS (ABS) - 168 ;-------------------------------------------------------- - 169 ; global & static initialisations + 19 .globl _xm_set_status_attr + 20 .globl _xm_draw_static_labels + 21 .globl _copy_file_name + 22 .globl _error_playback + 23 .globl _error_oom + 24 .globl _stop_on_error + 25 .globl _error_esp + 26 .globl _wait_for_manual_exit + 27 .globl _leave_playing_and_exit + 28 .globl _unload_and_exit + 29 .globl _about + 30 .globl _wait_frames + 31 .globl _wait_esc_key + 32 .globl _play_xm + 33 .globl _esp_init + 34 .globl _esp_create_obj + 35 .globl _esp_wait_status + 36 .globl _esp_rd_end + 37 .globl _esp_send_dma + 38 .globl _esp_wr_end + 39 .globl _esp_wr_reg32 + 40 .globl _esp_wr_reg8 + 41 .globl _esp_rd_regs + 42 .globl _esp_rd_reg32 + 43 .globl _esp_rd_reg8 + 44 .globl _esp_cmd + 45 .globl _wc_exit + 46 .globl _wc_prm_pl + 47 .globl _wc_gadrw + 48 .globl _wc_prsrw_attr + 49 .globl _wc_prsrw + 50 .globl _wc_key_space + 51 .globl _wc_key_pgdn + 52 .globl _wc_key_pgup + 53 .globl _wc_key_esc + 54 .globl _wc_load512 + 55 .globl _wc_rresb + 56 .globl _wc_prwow + 57 .globl _strlen + 58 .globl _state_esp + 59 .globl _bar_attr_ofs + 60 .globl _last_track_status + 61 .globl _xm_handle + 62 .globl _total_samples + 63 .globl _file_name + 64 .globl _p_file_name + 65 .globl _last_esp_status + 66 .globl _call_type + 67 .globl _file_ext + 68 .globl _filesize + 69 .globl _ret_sp + 70 .globl _fs_buf + 71 .globl _win_about + 72 .globl _win_xm + 73 .globl _esp_wait_busy + 74 .globl _xm_set_status + 75 .globl _xm_set_status_code + 76 ;-------------------------------------------------------- + 77 ; special function registers + 78 ;-------------------------------------------------------- + 00000057 79 _SPI_DATA = 0x0057 + 00000077 80 _SPI_CTRL = 0x0077 + 000000FE 81 _BORDER = 0x00fe + 000000AF 82 _TS_VCONFIG = 0x00af + 000000AF 83 _TS_STATUS = 0x00af + 000001AF 84 _TS_VPAGE = 0x01af + 000002AF 85 _TS_GXOFFSL = 0x02af + 000003AF 86 _TS_GXOFFSH = 0x03af + 000004AF 87 _TS_GYOFFSL = 0x04af + 000005AF 88 _TS_GYOFFSH = 0x05af + 000006AF 89 _TS_TSCONFIG = 0x06af + 000007AF 90 _TS_PALSEL = 0x07af + 00000FAF 91 _TS_BORDER = 0x0faf + 000010AF 92 _TS_PAGE0 = 0x10af + 000011AF 93 _TS_PAGE1 = 0x11af + 000012AF 94 _TS_PAGE2 = 0x12af + 000013AF 95 _TS_PAGE3 = 0x13af + 000015AF 96 _TS_FMADDR = 0x15af + 000016AF 97 _TS_TMPAGE = 0x16af + 000017AF 98 _TS_T0GPAGE = 0x17af + 000018AF 99 _TS_T1GPAGE = 0x18af + 000019AF 100 _TS_SGPAGE = 0x19af + 00001AAF 101 _TS_DMASADDRL = 0x1aaf + 00001BAF 102 _TS_DMASADDRH = 0x1baf + 00001CAF 103 _TS_DMASADDRX = 0x1caf + 00001DAF 104 _TS_DMADADDRL = 0x1daf + 00001EAF 105 _TS_DMADADDRH = 0x1eaf + 00001FAF 106 _TS_DMADADDRX = 0x1faf + 000020AF 107 _TS_SYSCONFIG = 0x20af + 000021AF 108 _TS_MEMCONFIG = 0x21af + 000022AF 109 _TS_HSINT = 0x22af + 000023AF 110 _TS_VSINTL = 0x23af + 000024AF 111 _TS_VSINTH = 0x24af + 000025AF 112 _TS_DMAWPD = 0x25af + 000026AF 113 _TS_DMALEN = 0x26af + 000027AF 114 _TS_DMACTR = 0x27af + 000027AF 115 _TS_DMASTATUS = 0x27af + 000028AF 116 _TS_DMANUM = 0x28af + 000029AF 117 _TS_FDDVIRT = 0x29af + 00002AAF 118 _TS_INTMASK = 0x2aaf + 00002BAF 119 _TS_CACHECONF = 0x2baf + 00002CAF 120 _TS_DMANUMH = 0x2caf + 00002DAF 121 _TS_DMAWPA = 0x2daf + 000040AF 122 _TS_T0XOFFSL = 0x40af + 000041AF 123 _TS_T0XOFFSH = 0x41af + 000042AF 124 _TS_T0YOFFSL = 0x42af + 000043AF 125 _TS_T0YOFFSH = 0x43af + 000044AF 126 _TS_T1XOFFSL = 0x44af + 000045AF 127 _TS_T1XOFFSH = 0x45af + 000046AF 128 _TS_T1YOFFSL = 0x46af + 000047AF 129 _TS_T1YOFFSH = 0x47af + 130 ;-------------------------------------------------------- + 131 ; ram data + 132 ;-------------------------------------------------------- + 133 .area _DATA + 00000000 134 _fs_buf:: + 00000000 135 .ds 4096 + 00001000 136 _ret_sp:: + 00001000 137 .ds 2 + 00001002 138 _filesize:: + 00001002 139 .ds 4 + 00001006 140 _file_ext:: + 00001006 141 .ds 1 + 00001007 142 _call_type:: + 00001007 143 .ds 1 + 00001008 144 _last_esp_status:: + 00001008 145 .ds 1 + 00001009 146 _p_file_name:: + 00001009 147 .ds 2 + 0000100B 148 _file_name:: + 0000100B 149 .ds 33 + 0000102C 150 _total_samples:: + 0000102C 151 .ds 4 + 00001030 152 _xm_handle:: + 00001030 153 .ds 1 + 00001031 154 _last_track_status:: + 00001031 155 .ds 1 + 00001032 156 _status_buf: + 00001032 157 .ds 24 + 0000104A 158 _status_code_buf: + 0000104A 159 .ds 24 + 00001062 160 _hexbuf: + 00001062 161 .ds 2 + 00001064 162 _decbuf: + 00001064 163 .ds 3 + 00001067 164 _timebuf: + 00001067 165 .ds 5 + 0000106C 166 _barbuf: + 0000106C 167 .ds 32 + 0000108C 168 _bar_attr_ofs:: + 0000108C 169 .ds 2 170 ;-------------------------------------------------------- - 171 .area _HOME - 172 .area _GSINIT - 173 .area _GSFINAL - 174 .area _GSINIT - 175 ;-------------------------------------------------------- - 176 ; Home - 177 ;-------------------------------------------------------- - 178 .area _HOME - 179 .area _HOME - 180 ;-------------------------------------------------------- - 181 ; code - 182 ;-------------------------------------------------------- - 183 .area _CODE - 184 ;src/wc_api.c:34: void wc_exit(u8 rc) __naked - 185 ; --------------------------------- - 186 ; Function wc_exit - 187 ; --------------------------------- - 00000000 188 _wc_exit:: - 189 ;src/wc_api.c:40: __endasm; - 00000000 ED 7Br00r10 [20] 190 ld sp, (_ret_sp) - 00000004 C9 [10] 191 ret - 192 ;src/wc_api.c:41: } - 193 ;src/wc_api.c:55: void wc_set_freq_14mhz() __naked - 194 ; --------------------------------- - 195 ; Function wc_set_freq_14mhz - 196 ; --------------------------------- - 00000005 197 _wc_set_freq_14mhz:: - 198 ;src/wc_api.c:62: __endasm; - 00000005 06 00 [ 7] 199 ld b, #0x00 ; type: Z80 frequency - 00000007 0E 02 [ 7] 200 ld c, #0x02 ; %10 = 14 MHz - 00000009 3E 0E [ 7] 201 ld a, #0x0E - 0000000B C3 06 60 [10] 202 jp 0x6006 - 203 ;src/wc_api.c:63: } - 204 ;src/esp32.c:18: void esp_cmd(u8 cmd) - 205 ; --------------------------------- - 206 ; Function esp_cmd - 207 ; --------------------------------- - 0000000E 208 _esp_cmd:: - 0000000E 4F [ 4] 209 ld c, a - 210 ;src/esp32.c:20: SPI_CTRL = SPI_ESP_CS_ON; - 0000000F 3E 13 [ 7] 211 ld a, #0x13 - 00000011 D3 77 [11] 212 out (_SPI_CTRL), a - 213 ;src/esp32.c:21: SPI_DATA = ESP_SPI_CMD_WR_REGS; - 00000013 3E 01 [ 7] 214 ld a, #0x01 - 00000015 D3 57 [11] 215 out (_SPI_DATA), a - 216 ;src/esp32.c:22: SPI_DATA = ESP_REG_COMMAND; - 00000017 AF [ 4] 217 xor a, a - 00000018 D3 57 [11] 218 out (_SPI_DATA), a - 219 ;src/esp32.c:23: SPI_DATA; // dummy - 0000001A DB 57 [11] 220 in a, (_SPI_DATA) - 221 ;src/esp32.c:24: SPI_DATA = cmd; // Command - 0000001C 79 [ 4] 222 ld a, c - 0000001D D3 57 [11] 223 out (_SPI_DATA), a - 224 ;src/esp32.c:25: SPI_DATA = ESP_ST_IDLE; // Reset status - 0000001F AF [ 4] 225 xor a, a - 00000020 D3 57 [11] 226 out (_SPI_DATA), a - 227 ;src/esp32.c:26: SPI_CTRL = SPI_ESP_CS_OFF; - 00000022 3E 03 [ 7] 228 ld a, #0x03 - 00000024 D3 77 [11] 229 out (_SPI_CTRL), a - 230 ;src/esp32.c:27: } - 00000026 C9 [10] 231 ret - 232 ;src/esp32.c:29: u8 esp_rd_reg8(u8 reg) - 233 ; --------------------------------- - 234 ; Function esp_rd_reg8 - 235 ; --------------------------------- - 00000027 236 _esp_rd_reg8:: - 00000027 4F [ 4] 237 ld c, a - 238 ;src/esp32.c:31: SPI_CTRL = SPI_ESP_CS_ON; - 00000028 3E 13 [ 7] 239 ld a, #0x13 - 0000002A D3 77 [11] 240 out (_SPI_CTRL), a - 241 ;src/esp32.c:32: SPI_DATA = ESP_SPI_CMD_RD_REGS; - 0000002C 3E 02 [ 7] 242 ld a, #0x02 - 0000002E D3 57 [11] 243 out (_SPI_DATA), a - 244 ;src/esp32.c:33: SPI_DATA = reg; - 00000030 79 [ 4] 245 ld a, c - 00000031 D3 57 [11] 246 out (_SPI_DATA), a - 247 ;src/esp32.c:34: SPI_DATA; // dummy - 00000033 DB 57 [11] 248 in a, (_SPI_DATA) - 249 ;src/esp32.c:35: SPI_DATA; // dummy - 00000035 DB 57 [11] 250 in a, (_SPI_DATA) - 251 ;src/esp32.c:36: u8 rc = SPI_DATA; - 00000037 DB 57 [11] 252 in a, (_SPI_DATA) - 00000039 4F [ 4] 253 ld c, a - 254 ;src/esp32.c:37: SPI_CTRL = SPI_ESP_CS_OFF; - 0000003A 3E 03 [ 7] 255 ld a, #0x03 - 0000003C D3 77 [11] 256 out (_SPI_CTRL), a - 257 ;src/esp32.c:39: return rc; - 0000003E 79 [ 4] 258 ld a, c - 259 ;src/esp32.c:40: } - 0000003F C9 [10] 260 ret - 261 ;src/esp32.c:42: u32 esp_rd_reg32(u8 reg) - 262 ; --------------------------------- - 263 ; Function esp_rd_reg32 - 264 ; --------------------------------- - 00000040 265 _esp_rd_reg32:: - 00000040 DD E5 [15] 266 push ix - 00000042 DD 21 00 00 [14] 267 ld ix, #0 - 00000046 DD 39 [15] 268 add ix, sp - 00000048 F5 [11] 269 push af - 00000049 F5 [11] 270 push af - 0000004A 4F [ 4] 271 ld c, a - 272 ;src/esp32.c:44: SPI_CTRL = SPI_ESP_CS_ON; - 0000004B 3E 13 [ 7] 273 ld a, #0x13 - 0000004D D3 77 [11] 274 out (_SPI_CTRL), a - 275 ;src/esp32.c:45: SPI_DATA = ESP_SPI_CMD_RD_REGS; - 0000004F 3E 02 [ 7] 276 ld a, #0x02 - 00000051 D3 57 [11] 277 out (_SPI_DATA), a - 278 ;src/esp32.c:46: SPI_DATA = reg; - 00000053 79 [ 4] 279 ld a, c - 00000054 D3 57 [11] 280 out (_SPI_DATA), a - 281 ;src/esp32.c:47: SPI_DATA; // dummy - 00000056 DB 57 [11] 282 in a, (_SPI_DATA) - 283 ;src/esp32.c:48: SPI_DATA; // dummy - 00000058 DB 57 [11] 284 in a, (_SPI_DATA) - 285 ;src/esp32.c:49: u32 rc = SPI_DATA; - 0000005A DB 57 [11] 286 in a, (_SPI_DATA) - 0000005C 4F [ 4] 287 ld c, a - 288 ;src/esp32.c:50: rc |= (u32)SPI_DATA << 8; - 0000005D DB 57 [11] 289 in a, (_SPI_DATA) - 0000005F 57 [ 4] 290 ld d, a - 00000060 59 [ 4] 291 ld e, c - 292 ;src/esp32.c:51: rc |= (u32)SPI_DATA << 16; - 00000061 DB 57 [11] 293 in a, (_SPI_DATA) - 00000063 DD 77 FC [19] 294 ld -4 (ix), a - 00000066 AF [ 4] 295 xor a, a - 00000067 DD 77 FD [19] 296 ld -3 (ix), a - 0000006A DD 77 FE [19] 297 ld -2 (ix), a - 0000006D DD 77 FF [19] 298 ld -1 (ix), a - 00000070 DD 7E FC [19] 299 ld a, -4 (ix) - 00000073 DD 77 FE [19] 300 ld -2 (ix), a - 00000076 AF [ 4] 301 xor a, a - 00000077 DD 77 FF [19] 302 ld -1 (ix), a - 0000007A DD 77 FC [19] 303 ld -4 (ix), a - 0000007D DD 77 FD [19] 304 ld -3 (ix), a - 00000080 DD 6E FE [19] 305 ld l, -2 (ix) - 306 ;src/esp32.c:52: rc |= (u32)SPI_DATA << 24; - 00000083 DB 57 [11] 307 in a, (_SPI_DATA) - 00000085 DD 77 FC [19] 308 ld -4 (ix), a - 00000088 AF [ 4] 309 xor a, a - 00000089 DD 77 FD [19] 310 ld -3 (ix), a - 0000008C DD 77 FE [19] 311 ld -2 (ix), a - 0000008F DD 77 FF [19] 312 ld -1 (ix), a - 00000092 DD 7E FC [19] 313 ld a, -4 (ix) - 00000095 DD 77 FF [19] 314 ld -1 (ix), a - 00000098 AF [ 4] 315 xor a, a - 00000099 DD 77 FC [19] 316 ld -4 (ix), a - 0000009C DD 77 FD [19] 317 ld -3 (ix), a - 0000009F DD 77 FE [19] 318 ld -2 (ix), a - 000000A2 DD 66 FF [19] 319 ld h, -1 (ix) - 320 ;src/esp32.c:53: SPI_CTRL = SPI_ESP_CS_OFF; - 000000A5 3E 03 [ 7] 321 ld a, #0x03 - 000000A7 D3 77 [11] 322 out (_SPI_CTRL), a - 323 ;src/esp32.c:55: return rc; - 324 ;src/esp32.c:56: } - 000000A9 DD F9 [10] 325 ld sp, ix - 000000AB DD E1 [14] 326 pop ix - 000000AD C9 [10] 327 ret - 328 ;src/esp32.c:58: void esp_rd_regs(u8 reg, void *data, u8 size) - 329 ; --------------------------------- - 330 ; Function esp_rd_regs - 331 ; --------------------------------- - 000000AE 332 _esp_rd_regs:: - 000000AE 4F [ 4] 333 ld c, a - 334 ;src/esp32.c:60: u8 *d = (u8*)data; - 335 ;src/esp32.c:62: SPI_CTRL = SPI_ESP_CS_ON; - 000000AF 3E 13 [ 7] 336 ld a, #0x13 - 000000B1 D3 77 [11] 337 out (_SPI_CTRL), a - 338 ;src/esp32.c:63: SPI_DATA = ESP_SPI_CMD_RD_REGS; - 000000B3 3E 02 [ 7] 339 ld a, #0x02 - 000000B5 D3 57 [11] 340 out (_SPI_DATA), a - 341 ;src/esp32.c:64: SPI_DATA = reg; - 000000B7 79 [ 4] 342 ld a, c - 000000B8 D3 57 [11] 343 out (_SPI_DATA), a - 344 ;src/esp32.c:65: SPI_DATA; // dummy - 000000BA DB 57 [11] 345 in a, (_SPI_DATA) - 346 ;src/esp32.c:66: SPI_DATA; // dummy - 000000BC DB 57 [11] 347 in a, (_SPI_DATA) - 348 ;src/esp32.c:67: while (size--) *d++ = SPI_DATA; - 000000BE FD 21 02 00 [14] 349 ld iy, #2 - 000000C2 FD 39 [15] 350 add iy, sp - 000000C4 FD 4E 00 [19] 351 ld c, 0 (iy) - 000000C7 352 00101$: - 000000C7 79 [ 4] 353 ld a, c - 000000C8 0D [ 4] 354 dec c - 000000C9 B7 [ 4] 355 or a, a - 000000CA 28 07 [12] 356 jr z, 00103$ - 000000CC DB 57 [11] 357 in a, (_SPI_DATA) - 000000CE 12 [ 7] 358 ld (de), a - 000000CF 13 [ 6] 359 inc de - 000000D0 C3rC7r00 [10] 360 jp 00101$ - 000000D3 361 00103$: - 362 ;src/esp32.c:68: SPI_CTRL = SPI_ESP_CS_OFF; - 000000D3 3E 03 [ 7] 363 ld a, #0x03 - 000000D5 D3 77 [11] 364 out (_SPI_CTRL), a - 365 ;src/esp32.c:69: } - 000000D7 E1 [10] 366 pop hl - 000000D8 33 [ 6] 367 inc sp - 000000D9 E9 [ 4] 368 jp (hl) - 369 ;src/esp32.c:71: void esp_wr_reg8(u8 reg, u8 data) - 370 ; --------------------------------- - 371 ; Function esp_wr_reg8 - 372 ; --------------------------------- - 000000DA 373 _esp_wr_reg8:: - 000000DA 47 [ 4] 374 ld b, a - 000000DB 4D [ 4] 375 ld c, l - 376 ;src/esp32.c:73: SPI_CTRL = SPI_ESP_CS_ON; - 000000DC 3E 13 [ 7] 377 ld a, #0x13 - 000000DE D3 77 [11] 378 out (_SPI_CTRL), a - 379 ;src/esp32.c:74: SPI_DATA = ESP_SPI_CMD_WR_REGS; - 000000E0 3E 01 [ 7] 380 ld a, #0x01 - 000000E2 D3 57 [11] 381 out (_SPI_DATA), a - 382 ;src/esp32.c:75: SPI_DATA = reg; - 000000E4 78 [ 4] 383 ld a, b - 000000E5 D3 57 [11] 384 out (_SPI_DATA), a - 385 ;src/esp32.c:76: SPI_DATA; // dummy - 000000E7 DB 57 [11] 386 in a, (_SPI_DATA) - 387 ;src/esp32.c:77: SPI_DATA = data; - 000000E9 79 [ 4] 388 ld a, c - 000000EA D3 57 [11] 389 out (_SPI_DATA), a - 390 ;src/esp32.c:78: SPI_CTRL = SPI_ESP_CS_OFF; - 000000EC 3E 03 [ 7] 391 ld a, #0x03 - 000000EE D3 77 [11] 392 out (_SPI_CTRL), a - 393 ;src/esp32.c:79: } - 000000F0 C9 [10] 394 ret - 395 ;src/esp32.c:81: void esp_wr_reg32(u8 reg, u32 data) - 396 ; --------------------------------- - 397 ; Function esp_wr_reg32 - 398 ; --------------------------------- - 000000F1 399 _esp_wr_reg32:: - 000000F1 4F [ 4] 400 ld c, a - 401 ;src/esp32.c:83: SPI_CTRL = SPI_ESP_CS_ON; - 000000F2 3E 13 [ 7] 402 ld a, #0x13 - 000000F4 D3 77 [11] 403 out (_SPI_CTRL), a - 404 ;src/esp32.c:84: SPI_DATA = ESP_SPI_CMD_WR_REGS; - 000000F6 3E 01 [ 7] 405 ld a, #0x01 - 000000F8 D3 57 [11] 406 out (_SPI_DATA), a - 407 ;src/esp32.c:85: SPI_DATA = reg; - 000000FA 79 [ 4] 408 ld a, c - 000000FB D3 57 [11] 409 out (_SPI_DATA), a - 410 ;src/esp32.c:86: SPI_DATA; // dummy - 000000FD DB 57 [11] 411 in a, (_SPI_DATA) - 412 ;src/esp32.c:87: SPI_DATA = (u8)data; - 000000FF FD 21 02 00 [14] 413 ld iy, #2 - 00000103 FD 39 [15] 414 add iy, sp - 00000105 FD 7E 00 [19] 415 ld a, 0 (iy) - 00000108 D3 57 [11] 416 out (_SPI_DATA), a - 417 ;src/esp32.c:88: SPI_DATA = (u8)(data >> 8); - 0000010A FD 7E 01 [19] 418 ld a, 1 (iy) - 0000010D D3 57 [11] 419 out (_SPI_DATA), a - 420 ;src/esp32.c:89: SPI_DATA = (u8)(data >> 16); - 0000010F FD 7E 02 [19] 421 ld a, 2 (iy) - 00000112 D3 57 [11] 422 out (_SPI_DATA), a - 423 ;src/esp32.c:90: SPI_DATA = (u8)(data >> 24); - 00000114 FD 7E 03 [19] 424 ld a, 3 (iy) - 00000117 D3 57 [11] 425 out (_SPI_DATA), a - 426 ;src/esp32.c:91: SPI_CTRL = SPI_ESP_CS_OFF; - 00000119 3E 03 [ 7] 427 ld a, #0x03 - 0000011B D3 77 [11] 428 out (_SPI_CTRL), a - 429 ;src/esp32.c:92: } - 0000011D E1 [10] 430 pop hl - 0000011E F1 [10] 431 pop af - 0000011F F1 [10] 432 pop af - 00000120 E9 [ 4] 433 jp (hl) - 434 ;src/esp32.c:94: void esp_wr_end() - 435 ; --------------------------------- - 436 ; Function esp_wr_end - 437 ; --------------------------------- - 00000121 438 _esp_wr_end:: - 439 ;src/esp32.c:96: SPI_CTRL = SPI_ESP_CS_ON; - 00000121 3E 13 [ 7] 440 ld a, #0x13 - 00000123 D3 77 [11] 441 out (_SPI_CTRL), a - 442 ;src/esp32.c:97: SPI_DATA = ESP_SPI_CMD_W_END; - 00000125 3E 07 [ 7] 443 ld a, #0x07 - 00000127 D3 57 [11] 444 out (_SPI_DATA), a - 445 ;src/esp32.c:98: SPI_DATA; // dummy - 00000129 DB 57 [11] 446 in a, (_SPI_DATA) - 447 ;src/esp32.c:99: SPI_CTRL = SPI_ESP_CS_OFF; - 0000012B 3E 03 [ 7] 448 ld a, #0x03 - 0000012D D3 77 [11] 449 out (_SPI_CTRL), a - 450 ;src/esp32.c:100: } - 0000012F C9 [10] 451 ret - 452 ;src/esp32.c:102: void esp_send_dma(u16 a, u8 p, u16 l, u16 n) - 453 ; --------------------------------- - 454 ; Function esp_send_dma - 455 ; --------------------------------- - 00000130 456 _esp_send_dma:: - 00000130 7D [ 4] 457 ld a, l - 458 ;src/esp32.c:105: TS_DMASADDRL = (u8)a; - 00000131 01 AF 1A [10] 459 ld bc, #_TS_DMASADDRL - 00000134 ED 79 [12] 460 out (c), a - 461 ;src/esp32.c:106: TS_DMASADDRH = (u8)((u16)a >> 8); - 00000136 7C [ 4] 462 ld a, h - 00000137 01 AF 1B [10] 463 ld bc, #_TS_DMASADDRH - 0000013A ED 79 [12] 464 out (c), a - 465 ;src/esp32.c:107: TS_DMASADDRX = p; - 0000013C FD 21 02 00 [14] 466 ld iy, #2 - 00000140 FD 39 [15] 467 add iy, sp - 00000142 FD 7E 00 [19] 468 ld a, 0 (iy) - 00000145 01 AF 1C [10] 469 ld bc, #_TS_DMASADDRX - 00000148 ED 79 [12] 470 out (c), a - 471 ;src/esp32.c:108: TS_DMALEN = (u8)((l >> 1) - 1); - 0000014A FD 7E 01 [19] 472 ld a, 1 (iy) - 0000014D FD 4E 02 [19] 473 ld c, 2 (iy) - 00000150 FD 23 [10] 474 inc iy - 00000152 CB 39 [ 8] 475 srl c - 00000154 CB 1F [ 8] 476 rr a - 00000156 3D [ 4] 477 dec a - 00000157 01 AF 26 [10] 478 ld bc, #_TS_DMALEN - 0000015A ED 79 [12] 479 out (c), a - 480 ;src/esp32.c:109: TS_DMANUM = (u8)(n - 1); - 0000015C FD 7E 02 [19] 481 ld a, 2 (iy) - 0000015F 3D [ 4] 482 dec a - 00000160 01 AF 28 [10] 483 ld bc, #_TS_DMANUM - 00000163 ED 79 [12] 484 out (c), a - 485 ;src/esp32.c:111: SPI_CTRL = SPI_ESP_CS_ON; - 00000165 3E 13 [ 7] 486 ld a, #0x13 - 00000167 D3 77 [11] 487 out (_SPI_CTRL), a - 488 ;src/esp32.c:112: SPI_DATA = ESP_SPI_CMD_WR_DATA; - 00000169 3E 03 [ 7] 489 ld a, #0x03 - 0000016B D3 57 [11] 490 out (_SPI_DATA), a - 491 ;src/esp32.c:113: SPI_DATA; // dummy - 0000016D DB 57 [11] 492 in a, (_SPI_DATA) - 493 ;src/esp32.c:114: SPI_DATA; // dummy - 0000016F DB 57 [11] 494 in a, (_SPI_DATA) - 495 ;src/esp32.c:115: TS_DMACTR = TS_DMA_RAM_SPI; - 00000171 3E 82 [ 7] 496 ld a, #0x82 - 00000173 01 AF 27 [10] 497 ld bc, #_TS_DMACTR - 00000176 ED 79 [12] 498 out (c), a - 499 ;src/esp32.c:116: while (TS_DMASTATUS & 0x80); - 00000178 500 00101$: - 00000178 3E 27 [ 7] 501 ld a, #>(_TS_DMASTATUS) - 0000017A DB AF [11] 502 in a, (#<(_TS_DMASTATUS)) - 0000017C 07 [ 4] 503 rlca - 0000017D 38 F9 [12] 504 jr c, 00101$ - 505 ;src/esp32.c:117: SPI_CTRL = SPI_ESP_CS_OFF; - 0000017F 3E 03 [ 7] 506 ld a, #0x03 - 00000181 D3 77 [11] 507 out (_SPI_CTRL), a - 508 ;src/esp32.c:119: esp_wr_end(); - 00000183 CDr21r01 [17] 509 call _esp_wr_end - 510 ;src/esp32.c:120: esp_wait_busy(60000); - 00000186 11 60 EA [10] 511 ld de, #0xea60 - 00000189 21 00 00 [10] 512 ld hl, #0x0000 - 0000018C CDrDEr01 [17] 513 call _esp_wait_busy - 514 ;src/esp32.c:121: } - 0000018F E1 [10] 515 pop hl - 00000190 F1 [10] 516 pop af - 00000191 F1 [10] 517 pop af - 00000192 33 [ 6] 518 inc sp - 00000193 E9 [ 4] 519 jp (hl) - 520 ;src/esp32.c:123: void esp_rd_end() - 521 ; --------------------------------- - 522 ; Function esp_rd_end - 523 ; --------------------------------- - 00000194 524 _esp_rd_end:: - 525 ;src/esp32.c:125: SPI_CTRL = SPI_ESP_CS_ON; - 00000194 3E 13 [ 7] 526 ld a, #0x13 - 00000196 D3 77 [11] 527 out (_SPI_CTRL), a - 528 ;src/esp32.c:126: SPI_DATA = ESP_SPI_CMD_R_END; - 00000198 3E 08 [ 7] 529 ld a, #0x08 - 0000019A D3 57 [11] 530 out (_SPI_DATA), a - 531 ;src/esp32.c:127: SPI_DATA; // dummy - 0000019C DB 57 [11] 532 in a, (_SPI_DATA) - 533 ;src/esp32.c:128: SPI_CTRL = SPI_ESP_CS_OFF; - 0000019E 3E 03 [ 7] 534 ld a, #0x03 - 000001A0 D3 77 [11] 535 out (_SPI_CTRL), a - 536 ;src/esp32.c:129: } - 000001A2 C9 [10] 537 ret - 538 ;src/esp32.c:131: u32 esp_wait_status(u8 status, u32 timeout) - 539 ; --------------------------------- - 540 ; Function esp_wait_status - 541 ; --------------------------------- - 000001A3 542 _esp_wait_status:: - 000001A3 DD E5 [15] 543 push ix - 000001A5 DD 21 00 00 [14] 544 ld ix, #0 - 000001A9 DD 39 [15] 545 add ix, sp - 000001AB 4F [ 4] 546 ld c, a - 547 ;src/esp32.c:133: while (--timeout) if (esp_rd_reg8(ESP_REG_STATUS) == status) break; - 000001AC DD 5E 04 [19] 548 ld e, 4 (ix) - 000001AF DD 56 05 [19] 549 ld d, 5 (ix) - 000001B2 DD 6E 06 [19] 550 ld l, 6 (ix) - 000001B5 DD 66 07 [19] 551 ld h, 7 (ix) - 000001B8 552 00103$: - 000001B8 7B [ 4] 553 ld a, e - 000001B9 C6 FF [ 7] 554 add a, #0xff - 000001BB 5F [ 4] 555 ld e, a - 000001BC 7A [ 4] 556 ld a, d - 000001BD CE FF [ 7] 557 adc a, #0xff - 000001BF 57 [ 4] 558 ld d, a - 000001C0 7D [ 4] 559 ld a, l - 000001C1 CE FF [ 7] 560 adc a, #0xff - 000001C3 6F [ 4] 561 ld l, a - 000001C4 7C [ 4] 562 ld a, h - 000001C5 CE FF [ 7] 563 adc a, #0xff - 000001C7 67 [ 4] 564 ld h, a - 000001C8 B5 [ 4] 565 or a, l - 000001C9 B2 [ 4] 566 or a, d - 000001CA B3 [ 4] 567 or a, e - 000001CB 28 0E [12] 568 jr z, 00105$ - 000001CD E5 [11] 569 push hl - 000001CE C5 [11] 570 push bc - 000001CF D5 [11] 571 push de - 000001D0 3E 01 [ 7] 572 ld a, #0x01 - 000001D2 CDr27r00 [17] 573 call _esp_rd_reg8 - 000001D5 D1 [10] 574 pop de - 000001D6 C1 [10] 575 pop bc - 000001D7 E1 [10] 576 pop hl - 000001D8 91 [ 4] 577 sub a, c - 000001D9 20 DD [12] 578 jr nz, 00103$ - 000001DB 579 00105$: - 580 ;src/esp32.c:135: return timeout; - 581 ;src/esp32.c:136: } - 000001DB DD E1 [14] 582 pop ix - 000001DD C9 [10] 583 ret - 584 ;src/esp32.c:138: u32 esp_wait_busy(u32 timeout) - 585 ; --------------------------------- - 586 ; Function esp_wait_busy - 587 ; --------------------------------- - 000001DE 588 _esp_wait_busy:: - 589 ;src/esp32.c:140: while (--timeout) if (esp_rd_reg8(ESP_REG_STATUS) != ESP_ST_BUSY) break; - 000001DE 590 00103$: - 000001DE 7B [ 4] 591 ld a, e - 000001DF C6 FF [ 7] 592 add a, #0xff - 000001E1 5F [ 4] 593 ld e, a - 000001E2 7A [ 4] 594 ld a, d - 000001E3 CE FF [ 7] 595 adc a, #0xff - 000001E5 57 [ 4] 596 ld d, a - 000001E6 7D [ 4] 597 ld a, l - 000001E7 CE FF [ 7] 598 adc a, #0xff - 000001E9 6F [ 4] 599 ld l, a - 000001EA 7C [ 4] 600 ld a, h - 000001EB CE FF [ 7] 601 adc a, #0xff - 000001ED 67 [ 4] 602 ld h, a - 000001EE B5 [ 4] 603 or a, l - 000001EF B2 [ 4] 604 or a, d - 000001F0 B3 [ 4] 605 or a, e - 000001F1 C8 [11] 606 ret z - 000001F2 E5 [11] 607 push hl - 000001F3 D5 [11] 608 push de - 000001F4 3E 01 [ 7] 609 ld a, #0x01 - 000001F6 CDr27r00 [17] 610 call _esp_rd_reg8 - 000001F9 D1 [10] 611 pop de - 000001FA E1 [10] 612 pop hl - 000001FB FE 02 [ 7] 613 cp a, #0x02 - 000001FD 28 DF [12] 614 jr z, 00103$ - 615 ;src/esp32.c:142: return timeout; - 616 ;src/esp32.c:143: } - 000001FF C9 [10] 617 ret - 618 ;src/esp32.c:145: int esp_create_obj(u32 size, u8 type) - 619 ; --------------------------------- - 620 ; Function esp_create_obj - 621 ; --------------------------------- - 00000200 622 _esp_create_obj:: - 623 ;src/esp32.c:147: esp_wr_reg32(ESP_REG_DATA_SIZE, size); - 00000200 E5 [11] 624 push hl - 00000201 D5 [11] 625 push de - 00000202 3E 03 [ 7] 626 ld a, #0x03 - 00000204 CDrF1r00 [17] 627 call _esp_wr_reg32 - 628 ;src/esp32.c:148: esp_wr_reg8(ESP_REG_OBJ_TYPE, type); - 00000207 FD 21 02 00 [14] 629 ld iy, #2 - 0000020B FD 39 [15] 630 add iy, sp - 0000020D FD 6E 00 [19] 631 ld l, 0 (iy) - 00000210 3E 02 [ 7] 632 ld a, #0x02 - 00000212 CDrDAr00 [17] 633 call _esp_wr_reg8 - 634 ;src/esp32.c:149: esp_cmd(ESP_CMD_MAKE_OBJECT); - 00000215 3E E0 [ 7] 635 ld a, #0xe0 - 00000217 CDr0Er00 [17] 636 call _esp_cmd - 637 ;src/esp32.c:150: esp_wait_busy(20000); - 0000021A 11 20 4E [10] 638 ld de, #0x4e20 - 0000021D 21 00 00 [10] 639 ld hl, #0x0000 - 00000220 CDrDEr01 [17] 640 call _esp_wait_busy - 641 ;src/esp32.c:153: return esp_rd_reg8(ESP_REG_OBJ_HANDLE); - 00000223 3E 0B [ 7] 642 ld a, #0x0b - 00000225 CDr27r00 [17] 643 call _esp_rd_reg8 - 00000228 5F [ 4] 644 ld e, a - 00000229 16 00 [ 7] 645 ld d, #0x00 - 646 ;src/esp32.c:154: } - 0000022B E1 [10] 647 pop hl - 0000022C 33 [ 6] 648 inc sp - 0000022D E9 [ 4] 649 jp (hl) - 650 ;src/main.c:143: bool esp_init() - 651 ; --------------------------------- - 652 ; Function esp_init - 653 ; --------------------------------- - 0000022E 654 _esp_init:: - 655 ;src/main.c:145: esp_cmd(ESP_CMD_NOP); - 0000022E AF [ 4] 656 xor a, a - 0000022F CDr0Er00 [17] 657 call _esp_cmd - 658 ;src/main.c:146: esp_rd_end(); - 00000232 CDr94r01 [17] 659 call _esp_rd_end - 660 ;src/main.c:147: esp_wr_end(); - 00000235 CDr21r01 [17] 661 call _esp_wr_end - 662 ;src/main.c:151: return true; - 00000238 3E 01 [ 7] 663 ld a, #0x01 - 664 ;src/main.c:152: } - 0000023A C9 [10] 665 ret - 0000023B 666 _err_no_esp: - 0000023B 01 667 .db #0x01 ; 1 - 0000023C 00 668 .db #0x00 ; 0 - 0000023D 18 669 .db #0x18 ; 24 - 0000023E 0A 670 .db #0x0a ; 10 - 0000023F 20 671 .db #0x20 ; 32 - 00000240 05 672 .db #0x05 ; 5 - 00000241 2F 673 .db #0x2f ; 47 - 00000242 00 674 .db #0x00 ; 0 - 00000243 00 00 675 .dw #0x0000 - 00000245 00 676 .db #0x00 ; 0 - 00000246 00 677 .db #0x00 ; 0 - 00000247r95r02 678 .dw __str_0 - 00000249r9Fr02 679 .dw __str_1 - 0000024BrA0r02 680 .dw __str_2 - 0000024D 681 _err_out_of_mem: - 0000024D 01 682 .db #0x01 ; 1 - 0000024E 00 683 .db #0x00 ; 0 - 0000024F FF 684 .db #0xff ; 255 - 00000250 FF 685 .db #0xff ; 255 - 00000251 20 686 .db #0x20 ; 32 - 00000252 05 687 .db #0x05 ; 5 - 00000253 2F 688 .db #0x2f ; 47 - 00000254 00 689 .db #0x00 ; 0 - 00000255 00 00 690 .dw #0x0000 - 00000257 00 691 .db #0x00 ; 0 - 00000258 00 692 .db #0x00 ; 0 - 00000259r95r02 693 .dw __str_0 - 0000025Br9Fr02 694 .dw __str_1 - 0000025DrB6r02 695 .dw __str_3 - 0000025F 696 _err_playback: - 0000025F 01 697 .db #0x01 ; 1 - 00000260 00 698 .db #0x00 ; 0 - 00000261 FF 699 .db #0xff ; 255 - 00000262 FF 700 .db #0xff ; 255 - 00000263 20 701 .db #0x20 ; 32 - 00000264 05 702 .db #0x05 ; 5 - 00000265 2F 703 .db #0x2f ; 47 - 00000266 00 704 .db #0x00 ; 0 - 00000267 00 00 705 .dw #0x0000 - 00000269 00 706 .db #0x00 ; 0 - 0000026A 00 707 .db #0x00 ; 0 - 0000026Br95r02 708 .dw __str_0 - 0000026Dr9Fr02 709 .dw __str_1 - 0000026FrD6r02 710 .dw __str_4 - 00000271 711 _win_xm: - 00000271 81 712 .db #0x81 ; 129 - 00000272 00 713 .db #0x00 ; 0 - 00000273 19 714 .db #0x19 ; 25 - 00000274 0A 715 .db #0x0a ; 10 - 00000275 28 716 .db #0x28 ; 40 - 00000276 0B 717 .db #0x0b ; 11 - 00000277 4F 718 .db #0x4f ; 79 'O' - 00000278 00 719 .db #0x00 ; 0 - 00000279 00 00 720 .dw #0x0000 - 0000027B 00 721 .db #0x00 ; 0 - 0000027C 00 722 .db #0x00 ; 0 - 0000027DrF4r02 723 .dw __str_5 - 0000027Fr9Fr02 724 .dw __str_1 - 00000281r09r03 725 .dw __str_6 - 00000283 726 _win_about: - 00000283 01 727 .db #0x01 ; 1 - 00000284 00 728 .db #0x00 ; 0 - 00000285 16 729 .db #0x16 ; 22 - 00000286 0A 730 .db #0x0a ; 10 - 00000287 24 731 .db #0x24 ; 36 - 00000288 05 732 .db #0x05 ; 5 - 00000289 4F 733 .db #0x4f ; 79 'O' - 0000028A 00 734 .db #0x00 ; 0 - 0000028B 00 00 735 .dw #0x0000 - 0000028D 00 736 .db #0x00 ; 0 - 0000028E 00 737 .db #0x00 ; 0 - 0000028Fr17r03 738 .dw __str_7 - 00000291r9Fr02 739 .dw __str_1 - 00000293r20r03 740 .dw __str_8 - 00000295 741 __str_0: - 00000295 0E 742 .db 0x0e - 00000296 20 45 72 72 6F 72 21 743 .ascii " Error! " - 20 - 0000029E 00 744 .db 0x00 - 0000029F 745 __str_1: - 0000029F 00 746 .db 0x00 - 000002A0 747 __str_2: - 000002A0 0E 748 .db 0x0e - 000002A1 0C 749 .db 0x0c - 000002A2 01 750 .db 0x01 - 000002A3 4E 6F 20 45 53 50 33 751 .ascii "No ESP32 detected!" - 32 20 64 65 74 65 63 - 74 65 64 21 - 000002B5 00 752 .db 0x00 - 000002B6 753 __str_3: - 000002B6 0E 754 .db 0x0e - 000002B7 0C 755 .db 0x0c - 000002B8 01 756 .db 0x01 - 000002B9 4F 75 74 20 6F 66 20 757 .ascii "Out of memory (file too big)" - 6D 65 6D 6F 72 79 20 - 28 66 69 6C 65 20 74 - 6F 6F 20 62 69 67 29 - 000002D5 00 758 .db 0x00 - 000002D6 759 __str_4: - 000002D6 0E 760 .db 0x0e - 000002D7 0C 761 .db 0x0c - 000002D8 01 762 .db 0x01 - 000002D9 50 6C 61 79 62 61 63 763 .ascii "Playback error (bad file?)" - 6B 20 65 72 72 6F 72 - 20 28 62 61 64 20 66 - 69 6C 65 3F 29 - 000002F3 00 764 .db 0x00 - 000002F4 765 __str_5: - 000002F4 0E 766 .db 0x0e - 000002F5 20 58 4D 2F 58 4D 5A 767 .ascii " XM/XMZ/S3M Player " + 171 ; ram data + 172 ;-------------------------------------------------------- + 173 .area _INITIALIZED + 00000000 174 _state_esp:: + 00000000 175 .ds 1 + 176 ;-------------------------------------------------------- + 177 ; absolute ram data + 178 ;-------------------------------------------------------- + 179 .area _DABS (ABS) + 180 .area _DABS (ABS) + 181 ;-------------------------------------------------------- + 182 ; global & static initialisations + 183 ;-------------------------------------------------------- + 184 .area _HOME + 185 .area _GSINIT + 186 .area _GSFINAL + 187 .area _GSINIT + 188 ;-------------------------------------------------------- + 189 ; Home + 190 ;-------------------------------------------------------- + 191 .area _HOME + 192 .area _HOME + 193 ;-------------------------------------------------------- + 194 ; code + 195 ;-------------------------------------------------------- + 196 .area _CODE + 197 ;src/wc_api.c:47: void wc_exit(u8 rc) __naked + 198 ; --------------------------------- + 199 ; Function wc_exit + 200 ; --------------------------------- + 00000000 201 _wc_exit:: + 202 ;src/wc_api.c:53: __endasm; + 00000000 ED 7Br00r10 [20] 203 ld sp, (_ret_sp) + 00000004 C9 [10] 204 ret + 205 ;src/wc_api.c:54: } + 206 ;src/esp32.c:18: void esp_cmd(u8 cmd) + 207 ; --------------------------------- + 208 ; Function esp_cmd + 209 ; --------------------------------- + 00000005 210 _esp_cmd:: + 00000005 4F [ 4] 211 ld c, a + 212 ;src/esp32.c:20: SPI_CTRL = SPI_ESP_CS_ON; + 00000006 3E 13 [ 7] 213 ld a, #0x13 + 00000008 D3 77 [11] 214 out (_SPI_CTRL), a + 215 ;src/esp32.c:21: SPI_DATA = ESP_SPI_CMD_WR_REGS; + 0000000A 3E 01 [ 7] 216 ld a, #0x01 + 0000000C D3 57 [11] 217 out (_SPI_DATA), a + 218 ;src/esp32.c:22: SPI_DATA = ESP_REG_COMMAND; + 0000000E AF [ 4] 219 xor a, a + 0000000F D3 57 [11] 220 out (_SPI_DATA), a + 221 ;src/esp32.c:23: SPI_DATA; // dummy + 00000011 DB 57 [11] 222 in a, (_SPI_DATA) + 223 ;src/esp32.c:24: SPI_DATA = cmd; // Command + 00000013 79 [ 4] 224 ld a, c + 00000014 D3 57 [11] 225 out (_SPI_DATA), a + 226 ;src/esp32.c:25: SPI_DATA = ESP_ST_IDLE; // Reset status + 00000016 AF [ 4] 227 xor a, a + 00000017 D3 57 [11] 228 out (_SPI_DATA), a + 229 ;src/esp32.c:26: SPI_CTRL = SPI_ESP_CS_OFF; + 00000019 3E 03 [ 7] 230 ld a, #0x03 + 0000001B D3 77 [11] 231 out (_SPI_CTRL), a + 232 ;src/esp32.c:27: } + 0000001D C9 [10] 233 ret + 234 ;src/esp32.c:29: u8 esp_rd_reg8(u8 reg) + 235 ; --------------------------------- + 236 ; Function esp_rd_reg8 + 237 ; --------------------------------- + 0000001E 238 _esp_rd_reg8:: + 0000001E 4F [ 4] 239 ld c, a + 240 ;src/esp32.c:31: SPI_CTRL = SPI_ESP_CS_ON; + 0000001F 3E 13 [ 7] 241 ld a, #0x13 + 00000021 D3 77 [11] 242 out (_SPI_CTRL), a + 243 ;src/esp32.c:32: SPI_DATA = ESP_SPI_CMD_RD_REGS; + 00000023 3E 02 [ 7] 244 ld a, #0x02 + 00000025 D3 57 [11] 245 out (_SPI_DATA), a + 246 ;src/esp32.c:33: SPI_DATA = reg; + 00000027 79 [ 4] 247 ld a, c + 00000028 D3 57 [11] 248 out (_SPI_DATA), a + 249 ;src/esp32.c:34: SPI_DATA; // dummy + 0000002A DB 57 [11] 250 in a, (_SPI_DATA) + 251 ;src/esp32.c:35: SPI_DATA; // dummy + 0000002C DB 57 [11] 252 in a, (_SPI_DATA) + 253 ;src/esp32.c:36: u8 rc = SPI_DATA; + 0000002E DB 57 [11] 254 in a, (_SPI_DATA) + 00000030 4F [ 4] 255 ld c, a + 256 ;src/esp32.c:37: SPI_CTRL = SPI_ESP_CS_OFF; + 00000031 3E 03 [ 7] 257 ld a, #0x03 + 00000033 D3 77 [11] 258 out (_SPI_CTRL), a + 259 ;src/esp32.c:39: return rc; + 00000035 79 [ 4] 260 ld a, c + 261 ;src/esp32.c:40: } + 00000036 C9 [10] 262 ret + 263 ;src/esp32.c:42: u32 esp_rd_reg32(u8 reg) + 264 ; --------------------------------- + 265 ; Function esp_rd_reg32 + 266 ; --------------------------------- + 00000037 267 _esp_rd_reg32:: + 00000037 DD E5 [15] 268 push ix + 00000039 DD 21 00 00 [14] 269 ld ix, #0 + 0000003D DD 39 [15] 270 add ix, sp + 0000003F F5 [11] 271 push af + 00000040 F5 [11] 272 push af + 00000041 4F [ 4] 273 ld c, a + 274 ;src/esp32.c:44: SPI_CTRL = SPI_ESP_CS_ON; + 00000042 3E 13 [ 7] 275 ld a, #0x13 + 00000044 D3 77 [11] 276 out (_SPI_CTRL), a + 277 ;src/esp32.c:45: SPI_DATA = ESP_SPI_CMD_RD_REGS; + 00000046 3E 02 [ 7] 278 ld a, #0x02 + 00000048 D3 57 [11] 279 out (_SPI_DATA), a + 280 ;src/esp32.c:46: SPI_DATA = reg; + 0000004A 79 [ 4] 281 ld a, c + 0000004B D3 57 [11] 282 out (_SPI_DATA), a + 283 ;src/esp32.c:47: SPI_DATA; // dummy + 0000004D DB 57 [11] 284 in a, (_SPI_DATA) + 285 ;src/esp32.c:48: SPI_DATA; // dummy + 0000004F DB 57 [11] 286 in a, (_SPI_DATA) + 287 ;src/esp32.c:49: u32 rc = SPI_DATA; + 00000051 DB 57 [11] 288 in a, (_SPI_DATA) + 00000053 4F [ 4] 289 ld c, a + 290 ;src/esp32.c:50: rc |= (u32)SPI_DATA << 8; + 00000054 DB 57 [11] 291 in a, (_SPI_DATA) + 00000056 57 [ 4] 292 ld d, a + 00000057 59 [ 4] 293 ld e, c + 294 ;src/esp32.c:51: rc |= (u32)SPI_DATA << 16; + 00000058 DB 57 [11] 295 in a, (_SPI_DATA) + 0000005A DD 77 FC [19] 296 ld -4 (ix), a + 0000005D AF [ 4] 297 xor a, a + 0000005E DD 77 FD [19] 298 ld -3 (ix), a + 00000061 DD 77 FE [19] 299 ld -2 (ix), a + 00000064 DD 77 FF [19] 300 ld -1 (ix), a + 00000067 DD 7E FC [19] 301 ld a, -4 (ix) + 0000006A DD 77 FE [19] 302 ld -2 (ix), a + 0000006D AF [ 4] 303 xor a, a + 0000006E DD 77 FF [19] 304 ld -1 (ix), a + 00000071 DD 77 FC [19] 305 ld -4 (ix), a + 00000074 DD 77 FD [19] 306 ld -3 (ix), a + 00000077 DD 6E FE [19] 307 ld l, -2 (ix) + 308 ;src/esp32.c:52: rc |= (u32)SPI_DATA << 24; + 0000007A DB 57 [11] 309 in a, (_SPI_DATA) + 0000007C DD 77 FC [19] 310 ld -4 (ix), a + 0000007F AF [ 4] 311 xor a, a + 00000080 DD 77 FD [19] 312 ld -3 (ix), a + 00000083 DD 77 FE [19] 313 ld -2 (ix), a + 00000086 DD 77 FF [19] 314 ld -1 (ix), a + 00000089 DD 7E FC [19] 315 ld a, -4 (ix) + 0000008C DD 77 FF [19] 316 ld -1 (ix), a + 0000008F AF [ 4] 317 xor a, a + 00000090 DD 77 FC [19] 318 ld -4 (ix), a + 00000093 DD 77 FD [19] 319 ld -3 (ix), a + 00000096 DD 77 FE [19] 320 ld -2 (ix), a + 00000099 DD 66 FF [19] 321 ld h, -1 (ix) + 322 ;src/esp32.c:53: SPI_CTRL = SPI_ESP_CS_OFF; + 0000009C 3E 03 [ 7] 323 ld a, #0x03 + 0000009E D3 77 [11] 324 out (_SPI_CTRL), a + 325 ;src/esp32.c:55: return rc; + 326 ;src/esp32.c:56: } + 000000A0 DD F9 [10] 327 ld sp, ix + 000000A2 DD E1 [14] 328 pop ix + 000000A4 C9 [10] 329 ret + 330 ;src/esp32.c:58: void esp_rd_regs(u8 reg, void *data, u8 size) + 331 ; --------------------------------- + 332 ; Function esp_rd_regs + 333 ; --------------------------------- + 000000A5 334 _esp_rd_regs:: + 000000A5 4F [ 4] 335 ld c, a + 336 ;src/esp32.c:60: u8 *d = (u8*)data; + 337 ;src/esp32.c:62: SPI_CTRL = SPI_ESP_CS_ON; + 000000A6 3E 13 [ 7] 338 ld a, #0x13 + 000000A8 D3 77 [11] 339 out (_SPI_CTRL), a + 340 ;src/esp32.c:63: SPI_DATA = ESP_SPI_CMD_RD_REGS; + 000000AA 3E 02 [ 7] 341 ld a, #0x02 + 000000AC D3 57 [11] 342 out (_SPI_DATA), a + 343 ;src/esp32.c:64: SPI_DATA = reg; + 000000AE 79 [ 4] 344 ld a, c + 000000AF D3 57 [11] 345 out (_SPI_DATA), a + 346 ;src/esp32.c:65: SPI_DATA; // dummy + 000000B1 DB 57 [11] 347 in a, (_SPI_DATA) + 348 ;src/esp32.c:66: SPI_DATA; // dummy + 000000B3 DB 57 [11] 349 in a, (_SPI_DATA) + 350 ;src/esp32.c:67: while (size--) *d++ = SPI_DATA; + 000000B5 FD 21 02 00 [14] 351 ld iy, #2 + 000000B9 FD 39 [15] 352 add iy, sp + 000000BB FD 4E 00 [19] 353 ld c, 0 (iy) + 000000BE 354 00101$: + 000000BE 79 [ 4] 355 ld a, c + 000000BF 0D [ 4] 356 dec c + 000000C0 B7 [ 4] 357 or a, a + 000000C1 28 07 [12] 358 jr z, 00103$ + 000000C3 DB 57 [11] 359 in a, (_SPI_DATA) + 000000C5 12 [ 7] 360 ld (de), a + 000000C6 13 [ 6] 361 inc de + 000000C7 C3rBEr00 [10] 362 jp 00101$ + 000000CA 363 00103$: + 364 ;src/esp32.c:68: SPI_CTRL = SPI_ESP_CS_OFF; + 000000CA 3E 03 [ 7] 365 ld a, #0x03 + 000000CC D3 77 [11] 366 out (_SPI_CTRL), a + 367 ;src/esp32.c:69: } + 000000CE E1 [10] 368 pop hl + 000000CF 33 [ 6] 369 inc sp + 000000D0 E9 [ 4] 370 jp (hl) + 371 ;src/esp32.c:71: void esp_wr_reg8(u8 reg, u8 data) + 372 ; --------------------------------- + 373 ; Function esp_wr_reg8 + 374 ; --------------------------------- + 000000D1 375 _esp_wr_reg8:: + 000000D1 47 [ 4] 376 ld b, a + 000000D2 4D [ 4] 377 ld c, l + 378 ;src/esp32.c:73: SPI_CTRL = SPI_ESP_CS_ON; + 000000D3 3E 13 [ 7] 379 ld a, #0x13 + 000000D5 D3 77 [11] 380 out (_SPI_CTRL), a + 381 ;src/esp32.c:74: SPI_DATA = ESP_SPI_CMD_WR_REGS; + 000000D7 3E 01 [ 7] 382 ld a, #0x01 + 000000D9 D3 57 [11] 383 out (_SPI_DATA), a + 384 ;src/esp32.c:75: SPI_DATA = reg; + 000000DB 78 [ 4] 385 ld a, b + 000000DC D3 57 [11] 386 out (_SPI_DATA), a + 387 ;src/esp32.c:76: SPI_DATA; // dummy + 000000DE DB 57 [11] 388 in a, (_SPI_DATA) + 389 ;src/esp32.c:77: SPI_DATA = data; + 000000E0 79 [ 4] 390 ld a, c + 000000E1 D3 57 [11] 391 out (_SPI_DATA), a + 392 ;src/esp32.c:78: SPI_CTRL = SPI_ESP_CS_OFF; + 000000E3 3E 03 [ 7] 393 ld a, #0x03 + 000000E5 D3 77 [11] 394 out (_SPI_CTRL), a + 395 ;src/esp32.c:79: } + 000000E7 C9 [10] 396 ret + 397 ;src/esp32.c:81: void esp_wr_reg32(u8 reg, u32 data) + 398 ; --------------------------------- + 399 ; Function esp_wr_reg32 + 400 ; --------------------------------- + 000000E8 401 _esp_wr_reg32:: + 000000E8 4F [ 4] 402 ld c, a + 403 ;src/esp32.c:83: SPI_CTRL = SPI_ESP_CS_ON; + 000000E9 3E 13 [ 7] 404 ld a, #0x13 + 000000EB D3 77 [11] 405 out (_SPI_CTRL), a + 406 ;src/esp32.c:84: SPI_DATA = ESP_SPI_CMD_WR_REGS; + 000000ED 3E 01 [ 7] 407 ld a, #0x01 + 000000EF D3 57 [11] 408 out (_SPI_DATA), a + 409 ;src/esp32.c:85: SPI_DATA = reg; + 000000F1 79 [ 4] 410 ld a, c + 000000F2 D3 57 [11] 411 out (_SPI_DATA), a + 412 ;src/esp32.c:86: SPI_DATA; // dummy + 000000F4 DB 57 [11] 413 in a, (_SPI_DATA) + 414 ;src/esp32.c:87: SPI_DATA = (u8)data; + 000000F6 FD 21 02 00 [14] 415 ld iy, #2 + 000000FA FD 39 [15] 416 add iy, sp + 000000FC FD 7E 00 [19] 417 ld a, 0 (iy) + 000000FF D3 57 [11] 418 out (_SPI_DATA), a + 419 ;src/esp32.c:88: SPI_DATA = (u8)(data >> 8); + 00000101 FD 7E 01 [19] 420 ld a, 1 (iy) + 00000104 D3 57 [11] 421 out (_SPI_DATA), a + 422 ;src/esp32.c:89: SPI_DATA = (u8)(data >> 16); + 00000106 FD 7E 02 [19] 423 ld a, 2 (iy) + 00000109 D3 57 [11] 424 out (_SPI_DATA), a + 425 ;src/esp32.c:90: SPI_DATA = (u8)(data >> 24); + 0000010B FD 7E 03 [19] 426 ld a, 3 (iy) + 0000010E D3 57 [11] 427 out (_SPI_DATA), a + 428 ;src/esp32.c:91: SPI_CTRL = SPI_ESP_CS_OFF; + 00000110 3E 03 [ 7] 429 ld a, #0x03 + 00000112 D3 77 [11] 430 out (_SPI_CTRL), a + 431 ;src/esp32.c:92: } + 00000114 E1 [10] 432 pop hl + 00000115 F1 [10] 433 pop af + 00000116 F1 [10] 434 pop af + 00000117 E9 [ 4] 435 jp (hl) + 436 ;src/esp32.c:94: void esp_wr_end() + 437 ; --------------------------------- + 438 ; Function esp_wr_end + 439 ; --------------------------------- + 00000118 440 _esp_wr_end:: + 441 ;src/esp32.c:96: SPI_CTRL = SPI_ESP_CS_ON; + 00000118 3E 13 [ 7] 442 ld a, #0x13 + 0000011A D3 77 [11] 443 out (_SPI_CTRL), a + 444 ;src/esp32.c:97: SPI_DATA = ESP_SPI_CMD_W_END; + 0000011C 3E 07 [ 7] 445 ld a, #0x07 + 0000011E D3 57 [11] 446 out (_SPI_DATA), a + 447 ;src/esp32.c:98: SPI_DATA; // dummy + 00000120 DB 57 [11] 448 in a, (_SPI_DATA) + 449 ;src/esp32.c:99: SPI_CTRL = SPI_ESP_CS_OFF; + 00000122 3E 03 [ 7] 450 ld a, #0x03 + 00000124 D3 77 [11] 451 out (_SPI_CTRL), a + 452 ;src/esp32.c:100: } + 00000126 C9 [10] 453 ret + 454 ;src/esp32.c:102: void esp_send_dma(u16 a, u8 p, u16 l, u16 n) + 455 ; --------------------------------- + 456 ; Function esp_send_dma + 457 ; --------------------------------- + 00000127 458 _esp_send_dma:: + 00000127 7D [ 4] 459 ld a, l + 460 ;src/esp32.c:105: TS_DMASADDRL = (u8)a; + 00000128 01 AF 1A [10] 461 ld bc, #_TS_DMASADDRL + 0000012B ED 79 [12] 462 out (c), a + 463 ;src/esp32.c:106: TS_DMASADDRH = (u8)((u16)a >> 8); + 0000012D 7C [ 4] 464 ld a, h + 0000012E 01 AF 1B [10] 465 ld bc, #_TS_DMASADDRH + 00000131 ED 79 [12] 466 out (c), a + 467 ;src/esp32.c:107: TS_DMASADDRX = p; + 00000133 FD 21 02 00 [14] 468 ld iy, #2 + 00000137 FD 39 [15] 469 add iy, sp + 00000139 FD 7E 00 [19] 470 ld a, 0 (iy) + 0000013C 01 AF 1C [10] 471 ld bc, #_TS_DMASADDRX + 0000013F ED 79 [12] 472 out (c), a + 473 ;src/esp32.c:108: TS_DMALEN = (u8)((l >> 1) - 1); + 00000141 FD 7E 01 [19] 474 ld a, 1 (iy) + 00000144 FD 4E 02 [19] 475 ld c, 2 (iy) + 00000147 FD 23 [10] 476 inc iy + 00000149 CB 39 [ 8] 477 srl c + 0000014B CB 1F [ 8] 478 rr a + 0000014D 3D [ 4] 479 dec a + 0000014E 01 AF 26 [10] 480 ld bc, #_TS_DMALEN + 00000151 ED 79 [12] 481 out (c), a + 482 ;src/esp32.c:109: TS_DMANUM = (u8)(n - 1); + 00000153 FD 7E 02 [19] 483 ld a, 2 (iy) + 00000156 3D [ 4] 484 dec a + 00000157 01 AF 28 [10] 485 ld bc, #_TS_DMANUM + 0000015A ED 79 [12] 486 out (c), a + 487 ;src/esp32.c:111: SPI_CTRL = SPI_ESP_CS_ON; + 0000015C 3E 13 [ 7] 488 ld a, #0x13 + 0000015E D3 77 [11] 489 out (_SPI_CTRL), a + 490 ;src/esp32.c:112: SPI_DATA = ESP_SPI_CMD_WR_DATA; + 00000160 3E 03 [ 7] 491 ld a, #0x03 + 00000162 D3 57 [11] 492 out (_SPI_DATA), a + 493 ;src/esp32.c:113: SPI_DATA; // dummy + 00000164 DB 57 [11] 494 in a, (_SPI_DATA) + 495 ;src/esp32.c:114: SPI_DATA; // dummy + 00000166 DB 57 [11] 496 in a, (_SPI_DATA) + 497 ;src/esp32.c:115: TS_DMACTR = TS_DMA_RAM_SPI; + 00000168 3E 82 [ 7] 498 ld a, #0x82 + 0000016A 01 AF 27 [10] 499 ld bc, #_TS_DMACTR + 0000016D ED 79 [12] 500 out (c), a + 501 ;src/esp32.c:116: while (TS_DMASTATUS & 0x80); + 0000016F 502 00101$: + 0000016F 3E 27 [ 7] 503 ld a, #>(_TS_DMASTATUS) + 00000171 DB AF [11] 504 in a, (#<(_TS_DMASTATUS)) + 00000173 07 [ 4] 505 rlca + 00000174 38 F9 [12] 506 jr c, 00101$ + 507 ;src/esp32.c:117: SPI_CTRL = SPI_ESP_CS_OFF; + 00000176 3E 03 [ 7] 508 ld a, #0x03 + 00000178 D3 77 [11] 509 out (_SPI_CTRL), a + 510 ;src/esp32.c:119: esp_wr_end(); + 0000017A CDr18r01 [17] 511 call _esp_wr_end + 512 ;src/esp32.c:120: esp_wait_busy(100); // 2s - esp32 consuming one DMA'd chunk should be near-instant + 0000017D 21 64 00 [10] 513 ld hl, #0x0064 + 00000180 CDrE5r01 [17] 514 call _esp_wait_busy + 515 ;src/esp32.c:121: } + 00000183 E1 [10] 516 pop hl + 00000184 F1 [10] 517 pop af + 00000185 F1 [10] 518 pop af + 00000186 33 [ 6] 519 inc sp + 00000187 E9 [ 4] 520 jp (hl) + 521 ;src/esp32.c:123: void esp_rd_end() + 522 ; --------------------------------- + 523 ; Function esp_rd_end + 524 ; --------------------------------- + 00000188 525 _esp_rd_end:: + 526 ;src/esp32.c:125: SPI_CTRL = SPI_ESP_CS_ON; + 00000188 3E 13 [ 7] 527 ld a, #0x13 + 0000018A D3 77 [11] 528 out (_SPI_CTRL), a + 529 ;src/esp32.c:126: SPI_DATA = ESP_SPI_CMD_R_END; + 0000018C 3E 08 [ 7] 530 ld a, #0x08 + 0000018E D3 57 [11] 531 out (_SPI_DATA), a + 532 ;src/esp32.c:127: SPI_DATA; // dummy + 00000190 DB 57 [11] 533 in a, (_SPI_DATA) + 534 ;src/esp32.c:128: SPI_CTRL = SPI_ESP_CS_OFF; + 00000192 3E 03 [ 7] 535 ld a, #0x03 + 00000194 D3 77 [11] 536 out (_SPI_CTRL), a + 537 ;src/esp32.c:129: } + 00000196 C9 [10] 538 ret + 539 ;src/esp32.c:139: u8 esp_wait_status(u8 status, u16 max_frames) + 540 ; --------------------------------- + 541 ; Function esp_wait_status + 542 ; --------------------------------- + 00000197 543 _esp_wait_status:: + 00000197 DD E5 [15] 544 push ix + 00000199 DD 21 00 00 [14] 545 ld ix, #0 + 0000019D DD 39 [15] 546 add ix, sp + 0000019F 21 FB FF [10] 547 ld hl, #-5 + 000001A2 39 [11] 548 add hl, sp + 000001A3 F9 [ 6] 549 ld sp, hl + 000001A4 DD 77 FF [19] 550 ld -1 (ix), a + 000001A7 DD 73 FD [19] 551 ld -3 (ix), e + 000001AA DD 72 FE [19] 552 ld -2 (ix), d + 553 ;src/esp32.c:141: u16 start = *(u16*)_TMN; + 000001AD 21 09 60 [10] 554 ld hl, #0x6009 + 000001B0 7E [ 7] 555 ld a, (hl) + 000001B1 DD 77 FB [19] 556 ld -5 (ix), a + 000001B4 23 [ 6] 557 inc hl + 000001B5 7E [ 7] 558 ld a, (hl) + 000001B6 DD 77 FC [19] 559 ld -4 (ix), a + 560 ;src/esp32.c:143: while ((u16)(*(u16*)_TMN - start) < max_frames) + 000001B9 561 00103$: + 000001B9 2A 09 60 [16] 562 ld hl, (#0x6009) + 000001BC 7D [ 4] 563 ld a, l + 000001BD DD 96 FB [19] 564 sub a, -5 (ix) + 000001C0 4F [ 4] 565 ld c, a + 000001C1 7C [ 4] 566 ld a, h + 000001C2 DD 9E FC [19] 567 sbc a, -4 (ix) + 000001C5 47 [ 4] 568 ld b, a + 000001C6 79 [ 4] 569 ld a, c + 000001C7 DD 96 FD [19] 570 sub a, -3 (ix) + 000001CA 78 [ 4] 571 ld a, b + 000001CB DD 9E FE [19] 572 sbc a, -2 (ix) + 000001CE 30 0F [12] 573 jr nc, 00105$ + 574 ;src/esp32.c:145: if (esp_rd_reg8(ESP_REG_STATUS) == status) + 000001D0 3E 01 [ 7] 575 ld a, #0x01 + 000001D2 CDr1Er00 [17] 576 call _esp_rd_reg8 + 000001D5 DD 96 FF [19] 577 sub a, -1 (ix) + 000001D8 20 DF [12] 578 jr nz, 00103$ + 579 ;src/esp32.c:146: return 1; + 000001DA 3E 01 [ 7] 580 ld a, #0x01 + 000001DC C3rE0r01 [10] 581 jp 00106$ + 000001DF 582 00105$: + 583 ;src/esp32.c:149: return 0; + 000001DF AF [ 4] 584 xor a, a + 000001E0 585 00106$: + 586 ;src/esp32.c:150: } + 000001E0 DD F9 [10] 587 ld sp, ix + 000001E2 DD E1 [14] 588 pop ix + 000001E4 C9 [10] 589 ret + 590 ;src/esp32.c:152: u8 esp_wait_busy(u16 max_frames) + 591 ; --------------------------------- + 592 ; Function esp_wait_busy + 593 ; --------------------------------- + 000001E5 594 _esp_wait_busy:: + 000001E5 DD E5 [15] 595 push ix + 000001E7 DD 21 00 00 [14] 596 ld ix, #0 + 000001EB DD 39 [15] 597 add ix, sp + 000001ED F5 [11] 598 push af + 000001EE F5 [11] 599 push af + 000001EF DD 75 FE [19] 600 ld -2 (ix), l + 000001F2 DD 74 FF [19] 601 ld -1 (ix), h + 602 ;src/esp32.c:154: u16 start = *(u16*)_TMN; + 000001F5 21 09 60 [10] 603 ld hl, #0x6009 + 000001F8 7E [ 7] 604 ld a, (hl) + 000001F9 DD 77 FC [19] 605 ld -4 (ix), a + 000001FC 23 [ 6] 606 inc hl + 000001FD 7E [ 7] 607 ld a, (hl) + 000001FE DD 77 FD [19] 608 ld -3 (ix), a + 609 ;src/esp32.c:156: while ((u16)(*(u16*)_TMN - start) < max_frames) + 00000201 610 00103$: + 00000201 2A 09 60 [16] 611 ld hl, (#0x6009) + 00000204 7D [ 4] 612 ld a, l + 00000205 DD 96 FC [19] 613 sub a, -4 (ix) + 00000208 4F [ 4] 614 ld c, a + 00000209 7C [ 4] 615 ld a, h + 0000020A DD 9E FD [19] 616 sbc a, -3 (ix) + 0000020D 47 [ 4] 617 ld b, a + 0000020E 79 [ 4] 618 ld a, c + 0000020F DD 96 FE [19] 619 sub a, -2 (ix) + 00000212 78 [ 4] 620 ld a, b + 00000213 DD 9E FF [19] 621 sbc a, -1 (ix) + 00000216 30 0E [12] 622 jr nc, 00105$ + 623 ;src/esp32.c:158: if (esp_rd_reg8(ESP_REG_STATUS) != ESP_ST_BUSY) + 00000218 3E 01 [ 7] 624 ld a, #0x01 + 0000021A CDr1Er00 [17] 625 call _esp_rd_reg8 + 0000021D FE 02 [ 7] 626 cp a, #0x02 + 0000021F 28 E0 [12] 627 jr z, 00103$ + 628 ;src/esp32.c:159: return 1; + 00000221 3E 01 [ 7] 629 ld a, #0x01 + 00000223 C3r27r02 [10] 630 jp 00106$ + 00000226 631 00105$: + 632 ;src/esp32.c:162: return 0; + 00000226 AF [ 4] 633 xor a, a + 00000227 634 00106$: + 635 ;src/esp32.c:163: } + 00000227 DD F9 [10] 636 ld sp, ix + 00000229 DD E1 [14] 637 pop ix + 0000022B C9 [10] 638 ret + 639 ;src/esp32.c:165: int esp_create_obj(u32 size, u8 type) + 640 ; --------------------------------- + 641 ; Function esp_create_obj + 642 ; --------------------------------- + 0000022C 643 _esp_create_obj:: + 644 ;src/esp32.c:167: esp_wr_reg32(ESP_REG_DATA_SIZE, size); + 0000022C E5 [11] 645 push hl + 0000022D D5 [11] 646 push de + 0000022E 3E 03 [ 7] 647 ld a, #0x03 + 00000230 CDrE8r00 [17] 648 call _esp_wr_reg32 + 649 ;src/esp32.c:168: esp_wr_reg8(ESP_REG_OBJ_TYPE, type); + 00000233 FD 21 02 00 [14] 650 ld iy, #2 + 00000237 FD 39 [15] 651 add iy, sp + 00000239 FD 6E 00 [19] 652 ld l, 0 (iy) + 0000023C 3E 02 [ 7] 653 ld a, #0x02 + 0000023E CDrD1r00 [17] 654 call _esp_wr_reg8 + 655 ;src/esp32.c:169: esp_cmd(ESP_CMD_MAKE_OBJECT); + 00000241 3E E0 [ 7] 656 ld a, #0xe0 + 00000243 CDr05r00 [17] 657 call _esp_cmd + 658 ;src/esp32.c:170: esp_wait_busy(100); // 2s - object allocation should be near-instant + 00000246 21 64 00 [10] 659 ld hl, #0x0064 + 00000249 CDrE5r01 [17] 660 call _esp_wait_busy + 661 ;src/esp32.c:173: return esp_rd_reg8(ESP_REG_OBJ_HANDLE); + 0000024C 3E 0B [ 7] 662 ld a, #0x0b + 0000024E CDr1Er00 [17] 663 call _esp_rd_reg8 + 00000251 5F [ 4] 664 ld e, a + 00000252 16 00 [ 7] 665 ld d, #0x00 + 666 ;src/esp32.c:174: } + 00000254 E1 [10] 667 pop hl + 00000255 33 [ 6] 668 inc sp + 00000256 E9 [ 4] 669 jp (hl) + 670 ;src/main.c:101: bool esp_init() + 671 ; --------------------------------- + 672 ; Function esp_init + 673 ; --------------------------------- + 00000257 674 _esp_init:: + 675 ;src/main.c:103: esp_cmd(ESP_CMD_NOP); + 00000257 AF [ 4] 676 xor a, a + 00000258 CDr05r00 [17] 677 call _esp_cmd + 678 ;src/main.c:104: esp_rd_end(); + 0000025B CDr88r01 [17] 679 call _esp_rd_end + 680 ;src/main.c:105: esp_wr_end(); + 0000025E CDr18r01 [17] 681 call _esp_wr_end + 682 ;src/main.c:109: return true; + 00000261 3E 01 [ 7] 683 ld a, #0x01 + 684 ;src/main.c:110: } + 00000263 C9 [10] 685 ret + 00000264 686 _win_xm: + 00000264 81 687 .db #0x81 ; 129 + 00000265 00 688 .db #0x00 ; 0 + 00000266 19 689 .db #0x19 ; 25 + 00000267 0A 690 .db #0x0a ; 10 + 00000268 28 691 .db #0x28 ; 40 + 00000269 0C 692 .db #0x0c ; 12 + 0000026A 70 693 .db #0x70 ; 112 'p' + 0000026B 00 694 .db #0x00 ; 0 + 0000026C 00 00 695 .dw #0x0000 + 0000026E 00 696 .db #0x00 ; 0 + 0000026F 00 697 .db #0x00 ; 0 + 00000270r88r02 698 .dw __str_0 + 00000272rA2r02 699 .dw __str_1 + 00000274rA2r02 700 .dw __str_1 + 00000276 701 _win_about: + 00000276 01 702 .db #0x01 ; 1 + 00000277 00 703 .db #0x00 ; 0 + 00000278 16 704 .db #0x16 ; 22 + 00000279 0A 705 .db #0x0a ; 10 + 0000027A 24 706 .db #0x24 ; 36 + 0000027B 05 707 .db #0x05 ; 5 + 0000027C 4F 708 .db #0x4f ; 79 'O' + 0000027D 00 709 .db #0x00 ; 0 + 0000027E 00 00 710 .dw #0x0000 + 00000280 00 711 .db #0x00 ; 0 + 00000281 00 712 .db #0x00 ; 0 + 00000282rA3r02 713 .dw __str_2 + 00000284rA2r02 714 .dw __str_1 + 00000286rACr02 715 .dw __str_3 + 00000288 716 __str_0: + 00000288 0E 717 .db 0x0e + 00000289 20 58 4D 2F 58 4D 5A 718 .ascii " XM/XMZ/S3M Player v0.1 " 2F 53 33 4D 20 50 6C - 61 79 65 72 20 - 00000308 00 768 .db 0x00 - 00000309 769 __str_6: - 00000309 0E 770 .db 0x0e - 0000030A 0C 771 .db 0x0c - 0000030B 01 772 .db 0x01 - 0000030C 50 6C 61 79 69 6E 67 773 .ascii "Playing..." - 2E 2E 2E - 00000316 00 774 .db 0x00 - 00000317 775 __str_7: - 00000317 0E 776 .db 0x0e - 00000318 20 41 62 6F 75 74 20 777 .ascii " About " - 0000031F 00 778 .db 0x00 - 00000320 779 __str_8: - 00000320 0E 780 .db 0x0e - 00000321 0C 781 .db 0x0c - 00000322 01 782 .db 0x01 - 00000323 58 4D 20 50 6C 61 79 783 .ascii "XM Player v1.0" - 65 72 20 76 31 2E 30 - 00000331 00 784 .db 0x00 - 785 ;src/main.c:156: bool play_xm() - 786 ; --------------------------------- - 787 ; Function play_xm - 788 ; --------------------------------- - 00000332 789 _play_xm:: - 00000332 DD E5 [15] 790 push ix - 00000334 DD 21 00 00 [14] 791 ld ix, #0 - 00000338 DD 39 [15] 792 add ix, sp - 0000033A 21 EC FF [10] 793 ld hl, #-20 - 0000033D 39 [11] 794 add hl, sp - 0000033E F9 [ 6] 795 ld sp, hl - 796 ;src/main.c:158: esp_cmd(ESP_CMD_TRACK_STOP); - 0000033F 3E A2 [ 7] 797 ld a, #0xa2 - 00000341 CDr0Er00 [17] 798 call _esp_cmd - 799 ;src/main.c:159: esp_wait_busy(10000); - 00000344 11 10 27 [10] 800 ld de, #0x2710 - 00000347 21 00 00 [10] 801 ld hl, #0x0000 - 0000034A CDrDEr01 [17] 802 call _esp_wait_busy - 803 ;src/main.c:160: esp_cmd(ESP_CMD_KILL_OBJECTS); - 0000034D 3E E4 [ 7] 804 ld a, #0xe4 - 0000034F CDr0Er00 [17] 805 call _esp_cmd - 806 ;src/main.c:161: esp_wait_busy(10000); - 00000352 11 10 27 [10] 807 ld de, #0x2710 - 00000355 21 00 00 [10] 808 ld hl, #0x0000 - 00000358 CDrDEr01 [17] 809 call _esp_wait_busy - 810 ;src/main.c:164: switch (file_ext) - 0000035B 3Ar06r10 [13] 811 ld a, (_file_ext) - 0000035E 3D [ 4] 812 dec a - 0000035F 28 0A [12] 813 jr z, 00101$ - 00000361 3Ar06r10 [13] 814 ld a, (_file_ext) - 00000364 D6 02 [ 7] 815 sub a, #0x02 - 00000366 28 08 [12] 816 jr z, 00102$ - 00000368 C3r75r03 [10] 817 jp 00103$ - 818 ;src/main.c:166: case EXT_XMZ: obj_type = OBJ_TYPE_ZIP; break; - 0000036B 819 00101$: - 0000036B 3E 08 [ 7] 820 ld a, #0x08 - 0000036D C3r77r03 [10] 821 jp 00104$ - 822 ;src/main.c:167: case EXT_S3M: obj_type = OBJ_TYPE_S3M; break; - 00000370 823 00102$: - 00000370 3E 0C [ 7] 824 ld a, #0x0c - 00000372 C3r77r03 [10] 825 jp 00104$ - 826 ;src/main.c:168: default: obj_type = OBJ_TYPE_XM; break; - 00000375 827 00103$: - 00000375 3E 05 [ 7] 828 ld a, #0x05 - 829 ;src/main.c:169: } - 00000377 830 00104$: - 831 ;src/main.c:171: xm_handle = esp_create_obj(filesize, obj_type); - 00000377 F5 [11] 832 push af - 00000378 33 [ 6] 833 inc sp - 00000379 ED 5Br02r10 [20] 834 ld de, (_filesize) - 0000037D 2Ar04r10 [16] 835 ld hl, (_filesize + 2) - 00000380 CDr00r02 [17] 836 call _esp_create_obj - 00000383 21r30r10 [10] 837 ld hl, #_xm_handle - 00000386 73 [ 7] 838 ld (hl), e - 839 ;src/main.c:172: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); - 00000387 3E 01 [ 7] 840 ld a, #0x01 - 00000389 CDr27r00 [17] 841 call _esp_rd_reg8 - 0000038C 32r08r10 [13] 842 ld (#_last_esp_status), a - 843 ;src/main.c:173: if (last_esp_status != ESP_ST_READY) - 0000038F 3Ar08r10 [13] 844 ld a, (_last_esp_status) - 00000392 3D [ 4] 845 dec a - 00000393 28 04 [12] 846 jr z, 00106$ - 847 ;src/main.c:174: return false; - 00000395 AF [ 4] 848 xor a, a - 00000396 C3r60r05 [10] 849 jp 00116$ - 00000399 850 00106$: - 851 ;src/main.c:176: u32 sz = filesize; - 00000399 21 0C 00 [10] 852 ld hl, #12 - 0000039C 39 [11] 853 add hl, sp - 0000039D EB [ 4] 854 ex de, hl - 0000039E 21r02r10 [10] 855 ld hl, #_filesize - 000003A1 01 04 00 [10] 856 ld bc, #4 - 000003A4 ED B0 [21] 857 ldir - 858 ;src/main.c:177: u32 offs = 0; - 000003A6 AF [ 4] 859 xor a, a - 000003A7 DD 77 FC [19] 860 ld -4 (ix), a - 000003AA DD 77 FD [19] 861 ld -3 (ix), a - 000003AD DD 77 FE [19] 862 ld -2 (ix), a - 000003B0 DD 77 FF [19] 863 ld -1 (ix), a - 864 ;src/main.c:179: while (sz) - 000003B3 865 00107$: - 000003B3 DD 7E FB [19] 866 ld a, -5 (ix) - 000003B6 DD B6 FA [19] 867 or a, -6 (ix) - 000003B9 DD B6 F9 [19] 868 or a, -7 (ix) - 000003BC DD B6 F8 [19] 869 or a, -8 (ix) - 000003BF CArCFr04 [10] 870 jp z, 00109$ - 871 ;src/main.c:181: u32 s = min(sz, FS_BUF_SIZE); - 000003C2 DD 7E F9 [19] 872 ld a, -7 (ix) - 000003C5 D6 10 [ 7] 873 sub a, #0x10 - 000003C7 DD 7E FA [19] 874 ld a, -6 (ix) - 000003CA DE 00 [ 7] 875 sbc a, #0x00 - 000003CC DD 7E FB [19] 876 ld a, -5 (ix) - 000003CF DE 00 [ 7] 877 sbc a, #0x00 - 000003D1 30 11 [12] 878 jr nc, 00118$ - 000003D3 21 00 00 [10] 879 ld hl, #0 - 000003D6 39 [11] 880 add hl, sp - 000003D7 EB [ 4] 881 ex de, hl - 000003D8 21 0C 00 [10] 882 ld hl, #12 - 000003DB 39 [11] 883 add hl, sp - 000003DC 01 04 00 [10] 884 ld bc, #4 - 000003DF ED B0 [21] 885 ldir - 000003E1 C3rF3r03 [10] 886 jp 00119$ - 000003E4 887 00118$: - 000003E4 DD 36 EC 00 [19] 888 ld -20 (ix), #0x00 - 000003E8 DD 36 ED 10 [19] 889 ld -19 (ix), #0x10 - 000003EC AF [ 4] 890 xor a, a - 000003ED DD 77 EE [19] 891 ld -18 (ix), a - 000003F0 DD 77 EF [19] 892 ld -17 (ix), a - 000003F3 893 00119$: - 000003F3 21 05 00 [10] 894 ld hl, #5 - 000003F6 39 [11] 895 add hl, sp - 000003F7 EB [ 4] 896 ex de, hl - 000003F8 21 00 00 [10] 897 ld hl, #0 - 000003FB 39 [11] 898 add hl, sp - 000003FC 01 04 00 [10] 899 ld bc, #4 - 000003FF ED B0 [21] 900 ldir - 901 ;src/main.c:182: u8 sec = (s + 511) >> 9; - 00000401 DD 7E F1 [19] 902 ld a, -15 (ix) - 00000404 C6 FF [ 7] 903 add a, #0xff - 00000406 DD 7E F2 [19] 904 ld a, -14 (ix) - 00000409 CE 01 [ 7] 905 adc a, #0x01 - 0000040B 47 [ 4] 906 ld b, a - 0000040C 3E 00 [ 7] 907 ld a, #0x00 - 0000040E CE 00 [ 7] 908 adc a, #0x00 - 00000410 5F [ 4] 909 ld e, a - 00000411 3E 00 [ 7] 910 ld a, #0x00 - 00000413 CE 00 [ 7] 911 adc a, #0x00 - 00000415 57 [ 4] 912 ld d, a - 00000416 48 [ 4] 913 ld c, b - 00000417 43 [ 4] 914 ld b, e - 00000418 5A [ 4] 915 ld e, d - 00000419 CB 3B [ 8] 916 srl e - 0000041B CB 18 [ 8] 917 rr b - 0000041D CB 19 [ 8] 918 rr c - 919 ;src/main.c:184: wc_load512((u16)fs_buf, sec); - 0000041F DD 71 F7 [19] 920 ld -9 (ix), c - 00000422 79 [ 4] 921 ld a, c - 00000423 F5 [11] 922 push af - 00000424 33 [ 6] 923 inc sp - 00000425 21r00r00 [10] 924 ld hl, #_fs_buf - 00000428 CDr00r00 [17] 925 call _wc_load512 - 926 ;src/main.c:186: esp_wr_reg32(ESP_REG_DATA_SIZE, s); - 0000042B 21 00 00 [10] 927 ld hl, #0x0 - 0000042E E5 [11] 928 push hl - 0000042F DD 6E F1 [19] 929 ld l, -15 (ix) - 00000432 DD 66 F2 [19] 930 ld h, -14 (ix) - 00000435 E5 [11] 931 push hl - 00000436 3E 03 [ 7] 932 ld a, #0x03 - 00000438 CDrF1r00 [17] 933 call _esp_wr_reg32 - 934 ;src/main.c:187: esp_wr_reg32(ESP_REG_DATA_OFFSET, offs); - 0000043B DD 6E FE [19] 935 ld l, -2 (ix) - 0000043E DD 66 FF [19] 936 ld h, -1 (ix) - 00000441 E5 [11] 937 push hl - 00000442 DD 6E FC [19] 938 ld l, -4 (ix) - 00000445 DD 66 FD [19] 939 ld h, -3 (ix) - 00000448 E5 [11] 940 push hl - 00000449 3E 07 [ 7] 941 ld a, #0x07 - 0000044B CDrF1r00 [17] 942 call _esp_wr_reg32 - 943 ;src/main.c:188: esp_cmd(ESP_CMD_WRITE_OBJECT); - 0000044E 3E E1 [ 7] 944 ld a, #0xe1 - 00000450 CDr0Er00 [17] 945 call _esp_cmd - 946 ;src/main.c:189: esp_wait_status(ESP_ST_DATA_M2S, 2000); - 00000453 21 00 00 [10] 947 ld hl, #0x0000 - 00000456 E5 [11] 948 push hl - 00000457 21 D0 07 [10] 949 ld hl, #0x07d0 - 0000045A E5 [11] 950 push hl - 0000045B 3E 03 [ 7] 951 ld a, #0x03 - 0000045D CDrA3r01 [17] 952 call _esp_wait_status - 00000460 F1 [10] 953 pop af - 00000461 F1 [10] 954 pop af - 955 ;src/main.c:190: esp_send_dma((u16)fs_buf, *(u8*)_PAGE2, 512, sec); - 00000462 DD 7E F7 [19] 956 ld a, -9 (ix) - 00000465 DD 77 F5 [19] 957 ld -11 (ix), a - 00000468 DD 36 F6 00 [19] 958 ld -10 (ix), #0x00 - 0000046C 3A 02 60 [13] 959 ld a, (#0x6002) - 0000046F DD 77 F7 [19] 960 ld -9 (ix), a - 00000472 DD 6E F5 [19] 961 ld l, -11 (ix) - 00000475 26 00 [ 7] 962 ld h, #0x00 - 00000477 E5 [11] 963 push hl - 00000478 21 00 02 [10] 964 ld hl, #0x0200 - 0000047B E5 [11] 965 push hl - 0000047C DD 7E F7 [19] 966 ld a, -9 (ix) - 0000047F F5 [11] 967 push af - 00000480 33 [ 6] 968 inc sp - 00000481 21r00r00 [10] 969 ld hl, #_fs_buf - 00000484 CDr30r01 [17] 970 call _esp_send_dma - 971 ;src/main.c:192: offs += s; - 00000487 DD 5E F1 [19] 972 ld e, -15 (ix) - 0000048A DD 56 F2 [19] 973 ld d, -14 (ix) - 0000048D DD 6E FC [19] 974 ld l, -4 (ix) - 00000490 DD 66 FD [19] 975 ld h, -3 (ix) - 00000493 19 [11] 976 add hl, de - 00000494 DD 75 FC [19] 977 ld -4 (ix), l - 00000497 DD 74 FD [19] 978 ld -3 (ix), h - 0000049A DD 7E FE [19] 979 ld a, -2 (ix) - 0000049D DD 8E F3 [19] 980 adc a, -13 (ix) - 000004A0 DD 77 FE [19] 981 ld -2 (ix), a - 000004A3 30 03 [12] 982 jr nc, 00197$ - 000004A5 DD 34 FF [23] 983 inc -1 (ix) - 000004A8 984 00197$: - 985 ;src/main.c:193: sz -= s; - 000004A8 DD 7E F8 [19] 986 ld a, -8 (ix) - 000004AB DD 96 F1 [19] 987 sub a, -15 (ix) - 000004AE DD 77 F8 [19] 988 ld -8 (ix), a - 000004B1 DD 7E F9 [19] 989 ld a, -7 (ix) - 000004B4 DD 9E F2 [19] 990 sbc a, -14 (ix) - 000004B7 DD 77 F9 [19] 991 ld -7 (ix), a - 000004BA DD 7E FA [19] 992 ld a, -6 (ix) - 000004BD DD 9E F3 [19] 993 sbc a, -13 (ix) - 000004C0 DD 77 FA [19] 994 ld -6 (ix), a - 000004C3 DD 7E FB [19] 995 ld a, -5 (ix) - 000004C6 DD 9E F4 [19] 996 sbc a, -12 (ix) - 000004C9 DD 77 FB [19] 997 ld -5 (ix), a - 000004CC C3rB3r03 [10] 998 jp 00107$ - 000004CF 999 00109$: - 1000 ;src/main.c:196: if (file_ext == EXT_XMZ) - 000004CF 3Ar06r10 [13] 1001 ld a, (_file_ext) - 000004D2 3D [ 4] 1002 dec a - 000004D3 20 3D [12] 1003 jr nz, 00113$ - 1004 ;src/main.c:201: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); - 000004D5 3Ar30r10 [13] 1005 ld a, (_xm_handle) - 000004D8 6F [ 4] 1006 ld l, a - 000004D9 3E 0B [ 7] 1007 ld a, #0x0b - 000004DB CDrDAr00 [17] 1008 call _esp_wr_reg8 - 1009 ;src/main.c:202: esp_wr_reg8(ESP_REG_OBJ_TYPE, OBJ_TYPE_XM); - 000004DE 2E 05 [ 7] 1010 ld l, #0x05 - 000004E0 3E 02 [ 7] 1011 ld a, #0x02 - 000004E2 CDrDAr00 [17] 1012 call _esp_wr_reg8 - 1013 ;src/main.c:203: esp_wr_reg32(ESP_REG_DATA_SIZE, filesize); - 000004E5 2Ar04r10 [16] 1014 ld hl, (_filesize + 2) - 000004E8 E5 [11] 1015 push hl - 000004E9 2Ar02r10 [16] 1016 ld hl, (_filesize) - 000004EC E5 [11] 1017 push hl - 000004ED 3E 03 [ 7] 1018 ld a, #0x03 - 000004EF CDrF1r00 [17] 1019 call _esp_wr_reg32 - 1020 ;src/main.c:204: esp_cmd(ESP_CMD_UNZIP); - 000004F2 3E F2 [ 7] 1021 ld a, #0xf2 - 000004F4 CDr0Er00 [17] 1022 call _esp_cmd - 1023 ;src/main.c:205: esp_wait_busy(10000); - 000004F7 11 10 27 [10] 1024 ld de, #0x2710 - 000004FA 21 00 00 [10] 1025 ld hl, #0x0000 - 000004FD CDrDEr01 [17] 1026 call _esp_wait_busy - 1027 ;src/main.c:207: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); - 00000500 3E 01 [ 7] 1028 ld a, #0x01 - 00000502 CDr27r00 [17] 1029 call _esp_rd_reg8 - 00000505 32r08r10 [13] 1030 ld (#_last_esp_status), a - 1031 ;src/main.c:208: if (last_esp_status != ESP_ST_READY) - 00000508 3Ar08r10 [13] 1032 ld a, (_last_esp_status) - 0000050B 3D [ 4] 1033 dec a - 0000050C 28 04 [12] 1034 jr z, 00113$ - 1035 ;src/main.c:209: return false; - 0000050E AF [ 4] 1036 xor a, a - 0000050F C3r60r05 [10] 1037 jp 00116$ - 00000512 1038 00113$: - 1039 ;src/main.c:212: esp_cmd(ESP_CMD_TRACK_INIT); - 00000512 3E A0 [ 7] 1040 ld a, #0xa0 - 00000514 CDr0Er00 [17] 1041 call _esp_cmd - 1042 ;src/main.c:220: esp_wait_busy(1000000); - 00000517 11 40 42 [10] 1043 ld de, #0x4240 - 0000051A 21 0F 00 [10] 1044 ld hl, #0x000f - 0000051D CDrDEr01 [17] 1045 call _esp_wait_busy - 1046 ;src/main.c:222: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); - 00000520 3E 01 [ 7] 1047 ld a, #0x01 - 00000522 CDr27r00 [17] 1048 call _esp_rd_reg8 - 00000525 32r08r10 [13] 1049 ld (#_last_esp_status), a - 1050 ;src/main.c:223: if (last_esp_status != ESP_ST_READY) - 00000528 3Ar08r10 [13] 1051 ld a, (_last_esp_status) - 0000052B 3D [ 4] 1052 dec a - 0000052C 28 04 [12] 1053 jr z, 00115$ - 1054 ;src/main.c:224: return false; - 0000052E AF [ 4] 1055 xor a, a - 0000052F C3r60r05 [10] 1056 jp 00116$ - 00000532 1057 00115$: - 1058 ;src/main.c:229: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); - 00000532 3Ar30r10 [13] 1059 ld a, (_xm_handle) - 00000535 6F [ 4] 1060 ld l, a - 00000536 3E 0B [ 7] 1061 ld a, #0x0b - 00000538 CDrDAr00 [17] 1062 call _esp_wr_reg8 - 1063 ;src/main.c:230: esp_wr_reg8(ESP_REG_TRACK_MAX_LOOP_COUNT, 1); - 0000053B 2E 01 [ 7] 1064 ld l, #0x01 - 0000053D 3E 3A [ 7] 1065 ld a, #0x3a - 0000053F CDrDAr00 [17] 1066 call _esp_wr_reg8 - 1067 ;src/main.c:231: esp_cmd(ESP_CMD_TRACK_SET_PARAMS); - 00000542 3E A6 [ 7] 1068 ld a, #0xa6 - 00000544 CDr0Er00 [17] 1069 call _esp_cmd - 1070 ;src/main.c:232: esp_wait_busy(10000); - 00000547 11 10 27 [10] 1071 ld de, #0x2710 - 0000054A 21 00 00 [10] 1072 ld hl, #0x0000 - 0000054D CDrDEr01 [17] 1073 call _esp_wait_busy - 1074 ;src/main.c:234: esp_cmd(ESP_CMD_TRACK_PLAY); - 00000550 3E A1 [ 7] 1075 ld a, #0xa1 - 00000552 CDr0Er00 [17] 1076 call _esp_cmd - 1077 ;src/main.c:235: esp_wait_busy(10000); - 00000555 11 10 27 [10] 1078 ld de, #0x2710 - 00000558 21 00 00 [10] 1079 ld hl, #0x0000 - 0000055B CDrDEr01 [17] 1080 call _esp_wait_busy - 1081 ;src/main.c:237: return true; - 0000055E 3E 01 [ 7] 1082 ld a, #0x01 - 00000560 1083 00116$: - 1084 ;src/main.c:238: } - 00000560 DD F9 [10] 1085 ld sp, ix - 00000562 DD E1 [14] 1086 pop ix - 00000564 C9 [10] 1087 ret - 1088 ;src/main.c:241: void wait_esc_key() - 1089 ; --------------------------------- - 1090 ; Function wait_esc_key - 1091 ; --------------------------------- - 00000565 1092 _wait_esc_key:: - 1093 ;src/main.c:243: while (1) - 00000565 1094 00104$: - 1095 ;src/main.c:247: __endasm; - 00000565 76 [ 4] 1096 halt - 1097 ;src/main.c:249: if (wc_key_esc()) - 00000566 CDr00r00 [17] 1098 call _wc_key_esc - 00000569 B7 [ 4] 1099 or a, a - 0000056A 28 F9 [12] 1100 jr z, 00104$ - 1101 ;src/main.c:250: break; - 1102 ;src/main.c:252: } - 0000056C C9 [10] 1103 ret - 1104 ;src/main.c:254: void wait_frames(u8 n) - 1105 ; --------------------------------- - 1106 ; Function wait_frames - 1107 ; --------------------------------- - 0000056D 1108 _wait_frames:: - 0000056D 4F [ 4] 1109 ld c, a - 1110 ;src/main.c:256: while (n--) - 0000056E 1111 00101$: - 0000056E 79 [ 4] 1112 ld a, c - 0000056F 0D [ 4] 1113 dec c - 00000570 B7 [ 4] 1114 or a, a - 00000571 C8 [11] 1115 ret z - 1116 ;src/main.c:260: __endasm; - 00000572 76 [ 4] 1117 halt - 1118 ;src/main.c:262: } - 00000573 C3r6Er05 [10] 1119 jp 00101$ - 1120 ;src/main.c:264: void about() - 1121 ; --------------------------------- - 1122 ; Function about - 1123 ; --------------------------------- - 00000576 1124 _about:: - 1125 ;src/main.c:266: wc_prwow(&win_about); - 00000576 21r83r02 [10] 1126 ld hl, #_win_about - 00000579 CDr00r00 [17] 1127 call _wc_prwow - 1128 ;src/main.c:267: wait_esc_key(); - 0000057C CDr65r05 [17] 1129 call _wait_esc_key - 1130 ;src/main.c:268: wc_rresb(&win_about); - 0000057F 21r83r02 [10] 1131 ld hl, #_win_about - 00000582 CDr00r00 [17] 1132 call _wc_rresb - 1133 ;src/main.c:269: wc_exit(WC_EXIT); - 00000585 AF [ 4] 1134 xor a, a - 1135 ;src/main.c:270: } - 00000586 C3r00r00 [10] 1136 jp _wc_exit - 1137 ;src/main.c:272: void error_esp() - 1138 ; --------------------------------- - 1139 ; Function error_esp - 1140 ; --------------------------------- - 00000589 1141 _error_esp:: - 1142 ;src/main.c:274: wc_prwow(&err_no_esp); - 00000589 21r3Br02 [10] 1143 ld hl, #_err_no_esp - 0000058C CDr00r00 [17] 1144 call _wc_prwow - 1145 ;src/main.c:275: wait_esc_key(); - 0000058F CDr65r05 [17] 1146 call _wait_esc_key - 1147 ;src/main.c:276: wc_rresb(&err_no_esp); - 00000592 21r3Br02 [10] 1148 ld hl, #_err_no_esp - 00000595 CDr00r00 [17] 1149 call _wc_rresb - 1150 ;src/main.c:277: wc_exit(WC_EXIT); - 00000598 AF [ 4] 1151 xor a, a - 1152 ;src/main.c:278: } - 00000599 C3r00r00 [10] 1153 jp _wc_exit - 1154 ;src/main.c:280: void error_oom() - 1155 ; --------------------------------- - 1156 ; Function error_oom - 1157 ; --------------------------------- - 0000059C 1158 _error_oom:: - 1159 ;src/main.c:282: wc_prwow(&err_out_of_mem); - 0000059C 21r4Dr02 [10] 1160 ld hl, #_err_out_of_mem - 0000059F CDr00r00 [17] 1161 call _wc_prwow - 1162 ;src/main.c:283: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance - 000005A2 3E 32 [ 7] 1163 ld a, #0x32 - 000005A4 CDr6Dr05 [17] 1164 call _wait_frames - 1165 ;src/main.c:284: wc_rresb(&err_out_of_mem); - 000005A7 21r4Dr02 [10] 1166 ld hl, #_err_out_of_mem - 000005AA CDr00r00 [17] 1167 call _wc_rresb - 1168 ;src/main.c:285: wc_exit(WC_NEXT_FILE); - 000005AD 3E 02 [ 7] 1169 ld a, #0x02 - 1170 ;src/main.c:286: } - 000005AF C3r00r00 [10] 1171 jp _wc_exit - 1172 ;src/main.c:288: void error_playback() - 1173 ; --------------------------------- - 1174 ; Function error_playback - 1175 ; --------------------------------- - 000005B2 1176 _error_playback:: - 1177 ;src/main.c:290: wc_prwow(&err_playback); - 000005B2 21r5Fr02 [10] 1178 ld hl, #_err_playback - 000005B5 CDr00r00 [17] 1179 call _wc_prwow - 1180 ;src/main.c:291: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance - 000005B8 3E 32 [ 7] 1181 ld a, #0x32 - 000005BA CDr6Dr05 [17] 1182 call _wait_frames - 1183 ;src/main.c:292: wc_rresb(&err_playback); - 000005BD 21r5Fr02 [10] 1184 ld hl, #_err_playback - 000005C0 CDr00r00 [17] 1185 call _wc_rresb - 1186 ;src/main.c:293: wc_exit(WC_NEXT_FILE); - 000005C3 3E 02 [ 7] 1187 ld a, #0x02 - 1188 ;src/main.c:294: } - 000005C5 C3r00r00 [10] 1189 jp _wc_exit - 1190 ;src/main.c:301: void copy_file_name() - 1191 ; --------------------------------- - 1192 ; Function copy_file_name - 1193 ; --------------------------------- - 000005C8 1194 _copy_file_name:: - 1195 ;src/main.c:303: u8 *src = (u8*)p_file_name; - 000005C8 ED 4Br09r10 [20] 1196 ld bc, (_p_file_name) - 1197 ;src/main.c:306: while (src[i] && i < sizeof(file_name) - 1) - 000005CC 1E 00 [ 7] 1198 ld e, #0x00 - 000005CE 1199 00102$: - 000005CE 6B [ 4] 1200 ld l, e - 000005CF 26 00 [ 7] 1201 ld h, #0x00 - 000005D1 09 [11] 1202 add hl, bc - 000005D2 56 [ 7] 1203 ld d, (hl) - 1204 ;src/main.c:308: file_name[i] = src[i]; - 000005D3 3Er0B [ 7] 1205 ld a, #<(_file_name) - 000005D5 83 [ 4] 1206 add a, e - 000005D6 6F [ 4] 1207 ld l, a - 000005D7 3Es10 [ 7] 1208 ld a, #>(_file_name) - 000005D9 CE 00 [ 7] 1209 adc a, #0x00 - 000005DB 67 [ 4] 1210 ld h, a - 1211 ;src/main.c:306: while (src[i] && i < sizeof(file_name) - 1) - 000005DC 7A [ 4] 1212 ld a, d - 000005DD B7 [ 4] 1213 or a, a - 000005DE 28 0A [12] 1214 jr z, 00104$ - 000005E0 7B [ 4] 1215 ld a, e - 000005E1 D6 20 [ 7] 1216 sub a, #0x20 - 000005E3 30 05 [12] 1217 jr nc, 00104$ - 1218 ;src/main.c:308: file_name[i] = src[i]; - 000005E5 72 [ 7] 1219 ld (hl), d - 1220 ;src/main.c:309: i++; - 000005E6 1C [ 4] 1221 inc e - 000005E7 C3rCEr05 [10] 1222 jp 00102$ - 000005EA 1223 00104$: - 1224 ;src/main.c:311: file_name[i] = 0; - 000005EA 36 00 [10] 1225 ld (hl), #0x00 - 1226 ;src/main.c:312: } - 000005EC C9 [10] 1227 ret - 1228 ;src/main.c:320: void xm_draw_static_labels() - 1229 ; --------------------------------- - 1230 ; Function xm_draw_static_labels - 1231 ; --------------------------------- - 000005ED 1232 _xm_draw_static_labels:: - 1233 ;src/main.c:322: wc_prsrw_attr(&win_xm, "File:", ROW_FILE, 1, 5, ATTR_CAPTION); - 000005ED 3E 45 [ 7] 1234 ld a, #0x45 - 000005EF F5 [11] 1235 push af - 000005F0 33 [ 6] 1236 inc sp - 000005F1 21 05 00 [10] 1237 ld hl, #0x0005 - 000005F4 E5 [11] 1238 push hl - 000005F5 21 01 01 [10] 1239 ld hl, #0x101 - 000005F8 E5 [11] 1240 push hl - 000005F9 11r17r06 [10] 1241 ld de, #___str_9 - 000005FC 21r71r02 [10] 1242 ld hl, #_win_xm - 000005FF CDr00r00 [17] 1243 call _wc_prsrw_attr - 1244 ;src/main.c:323: wc_prsrw(&win_xm, file_name, ROW_FILE, 7, strlen(file_name)); - 00000602 21r0Br10 [10] 1245 ld hl, #_file_name - 00000605 CDr00r00 [17] 1246 call _strlen - 00000608 D5 [11] 1247 push de - 00000609 21 01 07 [10] 1248 ld hl, #0x701 - 0000060C E5 [11] 1249 push hl - 0000060D 11r0Br10 [10] 1250 ld de, #_file_name - 00000610 21r71r02 [10] 1251 ld hl, #_win_xm - 00000613 CDr00r00 [17] 1252 call _wc_prsrw - 1253 ;src/main.c:324: } - 00000616 C9 [10] 1254 ret - 00000617 1255 ___str_9: - 00000617 46 69 6C 65 3A 1256 .ascii "File:" - 0000061C 00 1257 .db 0x00 - 1258 ;src/main.c:333: void put_hex2(char *dst, u8 val) - 1259 ; --------------------------------- - 1260 ; Function put_hex2 - 1261 ; --------------------------------- - 0000061D 1262 _put_hex2:: - 0000061D DD E5 [15] 1263 push ix - 0000061F DD 21 00 00 [14] 1264 ld ix, #0 - 00000623 DD 39 [15] 1265 add ix, sp - 00000625 EB [ 4] 1266 ex de, hl - 1267 ;src/main.c:336: dst[0] = hexch[(val >> 4) & 0xF]; - 00000626 01r49r06 [10] 1268 ld bc, #_put_hex2_hexch_10000_106+0 - 00000629 DD 7E 04 [19] 1269 ld a, 4 (ix) - 0000062C 07 [ 4] 1270 rlca - 0000062D 07 [ 4] 1271 rlca - 0000062E 07 [ 4] 1272 rlca - 0000062F 07 [ 4] 1273 rlca - 00000630 E6 0F [ 7] 1274 and a, #0xf - 00000632 6F [ 4] 1275 ld l, a - 00000633 26 00 [ 7] 1276 ld h, #0x00 - 00000635 09 [11] 1277 add hl, bc - 00000636 7E [ 7] 1278 ld a, (hl) - 00000637 12 [ 7] 1279 ld (de), a - 1280 ;src/main.c:337: dst[1] = hexch[val & 0xF]; - 00000638 13 [ 6] 1281 inc de - 00000639 DD 7E 04 [19] 1282 ld a, 4 (ix) - 0000063C E6 0F [ 7] 1283 and a, #0x0f - 0000063E 6F [ 4] 1284 ld l, a - 0000063F 26 00 [ 7] 1285 ld h, #0x00 - 00000641 09 [11] 1286 add hl, bc - 00000642 7E [ 7] 1287 ld a, (hl) - 00000643 12 [ 7] 1288 ld (de), a - 1289 ;src/main.c:338: } - 00000644 DD E1 [14] 1290 pop ix - 00000646 E1 [10] 1291 pop hl - 00000647 33 [ 6] 1292 inc sp - 00000648 E9 [ 4] 1293 jp (hl) - 00000649 1294 _put_hex2_hexch_10000_106: - 00000649 30 31 32 33 34 35 36 1295 .ascii "0123456789ABCDEF" + 61 79 65 72 20 76 30 + 2E 31 20 + 000002A1 00 719 .db 0x00 + 000002A2 720 __str_1: + 000002A2 00 721 .db 0x00 + 000002A3 722 __str_2: + 000002A3 0E 723 .db 0x0e + 000002A4 20 41 62 6F 75 74 20 724 .ascii " About " + 000002AB 00 725 .db 0x00 + 000002AC 726 __str_3: + 000002AC 0E 727 .db 0x0e + 000002AD 0C 728 .db 0x0c + 000002AE 01 729 .db 0x01 + 000002AF 58 4D 20 50 6C 61 79 730 .ascii "XM Player v0.1" + 65 72 20 76 30 2E 31 + 000002BD 00 731 .db 0x00 + 732 ;src/main.c:114: bool play_xm() + 733 ; --------------------------------- + 734 ; Function play_xm + 735 ; --------------------------------- + 000002BE 736 _play_xm:: + 000002BE DD E5 [15] 737 push ix + 000002C0 DD 21 00 00 [14] 738 ld ix, #0 + 000002C4 DD 39 [15] 739 add ix, sp + 000002C6 21 EC FF [10] 740 ld hl, #-20 + 000002C9 39 [11] 741 add hl, sp + 000002CA F9 [ 6] 742 ld sp, hl + 743 ;src/main.c:116: esp_cmd(ESP_CMD_TRACK_STOP); + 000002CB 3E A2 [ 7] 744 ld a, #0xa2 + 000002CD CDr05r00 [17] 745 call _esp_cmd + 746 ;src/main.c:117: esp_wait_busy(100); // 2s - both should be near-instant + 000002D0 21 64 00 [10] 747 ld hl, #0x0064 + 000002D3 CDrE5r01 [17] 748 call _esp_wait_busy + 749 ;src/main.c:118: esp_cmd(ESP_CMD_KILL_OBJECTS); + 000002D6 3E E4 [ 7] 750 ld a, #0xe4 + 000002D8 CDr05r00 [17] 751 call _esp_cmd + 752 ;src/main.c:119: esp_wait_busy(100); + 000002DB 21 64 00 [10] 753 ld hl, #0x0064 + 000002DE CDrE5r01 [17] 754 call _esp_wait_busy + 755 ;src/main.c:122: switch (file_ext) + 000002E1 3Ar06r10 [13] 756 ld a, (_file_ext) + 000002E4 3D [ 4] 757 dec a + 000002E5 28 0A [12] 758 jr z, 00101$ + 000002E7 3Ar06r10 [13] 759 ld a, (_file_ext) + 000002EA D6 02 [ 7] 760 sub a, #0x02 + 000002EC 28 08 [12] 761 jr z, 00102$ + 000002EE C3rFBr02 [10] 762 jp 00103$ + 763 ;src/main.c:124: case EXT_XMZ: obj_type = OBJ_TYPE_ZIP; break; + 000002F1 764 00101$: + 000002F1 3E 08 [ 7] 765 ld a, #0x08 + 000002F3 C3rFDr02 [10] 766 jp 00104$ + 767 ;src/main.c:125: case EXT_S3M: obj_type = OBJ_TYPE_S3M; break; + 000002F6 768 00102$: + 000002F6 3E 0C [ 7] 769 ld a, #0x0c + 000002F8 C3rFDr02 [10] 770 jp 00104$ + 771 ;src/main.c:126: default: obj_type = OBJ_TYPE_XM; break; + 000002FB 772 00103$: + 000002FB 3E 05 [ 7] 773 ld a, #0x05 + 774 ;src/main.c:127: } + 000002FD 775 00104$: + 776 ;src/main.c:129: xm_handle = esp_create_obj(filesize, obj_type); + 000002FD F5 [11] 777 push af + 000002FE 33 [ 6] 778 inc sp + 000002FF ED 5Br02r10 [20] 779 ld de, (_filesize) + 00000303 2Ar04r10 [16] 780 ld hl, (_filesize + 2) + 00000306 CDr2Cr02 [17] 781 call _esp_create_obj + 00000309 21r30r10 [10] 782 ld hl, #_xm_handle + 0000030C 73 [ 7] 783 ld (hl), e + 784 ;src/main.c:130: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); + 0000030D 3E 01 [ 7] 785 ld a, #0x01 + 0000030F CDr1Er00 [17] 786 call _esp_rd_reg8 + 00000312 32r08r10 [13] 787 ld (#_last_esp_status), a + 788 ;src/main.c:131: if (last_esp_status != ESP_ST_READY) + 00000315 3Ar08r10 [13] 789 ld a, (_last_esp_status) + 00000318 3D [ 4] 790 dec a + 00000319 28 04 [12] 791 jr z, 00106$ + 792 ;src/main.c:132: return false; + 0000031B AF [ 4] 793 xor a, a + 0000031C C3rE5r04 [10] 794 jp 00118$ + 0000031F 795 00106$: + 796 ;src/main.c:134: u32 sz = filesize; + 0000031F 21 0C 00 [10] 797 ld hl, #12 + 00000322 39 [11] 798 add hl, sp + 00000323 EB [ 4] 799 ex de, hl + 00000324 21r02r10 [10] 800 ld hl, #_filesize + 00000327 01 04 00 [10] 801 ld bc, #4 + 0000032A ED B0 [21] 802 ldir + 803 ;src/main.c:135: u32 offs = 0; + 0000032C AF [ 4] 804 xor a, a + 0000032D DD 77 FC [19] 805 ld -4 (ix), a + 00000330 DD 77 FD [19] 806 ld -3 (ix), a + 00000333 DD 77 FE [19] 807 ld -2 (ix), a + 00000336 DD 77 FF [19] 808 ld -1 (ix), a + 809 ;src/main.c:137: while (sz) + 00000339 810 00107$: + 00000339 DD 7E FB [19] 811 ld a, -5 (ix) + 0000033C DD B6 FA [19] 812 or a, -6 (ix) + 0000033F DD B6 F9 [19] 813 or a, -7 (ix) + 00000342 DD B6 F8 [19] 814 or a, -8 (ix) + 00000345 CAr4Er04 [10] 815 jp z, 00109$ + 816 ;src/main.c:139: u32 s = min(sz, FS_BUF_SIZE); + 00000348 DD 7E F9 [19] 817 ld a, -7 (ix) + 0000034B D6 10 [ 7] 818 sub a, #0x10 + 0000034D DD 7E FA [19] 819 ld a, -6 (ix) + 00000350 DE 00 [ 7] 820 sbc a, #0x00 + 00000352 DD 7E FB [19] 821 ld a, -5 (ix) + 00000355 DE 00 [ 7] 822 sbc a, #0x00 + 00000357 30 11 [12] 823 jr nc, 00120$ + 00000359 21 00 00 [10] 824 ld hl, #0 + 0000035C 39 [11] 825 add hl, sp + 0000035D EB [ 4] 826 ex de, hl + 0000035E 21 0C 00 [10] 827 ld hl, #12 + 00000361 39 [11] 828 add hl, sp + 00000362 01 04 00 [10] 829 ld bc, #4 + 00000365 ED B0 [21] 830 ldir + 00000367 C3r79r03 [10] 831 jp 00121$ + 0000036A 832 00120$: + 0000036A DD 36 EC 00 [19] 833 ld -20 (ix), #0x00 + 0000036E DD 36 ED 10 [19] 834 ld -19 (ix), #0x10 + 00000372 AF [ 4] 835 xor a, a + 00000373 DD 77 EE [19] 836 ld -18 (ix), a + 00000376 DD 77 EF [19] 837 ld -17 (ix), a + 00000379 838 00121$: + 00000379 21 05 00 [10] 839 ld hl, #5 + 0000037C 39 [11] 840 add hl, sp + 0000037D EB [ 4] 841 ex de, hl + 0000037E 21 00 00 [10] 842 ld hl, #0 + 00000381 39 [11] 843 add hl, sp + 00000382 01 04 00 [10] 844 ld bc, #4 + 00000385 ED B0 [21] 845 ldir + 846 ;src/main.c:140: u8 sec = (s + 511) >> 9; + 00000387 DD 7E F1 [19] 847 ld a, -15 (ix) + 0000038A C6 FF [ 7] 848 add a, #0xff + 0000038C DD 7E F2 [19] 849 ld a, -14 (ix) + 0000038F CE 01 [ 7] 850 adc a, #0x01 + 00000391 47 [ 4] 851 ld b, a + 00000392 3E 00 [ 7] 852 ld a, #0x00 + 00000394 CE 00 [ 7] 853 adc a, #0x00 + 00000396 5F [ 4] 854 ld e, a + 00000397 3E 00 [ 7] 855 ld a, #0x00 + 00000399 CE 00 [ 7] 856 adc a, #0x00 + 0000039B 57 [ 4] 857 ld d, a + 0000039C 48 [ 4] 858 ld c, b + 0000039D 43 [ 4] 859 ld b, e + 0000039E 5A [ 4] 860 ld e, d + 0000039F CB 3B [ 8] 861 srl e + 000003A1 CB 18 [ 8] 862 rr b + 000003A3 CB 19 [ 8] 863 rr c + 864 ;src/main.c:142: wc_load512((u16)fs_buf, sec); + 000003A5 DD 71 F7 [19] 865 ld -9 (ix), c + 000003A8 79 [ 4] 866 ld a, c + 000003A9 F5 [11] 867 push af + 000003AA 33 [ 6] 868 inc sp + 000003AB 21r00r00 [10] 869 ld hl, #_fs_buf + 000003AE CDr00r00 [17] 870 call _wc_load512 + 871 ;src/main.c:144: esp_wr_reg32(ESP_REG_DATA_SIZE, s); + 000003B1 21 00 00 [10] 872 ld hl, #0x0 + 000003B4 E5 [11] 873 push hl + 000003B5 DD 6E F1 [19] 874 ld l, -15 (ix) + 000003B8 DD 66 F2 [19] 875 ld h, -14 (ix) + 000003BB E5 [11] 876 push hl + 000003BC 3E 03 [ 7] 877 ld a, #0x03 + 000003BE CDrE8r00 [17] 878 call _esp_wr_reg32 + 879 ;src/main.c:145: esp_wr_reg32(ESP_REG_DATA_OFFSET, offs); + 000003C1 DD 6E FE [19] 880 ld l, -2 (ix) + 000003C4 DD 66 FF [19] 881 ld h, -1 (ix) + 000003C7 E5 [11] 882 push hl + 000003C8 DD 6E FC [19] 883 ld l, -4 (ix) + 000003CB DD 66 FD [19] 884 ld h, -3 (ix) + 000003CE E5 [11] 885 push hl + 000003CF 3E 07 [ 7] 886 ld a, #0x07 + 000003D1 CDrE8r00 [17] 887 call _esp_wr_reg32 + 888 ;src/main.c:146: esp_cmd(ESP_CMD_WRITE_OBJECT); + 000003D4 3E E1 [ 7] 889 ld a, #0xe1 + 000003D6 CDr05r00 [17] 890 call _esp_cmd + 891 ;src/main.c:147: esp_wait_status(ESP_ST_DATA_M2S, 100); // 2s - near-instant state transition + 000003D9 11 64 00 [10] 892 ld de, #0x0064 + 000003DC 3E 03 [ 7] 893 ld a, #0x03 + 000003DE CDr97r01 [17] 894 call _esp_wait_status + 895 ;src/main.c:148: esp_send_dma((u16)fs_buf, *(u8*)_PAGE2, 512, sec); + 000003E1 DD 7E F7 [19] 896 ld a, -9 (ix) + 000003E4 DD 77 F5 [19] 897 ld -11 (ix), a + 000003E7 DD 36 F6 00 [19] 898 ld -10 (ix), #0x00 + 000003EB 3A 02 60 [13] 899 ld a, (#0x6002) + 000003EE DD 77 F7 [19] 900 ld -9 (ix), a + 000003F1 DD 6E F5 [19] 901 ld l, -11 (ix) + 000003F4 26 00 [ 7] 902 ld h, #0x00 + 000003F6 E5 [11] 903 push hl + 000003F7 21 00 02 [10] 904 ld hl, #0x0200 + 000003FA E5 [11] 905 push hl + 000003FB DD 7E F7 [19] 906 ld a, -9 (ix) + 000003FE F5 [11] 907 push af + 000003FF 33 [ 6] 908 inc sp + 00000400 21r00r00 [10] 909 ld hl, #_fs_buf + 00000403 CDr27r01 [17] 910 call _esp_send_dma + 911 ;src/main.c:150: offs += s; + 00000406 DD 5E F1 [19] 912 ld e, -15 (ix) + 00000409 DD 56 F2 [19] 913 ld d, -14 (ix) + 0000040C DD 6E FC [19] 914 ld l, -4 (ix) + 0000040F DD 66 FD [19] 915 ld h, -3 (ix) + 00000412 19 [11] 916 add hl, de + 00000413 DD 75 FC [19] 917 ld -4 (ix), l + 00000416 DD 74 FD [19] 918 ld -3 (ix), h + 00000419 DD 7E FE [19] 919 ld a, -2 (ix) + 0000041C DD 8E F3 [19] 920 adc a, -13 (ix) + 0000041F DD 77 FE [19] 921 ld -2 (ix), a + 00000422 30 03 [12] 922 jr nc, 00207$ + 00000424 DD 34 FF [23] 923 inc -1 (ix) + 00000427 924 00207$: + 925 ;src/main.c:151: sz -= s; + 00000427 DD 7E F8 [19] 926 ld a, -8 (ix) + 0000042A DD 96 F1 [19] 927 sub a, -15 (ix) + 0000042D DD 77 F8 [19] 928 ld -8 (ix), a + 00000430 DD 7E F9 [19] 929 ld a, -7 (ix) + 00000433 DD 9E F2 [19] 930 sbc a, -14 (ix) + 00000436 DD 77 F9 [19] 931 ld -7 (ix), a + 00000439 DD 7E FA [19] 932 ld a, -6 (ix) + 0000043C DD 9E F3 [19] 933 sbc a, -13 (ix) + 0000043F DD 77 FA [19] 934 ld -6 (ix), a + 00000442 DD 7E FB [19] 935 ld a, -5 (ix) + 00000445 DD 9E F4 [19] 936 sbc a, -12 (ix) + 00000448 DD 77 FB [19] 937 ld -5 (ix), a + 0000044B C3r39r03 [10] 938 jp 00107$ + 0000044E 939 00109$: + 940 ;src/main.c:154: if (file_ext == EXT_XMZ) + 0000044E 3Ar06r10 [13] 941 ld a, (_file_ext) + 00000451 3D [ 4] 942 dec a + 00000452 20 3A [12] 943 jr nz, 00113$ + 944 ;src/main.c:159: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); + 00000454 3Ar30r10 [13] 945 ld a, (_xm_handle) + 00000457 6F [ 4] 946 ld l, a + 00000458 3E 0B [ 7] 947 ld a, #0x0b + 0000045A CDrD1r00 [17] 948 call _esp_wr_reg8 + 949 ;src/main.c:160: esp_wr_reg8(ESP_REG_OBJ_TYPE, OBJ_TYPE_XM); + 0000045D 2E 05 [ 7] 950 ld l, #0x05 + 0000045F 3E 02 [ 7] 951 ld a, #0x02 + 00000461 CDrD1r00 [17] 952 call _esp_wr_reg8 + 953 ;src/main.c:161: esp_wr_reg32(ESP_REG_DATA_SIZE, filesize); + 00000464 2Ar04r10 [16] 954 ld hl, (_filesize + 2) + 00000467 E5 [11] 955 push hl + 00000468 2Ar02r10 [16] 956 ld hl, (_filesize) + 0000046B E5 [11] 957 push hl + 0000046C 3E 03 [ 7] 958 ld a, #0x03 + 0000046E CDrE8r00 [17] 959 call _esp_wr_reg32 + 960 ;src/main.c:162: esp_cmd(ESP_CMD_UNZIP); + 00000471 3E F2 [ 7] 961 ld a, #0xf2 + 00000473 CDr05r00 [17] 962 call _esp_cmd + 963 ;src/main.c:163: esp_wait_busy(250); // 5s - decompression time scales with file size + 00000476 21 FA 00 [10] 964 ld hl, #0x00fa + 00000479 CDrE5r01 [17] 965 call _esp_wait_busy + 966 ;src/main.c:165: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); + 0000047C 3E 01 [ 7] 967 ld a, #0x01 + 0000047E CDr1Er00 [17] 968 call _esp_rd_reg8 + 00000481 32r08r10 [13] 969 ld (#_last_esp_status), a + 970 ;src/main.c:166: if (last_esp_status != ESP_ST_READY) + 00000484 3Ar08r10 [13] 971 ld a, (_last_esp_status) + 00000487 3D [ 4] 972 dec a + 00000488 28 04 [12] 973 jr z, 00113$ + 974 ;src/main.c:167: return false; + 0000048A AF [ 4] 975 xor a, a + 0000048B C3rE5r04 [10] 976 jp 00118$ + 0000048E 977 00113$: + 978 ;src/main.c:170: esp_cmd(ESP_CMD_TRACK_INIT); + 0000048E 3E A0 [ 7] 979 ld a, #0xa0 + 00000490 CDr05r00 [17] 980 call _esp_cmd + 981 ;src/main.c:176: esp_wait_busy(400); + 00000493 21 90 01 [10] 982 ld hl, #0x0190 + 00000496 CDrE5r01 [17] 983 call _esp_wait_busy + 984 ;src/main.c:178: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); + 00000499 3E 01 [ 7] 985 ld a, #0x01 + 0000049B CDr1Er00 [17] 986 call _esp_rd_reg8 + 0000049E 32r08r10 [13] 987 ld (#_last_esp_status), a + 988 ;src/main.c:179: if (last_esp_status != ESP_ST_READY) + 000004A1 3Ar08r10 [13] 989 ld a, (_last_esp_status) + 000004A4 3D [ 4] 990 dec a + 000004A5 28 04 [12] 991 jr z, 00115$ + 992 ;src/main.c:180: return false; + 000004A7 AF [ 4] 993 xor a, a + 000004A8 C3rE5r04 [10] 994 jp 00118$ + 000004AB 995 00115$: + 996 ;src/main.c:185: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); + 000004AB 3Ar30r10 [13] 997 ld a, (_xm_handle) + 000004AE 6F [ 4] 998 ld l, a + 000004AF 3E 0B [ 7] 999 ld a, #0x0b + 000004B1 CDrD1r00 [17] 1000 call _esp_wr_reg8 + 1001 ;src/main.c:186: esp_wr_reg8(ESP_REG_TRACK_MAX_LOOP_COUNT, 1); + 000004B4 2E 01 [ 7] 1002 ld l, #0x01 + 000004B6 3E 3A [ 7] 1003 ld a, #0x3a + 000004B8 CDrD1r00 [17] 1004 call _esp_wr_reg8 + 1005 ;src/main.c:187: esp_cmd(ESP_CMD_TRACK_SET_PARAMS); + 000004BB 3E A6 [ 7] 1006 ld a, #0xa6 + 000004BD CDr05r00 [17] 1007 call _esp_cmd + 1008 ;src/main.c:188: esp_wait_busy(100); // 2s - both should be near-instant + 000004C0 21 64 00 [10] 1009 ld hl, #0x0064 + 000004C3 CDrE5r01 [17] 1010 call _esp_wait_busy + 1011 ;src/main.c:190: esp_cmd(ESP_CMD_TRACK_PLAY); + 000004C6 3E A1 [ 7] 1012 ld a, #0xa1 + 000004C8 CDr05r00 [17] 1013 call _esp_cmd + 1014 ;src/main.c:191: esp_wait_busy(100); + 000004CB 21 64 00 [10] 1015 ld hl, #0x0064 + 000004CE CDrE5r01 [17] 1016 call _esp_wait_busy + 1017 ;src/main.c:193: last_esp_status = esp_rd_reg8(ESP_REG_STATUS); + 000004D1 3E 01 [ 7] 1018 ld a, #0x01 + 000004D3 CDr1Er00 [17] 1019 call _esp_rd_reg8 + 000004D6 32r08r10 [13] 1020 ld (#_last_esp_status), a + 1021 ;src/main.c:194: if (last_esp_status != ESP_ST_READY) + 000004D9 3Ar08r10 [13] 1022 ld a, (_last_esp_status) + 000004DC 3D [ 4] 1023 dec a + 000004DD 28 04 [12] 1024 jr z, 00117$ + 1025 ;src/main.c:195: return false; + 000004DF AF [ 4] 1026 xor a, a + 000004E0 C3rE5r04 [10] 1027 jp 00118$ + 000004E3 1028 00117$: + 1029 ;src/main.c:197: return true; + 000004E3 3E 01 [ 7] 1030 ld a, #0x01 + 000004E5 1031 00118$: + 1032 ;src/main.c:198: } + 000004E5 DD F9 [10] 1033 ld sp, ix + 000004E7 DD E1 [14] 1034 pop ix + 000004E9 C9 [10] 1035 ret + 1036 ;src/main.c:201: void wait_esc_key() + 1037 ; --------------------------------- + 1038 ; Function wait_esc_key + 1039 ; --------------------------------- + 000004EA 1040 _wait_esc_key:: + 1041 ;src/main.c:203: while (1) + 000004EA 1042 00104$: + 1043 ;src/main.c:207: __endasm; + 000004EA 76 [ 4] 1044 halt + 1045 ;src/main.c:209: if (wc_key_esc()) + 000004EB CDr00r00 [17] 1046 call _wc_key_esc + 000004EE B7 [ 4] 1047 or a, a + 000004EF 28 F9 [12] 1048 jr z, 00104$ + 1049 ;src/main.c:210: break; + 1050 ;src/main.c:212: } + 000004F1 C9 [10] 1051 ret + 1052 ;src/main.c:214: void wait_frames(u8 n) + 1053 ; --------------------------------- + 1054 ; Function wait_frames + 1055 ; --------------------------------- + 000004F2 1056 _wait_frames:: + 000004F2 4F [ 4] 1057 ld c, a + 1058 ;src/main.c:216: while (n--) + 000004F3 1059 00101$: + 000004F3 79 [ 4] 1060 ld a, c + 000004F4 0D [ 4] 1061 dec c + 000004F5 B7 [ 4] 1062 or a, a + 000004F6 C8 [11] 1063 ret z + 1064 ;src/main.c:220: __endasm; + 000004F7 76 [ 4] 1065 halt + 1066 ;src/main.c:222: } + 000004F8 C3rF3r04 [10] 1067 jp 00101$ + 1068 ;src/main.c:224: void about() + 1069 ; --------------------------------- + 1070 ; Function about + 1071 ; --------------------------------- + 000004FB 1072 _about:: + 1073 ;src/main.c:226: wc_prwow(&win_about); + 000004FB 21r76r02 [10] 1074 ld hl, #_win_about + 000004FE CDr00r00 [17] 1075 call _wc_prwow + 1076 ;src/main.c:227: wait_esc_key(); + 00000501 CDrEAr04 [17] 1077 call _wait_esc_key + 1078 ;src/main.c:228: wc_rresb(&win_about); + 00000504 21r76r02 [10] 1079 ld hl, #_win_about + 00000507 CDr00r00 [17] 1080 call _wc_rresb + 1081 ;src/main.c:229: wc_exit(WC_EXIT); + 0000050A AF [ 4] 1082 xor a, a + 1083 ;src/main.c:230: } + 0000050B C3r00r00 [10] 1084 jp _wc_exit + 1085 ;src/main.c:235: void unload_and_exit(WC_EXIT_SIGNAL sig) + 1086 ; --------------------------------- + 1087 ; Function unload_and_exit + 1088 ; --------------------------------- + 0000050E 1089 _unload_and_exit:: + 0000050E 3B [ 6] 1090 dec sp + 0000050F FD 21 00 00 [14] 1091 ld iy, #0 + 00000513 FD 39 [15] 1092 add iy, sp + 00000515 FD 77 00 [19] 1093 ld 0 (iy), a + 1094 ;src/main.c:237: esp_cmd(ESP_CMD_TRACK_STOP); + 00000518 3E A2 [ 7] 1095 ld a, #0xa2 + 0000051A CDr05r00 [17] 1096 call _esp_cmd + 1097 ;src/main.c:238: esp_wait_busy(100); // 2s - both should be near-instant + 0000051D 21 64 00 [10] 1098 ld hl, #0x0064 + 00000520 CDrE5r01 [17] 1099 call _esp_wait_busy + 1100 ;src/main.c:239: esp_cmd(ESP_CMD_KILL_OBJECTS); + 00000523 3E E4 [ 7] 1101 ld a, #0xe4 + 00000525 CDr05r00 [17] 1102 call _esp_cmd + 1103 ;src/main.c:240: esp_wait_busy(100); + 00000528 21 64 00 [10] 1104 ld hl, #0x0064 + 0000052B CDrE5r01 [17] 1105 call _esp_wait_busy + 1106 ;src/main.c:241: wc_rresb(&win_xm); + 0000052E 21r64r02 [10] 1107 ld hl, #_win_xm + 00000531 CDr00r00 [17] 1108 call _wc_rresb + 1109 ;src/main.c:242: wc_exit(sig); + 00000534 21 00 00 [10] 1110 ld hl, #0 + 00000537 39 [11] 1111 add hl, sp + 00000538 7E [ 7] 1112 ld a, (hl) + 00000539 33 [ 6] 1113 inc sp + 0000053A C3r00r00 [10] 1114 jp _wc_exit + 1115 ;src/main.c:243: } + 0000053D 33 [ 6] 1116 inc sp + 0000053E C9 [10] 1117 ret + 1118 ;src/main.c:247: void leave_playing_and_exit() + 1119 ; --------------------------------- + 1120 ; Function leave_playing_and_exit + 1121 ; --------------------------------- + 0000053F 1122 _leave_playing_and_exit:: + 1123 ;src/main.c:249: wc_rresb(&win_xm); + 0000053F 21r64r02 [10] 1124 ld hl, #_win_xm + 00000542 CDr00r00 [17] 1125 call _wc_rresb + 1126 ;src/main.c:250: wc_exit(WC_EXIT); + 00000545 AF [ 4] 1127 xor a, a + 1128 ;src/main.c:251: } + 00000546 C3r00r00 [10] 1129 jp _wc_exit + 1130 ;src/main.c:257: void wait_for_manual_exit() + 1131 ; --------------------------------- + 1132 ; Function wait_for_manual_exit + 1133 ; --------------------------------- + 00000549 1134 _wait_for_manual_exit:: + 1135 ;src/main.c:259: while (1) + 00000549 1136 00108$: + 1137 ;src/main.c:263: __endasm; + 00000549 76 [ 4] 1138 halt + 1139 ;src/main.c:265: if (wc_key_pgdn()) + 0000054A CDr00r00 [17] 1140 call _wc_key_pgdn + 0000054D B7 [ 4] 1141 or a, a + 0000054E 28 05 [12] 1142 jr z, 00102$ + 1143 ;src/main.c:266: unload_and_exit(WC_NEXT_FILE); + 00000550 3E 02 [ 7] 1144 ld a, #0x02 + 00000552 CDr0Er05 [17] 1145 call _unload_and_exit + 00000555 1146 00102$: + 1147 ;src/main.c:268: if (wc_key_pgup()) + 00000555 CDr00r00 [17] 1148 call _wc_key_pgup + 00000558 B7 [ 4] 1149 or a, a + 00000559 28 05 [12] 1150 jr z, 00104$ + 1151 ;src/main.c:269: unload_and_exit(WC_PREV_FILE); + 0000055B 3E 04 [ 7] 1152 ld a, #0x04 + 0000055D CDr0Er05 [17] 1153 call _unload_and_exit + 00000560 1154 00104$: + 1155 ;src/main.c:271: if (wc_key_esc()) + 00000560 CDr00r00 [17] 1156 call _wc_key_esc + 00000563 B7 [ 4] 1157 or a, a + 00000564 28 E3 [12] 1158 jr z, 00108$ + 1159 ;src/main.c:272: unload_and_exit(WC_EXIT); + 00000566 AF [ 4] 1160 xor a, a + 00000567 CDr0Er05 [17] 1161 call _unload_and_exit + 1162 ;src/main.c:274: } + 0000056A C3r49r05 [10] 1163 jp 00108$ + 1164 ;src/main.c:280: void error_esp() + 1165 ; --------------------------------- + 1166 ; Function error_esp + 1167 ; --------------------------------- + 0000056D 1168 _error_esp:: + 1169 ;src/main.c:285: xm_set_status_code("No ESP32 found", state_esp); + 0000056D 3Ar00r00 [13] 1170 ld a, (_state_esp) + 00000570 F5 [11] 1171 push af + 00000571 33 [ 6] 1172 inc sp + 00000572 21r85r05 [10] 1173 ld hl, #___str_4 + 00000575 CDr16r07 [17] 1174 call _xm_set_status_code + 1175 ;src/main.c:286: wait_esc_key(); + 00000578 CDrEAr04 [17] 1176 call _wait_esc_key + 1177 ;src/main.c:287: wc_rresb(&win_xm); + 0000057B 21r64r02 [10] 1178 ld hl, #_win_xm + 0000057E CDr00r00 [17] 1179 call _wc_rresb + 1180 ;src/main.c:288: wc_exit(WC_EXIT); + 00000581 AF [ 4] 1181 xor a, a + 1182 ;src/main.c:289: } + 00000582 C3r00r00 [10] 1183 jp _wc_exit + 00000585 1184 ___str_4: + 00000585 4E 6F 20 45 53 50 33 1185 .ascii "No ESP32 found" + 32 20 66 6F 75 6E 64 + 00000593 00 1186 .db 0x00 + 1187 ;src/main.c:299: u8 stop_on_error() + 1188 ; --------------------------------- + 1189 ; Function stop_on_error + 1190 ; --------------------------------- + 00000594 1191 _stop_on_error:: + 1192 ;src/main.c:301: return wc_prm_pl(1) == 2; + 00000594 3E 01 [ 7] 1193 ld a, #0x01 + 00000596 CDr00r00 [17] 1194 call _wc_prm_pl + 00000599 FE 02 [ 7] 1195 cp a, #0x02 + 0000059B 3E 01 [ 7] 1196 ld a, #0x01 + 0000059D C8 [11] 1197 ret z + 0000059E AF [ 4] 1198 xor a, a + 1199 ;src/main.c:302: } + 0000059F C9 [10] 1200 ret + 1201 ;src/main.c:304: void error_oom() + 1202 ; --------------------------------- + 1203 ; Function error_oom + 1204 ; --------------------------------- + 000005A0 1205 _error_oom:: + 1206 ;src/main.c:306: xm_set_status_code("File too large", last_esp_status); + 000005A0 3Ar08r10 [13] 1207 ld a, (_last_esp_status) + 000005A3 F5 [11] 1208 push af + 000005A4 33 [ 6] 1209 inc sp + 000005A5 21rC4r05 [10] 1210 ld hl, #___str_5 + 000005A8 CDr16r07 [17] 1211 call _xm_set_status_code + 1212 ;src/main.c:308: if (stop_on_error()) + 000005AB CDr94r05 [17] 1213 call _stop_on_error + 000005AE B7 [ 4] 1214 or a, a + 000005AF 28 03 [12] 1215 jr z, 00102$ + 1216 ;src/main.c:309: wait_for_manual_exit(); + 000005B1 CDr49r05 [17] 1217 call _wait_for_manual_exit + 000005B4 1218 00102$: + 1219 ;src/main.c:311: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance + 000005B4 3E 32 [ 7] 1220 ld a, #0x32 + 000005B6 CDrF2r04 [17] 1221 call _wait_frames + 1222 ;src/main.c:312: wc_rresb(&win_xm); + 000005B9 21r64r02 [10] 1223 ld hl, #_win_xm + 000005BC CDr00r00 [17] 1224 call _wc_rresb + 1225 ;src/main.c:313: wc_exit(WC_NEXT_FILE); + 000005BF 3E 02 [ 7] 1226 ld a, #0x02 + 1227 ;src/main.c:314: } + 000005C1 C3r00r00 [10] 1228 jp _wc_exit + 000005C4 1229 ___str_5: + 000005C4 46 69 6C 65 20 74 6F 1230 .ascii "File too large" + 6F 20 6C 61 72 67 65 + 000005D2 00 1231 .db 0x00 + 1232 ;src/main.c:316: void error_playback() + 1233 ; --------------------------------- + 1234 ; Function error_playback + 1235 ; --------------------------------- + 000005D3 1236 _error_playback:: + 1237 ;src/main.c:318: xm_set_status_code("Playback error", last_esp_status); + 000005D3 3Ar08r10 [13] 1238 ld a, (_last_esp_status) + 000005D6 F5 [11] 1239 push af + 000005D7 33 [ 6] 1240 inc sp + 000005D8 21rF7r05 [10] 1241 ld hl, #___str_6 + 000005DB CDr16r07 [17] 1242 call _xm_set_status_code + 1243 ;src/main.c:320: if (stop_on_error()) + 000005DE CDr94r05 [17] 1244 call _stop_on_error + 000005E1 B7 [ 4] 1245 or a, a + 000005E2 28 03 [12] 1246 jr z, 00102$ + 1247 ;src/main.c:321: wait_for_manual_exit(); + 000005E4 CDr49r05 [17] 1248 call _wait_for_manual_exit + 000005E7 1249 00102$: + 1250 ;src/main.c:323: wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance + 000005E7 3E 32 [ 7] 1251 ld a, #0x32 + 000005E9 CDrF2r04 [17] 1252 call _wait_frames + 1253 ;src/main.c:324: wc_rresb(&win_xm); + 000005EC 21r64r02 [10] 1254 ld hl, #_win_xm + 000005EF CDr00r00 [17] 1255 call _wc_rresb + 1256 ;src/main.c:325: wc_exit(WC_NEXT_FILE); + 000005F2 3E 02 [ 7] 1257 ld a, #0x02 + 1258 ;src/main.c:326: } + 000005F4 C3r00r00 [10] 1259 jp _wc_exit + 000005F7 1260 ___str_6: + 000005F7 50 6C 61 79 62 61 63 1261 .ascii "Playback error" + 6B 20 65 72 72 6F 72 + 00000605 00 1262 .db 0x00 + 1263 ;src/main.c:333: void copy_file_name() + 1264 ; --------------------------------- + 1265 ; Function copy_file_name + 1266 ; --------------------------------- + 00000606 1267 _copy_file_name:: + 1268 ;src/main.c:335: u8 *src = (u8*)p_file_name; + 00000606 ED 4Br09r10 [20] 1269 ld bc, (_p_file_name) + 1270 ;src/main.c:338: while (src[i] && i < sizeof(file_name) - 1) + 0000060A 1E 00 [ 7] 1271 ld e, #0x00 + 0000060C 1272 00102$: + 0000060C 6B [ 4] 1273 ld l, e + 0000060D 26 00 [ 7] 1274 ld h, #0x00 + 0000060F 09 [11] 1275 add hl, bc + 00000610 56 [ 7] 1276 ld d, (hl) + 1277 ;src/main.c:340: file_name[i] = src[i]; + 00000611 3Er0B [ 7] 1278 ld a, #<(_file_name) + 00000613 83 [ 4] 1279 add a, e + 00000614 6F [ 4] 1280 ld l, a + 00000615 3Es10 [ 7] 1281 ld a, #>(_file_name) + 00000617 CE 00 [ 7] 1282 adc a, #0x00 + 00000619 67 [ 4] 1283 ld h, a + 1284 ;src/main.c:338: while (src[i] && i < sizeof(file_name) - 1) + 0000061A 7A [ 4] 1285 ld a, d + 0000061B B7 [ 4] 1286 or a, a + 0000061C 28 0A [12] 1287 jr z, 00104$ + 0000061E 7B [ 4] 1288 ld a, e + 0000061F D6 20 [ 7] 1289 sub a, #0x20 + 00000621 30 05 [12] 1290 jr nc, 00104$ + 1291 ;src/main.c:340: file_name[i] = src[i]; + 00000623 72 [ 7] 1292 ld (hl), d + 1293 ;src/main.c:341: i++; + 00000624 1C [ 4] 1294 inc e + 00000625 C3r0Cr06 [10] 1295 jp 00102$ + 00000628 1296 00104$: + 1297 ;src/main.c:343: file_name[i] = 0; + 00000628 36 00 [10] 1298 ld (hl), #0x00 + 1299 ;src/main.c:344: } + 0000062A C9 [10] 1300 ret + 1301 ;src/main.c:377: void xm_draw_static_labels() + 1302 ; --------------------------------- + 1303 ; Function xm_draw_static_labels + 1304 ; --------------------------------- + 0000062B 1305 _xm_draw_static_labels:: + 1306 ;src/main.c:379: wc_prsrw(&win_xm, "File:", ROW_FILE, 1, 5); + 0000062B 21 05 00 [10] 1307 ld hl, #0x0005 + 0000062E E5 [11] 1308 push hl + 0000062F 21 02 01 [10] 1309 ld hl, #0x102 + 00000632 E5 [11] 1310 push hl + 00000633 11r77r06 [10] 1311 ld de, #___str_7 + 00000636 21r64r02 [10] 1312 ld hl, #_win_xm + 00000639 CDr00r00 [17] 1313 call _wc_prsrw + 1314 ;src/main.c:380: wc_prsrw_attr(&win_xm, file_name, ROW_FILE, 7, strlen(file_name), ATTR_VALUE); + 0000063C 21r0Br10 [10] 1315 ld hl, #_file_name + 0000063F CDr00r00 [17] 1316 call _strlen + 00000642 3E 71 [ 7] 1317 ld a, #0x71 + 00000644 F5 [11] 1318 push af + 00000645 33 [ 6] 1319 inc sp + 00000646 D5 [11] 1320 push de + 00000647 21 02 07 [10] 1321 ld hl, #0x702 + 0000064A E5 [11] 1322 push hl + 0000064B 11r0Br10 [10] 1323 ld de, #_file_name + 0000064E 21r64r02 [10] 1324 ld hl, #_win_xm + 00000651 CDr00r00 [17] 1325 call _wc_prsrw_attr + 1326 ;src/main.c:381: wc_prsrw(&win_xm, "Status:", ROW_STATUS, 1, 7); + 00000654 21 07 00 [10] 1327 ld hl, #0x0007 + 00000657 E5 [11] 1328 push hl + 00000658 21 03 01 [10] 1329 ld hl, #0x103 + 0000065B E5 [11] 1330 push hl + 0000065C 11r7Dr06 [10] 1331 ld de, #___str_8 + 0000065F 21r64r02 [10] 1332 ld hl, #_win_xm + 00000662 CDr00r00 [17] 1333 call _wc_prsrw + 1334 ;src/main.c:384: wc_prsrw(&win_xm, HINT_TEXT, ROW_HINT, 2, sizeof(HINT_TEXT) - 1); + 00000665 21 24 00 [10] 1335 ld hl, #0x0024 + 00000668 E5 [11] 1336 push hl + 00000669 21 0A 02 [10] 1337 ld hl, #0x20a + 0000066C E5 [11] 1338 push hl + 0000066D 11r85r06 [10] 1339 ld de, #___str_9 + 00000670 21r64r02 [10] 1340 ld hl, #_win_xm + 00000673 CDr00r00 [17] 1341 call _wc_prsrw + 1342 ;src/main.c:385: } + 00000676 C9 [10] 1343 ret + 00000677 1344 ___str_7: + 00000677 46 69 6C 65 3A 1345 .ascii "File:" + 0000067C 00 1346 .db 0x00 + 0000067D 1347 ___str_8: + 0000067D 53 74 61 74 75 73 3A 1348 .ascii "Status:" + 00000684 00 1349 .db 0x00 + 00000685 1350 ___str_9: + 00000685 50 67 55 70 2F 50 67 1351 .ascii "PgUp/PgDn:Track Esc:Stop Space:Leave" + 44 6E 3A 54 72 61 63 + 6B 20 45 73 63 3A 53 + 74 6F 70 20 53 70 61 + 63 65 3A 4C 65 61 76 + 65 + 000006A9 00 1352 .db 0x00 + 1353 ;src/main.c:391: void xm_set_status_attr(const char *msg, u8 attr) + 1354 ; --------------------------------- + 1355 ; Function xm_set_status_attr + 1356 ; --------------------------------- + 000006AA 1357 _xm_set_status_attr:: + 000006AA DD E5 [15] 1358 push ix + 000006AC DD 21 00 00 [14] 1359 ld ix, #0 + 000006B0 DD 39 [15] 1360 add ix, sp + 000006B2 F5 [11] 1361 push af + 1362 ;src/main.c:395: while (msg[i] && i < STATUS_VALUE_WIDTH) + 000006B3 1E 00 [ 7] 1363 ld e, #0x00 + 000006B5 1364 00102$: + 000006B5 7B [ 4] 1365 ld a, e + 000006B6 85 [ 4] 1366 add a, l + 000006B7 4F [ 4] 1367 ld c, a + 000006B8 3E 00 [ 7] 1368 ld a, #0x00 + 000006BA 8C [ 4] 1369 adc a, h + 000006BB 47 [ 4] 1370 ld b, a + 000006BC 0A [ 7] 1371 ld a, (bc) + 000006BD 4F [ 4] 1372 ld c, a + 000006BE B7 [ 4] 1373 or a, a + 000006BF 28 1F [12] 1374 jr z, 00119$ + 000006C1 7B [ 4] 1375 ld a, e + 000006C2 D6 18 [ 7] 1376 sub a, #0x18 + 000006C4 30 1A [12] 1377 jr nc, 00119$ + 1378 ;src/main.c:397: status_buf[i] = msg[i]; + 000006C6 3Er32 [ 7] 1379 ld a, #<(_status_buf) + 000006C8 83 [ 4] 1380 add a, e + 000006C9 DD 77 FE [19] 1381 ld -2 (ix), a + 000006CC 3Es10 [ 7] 1382 ld a, #>(_status_buf) + 000006CE CE 00 [ 7] 1383 adc a, #0x00 + 000006D0 DD 77 FF [19] 1384 ld -1 (ix), a + 000006D3 E5 [11] 1385 push hl + 000006D4 DD 6E FE [19] 1386 ld l, -2 (ix) + 000006D7 DD 66 FF [19] 1387 ld h, -1 (ix) + 000006DA 71 [ 7] 1388 ld (hl), c + 000006DB E1 [10] 1389 pop hl + 1390 ;src/main.c:398: i++; + 000006DC 1C [ 4] 1391 inc e + 000006DD C3rB5r06 [10] 1392 jp 00102$ + 1393 ;src/main.c:400: while (i < STATUS_VALUE_WIDTH) + 000006E0 1394 00119$: + 000006E0 1395 00105$: + 000006E0 7B [ 4] 1396 ld a, e + 000006E1 D6 18 [ 7] 1397 sub a, #0x18 + 000006E3 30 0C [12] 1398 jr nc, 00107$ + 1399 ;src/main.c:401: status_buf[i++] = ' '; + 000006E5 21r32r10 [10] 1400 ld hl, #_status_buf + 000006E8 16 00 [ 7] 1401 ld d, #0x00 + 000006EA 19 [11] 1402 add hl, de + 000006EB 1C [ 4] 1403 inc e + 000006EC 36 20 [10] 1404 ld (hl), #0x20 + 000006EE C3rE0r06 [10] 1405 jp 00105$ + 000006F1 1406 00107$: + 1407 ;src/main.c:403: wc_prsrw_attr(&win_xm, status_buf, ROW_STATUS, STATUS_VALUE_X, STATUS_VALUE_WIDTH, attr); + 000006F1 21r64r02 [10] 1408 ld hl, #_win_xm + 000006F4 DD 7E 04 [19] 1409 ld a, 4 (ix) + 000006F7 F5 [11] 1410 push af + 000006F8 33 [ 6] 1411 inc sp + 000006F9 11 18 00 [10] 1412 ld de, #0x0018 + 000006FC D5 [11] 1413 push de + 000006FD 11 03 09 [10] 1414 ld de, #0x903 + 00000700 D5 [11] 1415 push de + 00000701 11r32r10 [10] 1416 ld de, #_status_buf + 00000704 CDr00r00 [17] 1417 call _wc_prsrw_attr + 1418 ;src/main.c:404: } + 00000707 DD F9 [10] 1419 ld sp, ix + 00000709 DD E1 [14] 1420 pop ix + 0000070B E1 [10] 1421 pop hl + 0000070C 33 [ 6] 1422 inc sp + 0000070D E9 [ 4] 1423 jp (hl) + 1424 ;src/main.c:406: void xm_set_status(const char *msg) + 1425 ; --------------------------------- + 1426 ; Function xm_set_status + 1427 ; --------------------------------- + 0000070E 1428 _xm_set_status:: + 1429 ;src/main.c:408: xm_set_status_attr(msg, ATTR_VALUE); + 0000070E 3E 71 [ 7] 1430 ld a, #0x71 + 00000710 F5 [11] 1431 push af + 00000711 33 [ 6] 1432 inc sp + 00000712 CDrAAr06 [17] 1433 call _xm_set_status_attr + 1434 ;src/main.c:409: } + 00000715 C9 [10] 1435 ret + 1436 ;src/main.c:416: void xm_set_status_code(const char *msg, u8 code) + 1437 ; --------------------------------- + 1438 ; Function xm_set_status_code + 1439 ; --------------------------------- + 00000716 1440 _xm_set_status_code:: + 00000716 DD E5 [15] 1441 push ix + 00000718 DD 21 00 00 [14] 1442 ld ix, #0 + 0000071C DD 39 [15] 1443 add ix, sp + 0000071E 3B [ 6] 1444 dec sp + 0000071F EB [ 4] 1445 ex de, hl + 1446 ;src/main.c:421: while (msg[i] && i < sizeof(status_code_buf) - 7) + 00000720 0E 00 [ 7] 1447 ld c, #0x00 + 00000722 1448 00102$: + 00000722 69 [ 4] 1449 ld l, c + 00000723 26 00 [ 7] 1450 ld h, #0x00 + 00000725 19 [11] 1451 add hl, de + 00000726 46 [ 7] 1452 ld b, (hl) + 1453 ;src/main.c:423: status_code_buf[i] = msg[i]; + 00000727 3Er4A [ 7] 1454 ld a, #<(_status_code_buf) + 00000729 81 [ 4] 1455 add a, c + 0000072A 6F [ 4] 1456 ld l, a + 0000072B 3Es10 [ 7] 1457 ld a, #>(_status_code_buf) + 0000072D CE 00 [ 7] 1458 adc a, #0x00 + 0000072F 67 [ 4] 1459 ld h, a + 1460 ;src/main.c:424: i++; + 00000730 79 [ 4] 1461 ld a, c + 00000731 3C [ 4] 1462 inc a + 00000732 DD 77 FF [19] 1463 ld -1 (ix), a + 1464 ;src/main.c:421: while (msg[i] && i < sizeof(status_code_buf) - 7) + 00000735 78 [ 4] 1465 ld a, b + 00000736 B7 [ 4] 1466 or a, a + 00000737 28 0C [12] 1467 jr z, 00104$ + 00000739 79 [ 4] 1468 ld a, c + 0000073A D6 11 [ 7] 1469 sub a, #0x11 + 0000073C 30 07 [12] 1470 jr nc, 00104$ + 1471 ;src/main.c:423: status_code_buf[i] = msg[i]; + 0000073E 70 [ 7] 1472 ld (hl), b + 1473 ;src/main.c:424: i++; + 0000073F DD 4E FF [19] 1474 ld c, -1 (ix) + 00000742 C3r22r07 [10] 1475 jp 00102$ + 00000745 1476 00104$: + 1477 ;src/main.c:427: status_code_buf[i++] = ' '; + 00000745 DD 4E FF [19] 1478 ld c, -1 (ix) + 00000748 36 20 [10] 1479 ld (hl), #0x20 + 1480 ;src/main.c:428: status_code_buf[i++] = '('; + 0000074A 69 [ 4] 1481 ld l, c + 0000074B 0C [ 4] 1482 inc c + 0000074C 26 00 [ 7] 1483 ld h, #0x00 + 0000074E 11r4Ar10 [10] 1484 ld de, #_status_code_buf + 00000751 19 [11] 1485 add hl, de + 00000752 36 28 [10] 1486 ld (hl), #0x28 + 1487 ;src/main.c:429: status_code_buf[i++] = '0'; + 00000754 69 [ 4] 1488 ld l, c + 00000755 0C [ 4] 1489 inc c + 00000756 26 00 [ 7] 1490 ld h, #0x00 + 00000758 11r4Ar10 [10] 1491 ld de, #_status_code_buf + 0000075B 19 [11] 1492 add hl, de + 0000075C 36 30 [10] 1493 ld (hl), #0x30 + 1494 ;src/main.c:430: status_code_buf[i++] = 'x'; + 0000075E 69 [ 4] 1495 ld l, c + 0000075F 0C [ 4] 1496 inc c + 00000760 26 00 [ 7] 1497 ld h, #0x00 + 00000762 11r4Ar10 [10] 1498 ld de, #_status_code_buf + 00000765 19 [11] 1499 add hl, de + 00000766 36 78 [10] 1500 ld (hl), #0x78 + 1501 ;src/main.c:431: status_code_buf[i++] = hexch[(code >> 4) & 0xF]; + 00000768 69 [ 4] 1502 ld l, c + 00000769 0C [ 4] 1503 inc c + 0000076A 26 00 [ 7] 1504 ld h, #0x00 + 0000076C 11r4Ar10 [10] 1505 ld de, #_status_code_buf + 0000076F 19 [11] 1506 add hl, de + 00000770 DD 7E 04 [19] 1507 ld a, 4 (ix) + 00000773 07 [ 4] 1508 rlca + 00000774 07 [ 4] 1509 rlca + 00000775 07 [ 4] 1510 rlca + 00000776 07 [ 4] 1511 rlca + 00000777 E6 0F [ 7] 1512 and a, #0xf + 00000779 C6rBD [ 7] 1513 add a, #<(_xm_set_status_code_hexch_10000_129) + 0000077B 5F [ 4] 1514 ld e, a + 0000077C 3E 00 [ 7] 1515 ld a, #0x00 + 0000077E CEs07 [ 7] 1516 adc a, #>(_xm_set_status_code_hexch_10000_129) + 00000780 57 [ 4] 1517 ld d, a + 00000781 1A [ 7] 1518 ld a, (de) + 00000782 77 [ 7] 1519 ld (hl), a + 1520 ;src/main.c:432: status_code_buf[i++] = hexch[code & 0xF]; + 00000783 69 [ 4] 1521 ld l, c + 00000784 0C [ 4] 1522 inc c + 00000785 26 00 [ 7] 1523 ld h, #0x00 + 00000787 11r4Ar10 [10] 1524 ld de, #_status_code_buf + 0000078A 19 [11] 1525 add hl, de + 0000078B DD 7E 04 [19] 1526 ld a, 4 (ix) + 0000078E E6 0F [ 7] 1527 and a, #0x0f + 00000790 C6rBD [ 7] 1528 add a, #<(_xm_set_status_code_hexch_10000_129) + 00000792 5F [ 4] 1529 ld e, a + 00000793 3E 00 [ 7] 1530 ld a, #0x00 + 00000795 CEs07 [ 7] 1531 adc a, #>(_xm_set_status_code_hexch_10000_129) + 00000797 57 [ 4] 1532 ld d, a + 00000798 1A [ 7] 1533 ld a, (de) + 00000799 77 [ 7] 1534 ld (hl), a + 1535 ;src/main.c:433: status_code_buf[i++] = ')'; + 0000079A 69 [ 4] 1536 ld l, c + 0000079B 0C [ 4] 1537 inc c + 0000079C 26 00 [ 7] 1538 ld h, #0x00 + 0000079E 11r4Ar10 [10] 1539 ld de, #_status_code_buf + 000007A1 19 [11] 1540 add hl, de + 000007A2 36 29 [10] 1541 ld (hl), #0x29 + 1542 ;src/main.c:434: status_code_buf[i] = 0; + 000007A4 69 [ 4] 1543 ld l, c + 000007A5 26 00 [ 7] 1544 ld h, #0x00 + 000007A7 11r4Ar10 [10] 1545 ld de, #_status_code_buf + 000007AA 19 [11] 1546 add hl, de + 000007AB 36 00 [10] 1547 ld (hl), #0x00 + 1548 ;src/main.c:436: xm_set_status_attr(status_code_buf, ATTR_ERROR); + 000007AD 3E 72 [ 7] 1549 ld a, #0x72 + 000007AF F5 [11] 1550 push af + 000007B0 33 [ 6] 1551 inc sp + 000007B1 21r4Ar10 [10] 1552 ld hl, #_status_code_buf + 000007B4 CDrAAr06 [17] 1553 call _xm_set_status_attr + 1554 ;src/main.c:437: } + 000007B7 33 [ 6] 1555 inc sp + 000007B8 DD E1 [14] 1556 pop ix + 000007BA E1 [10] 1557 pop hl + 000007BB 33 [ 6] 1558 inc sp + 000007BC E9 [ 4] 1559 jp (hl) + 000007BD 1560 _xm_set_status_code_hexch_10000_129: + 000007BD 30 31 32 33 34 35 36 1561 .ascii "0123456789ABCDEF" 37 38 39 41 42 43 44 45 46 - 00000659 00 1296 .db 0x00 - 1297 ;src/main.c:340: void put_dec3(char *dst, u16 val) - 1298 ; --------------------------------- - 1299 ; Function put_dec3 - 1300 ; --------------------------------- - 0000065A 1301 _put_dec3:: - 0000065A DD E5 [15] 1302 push ix - 0000065C DD 21 00 00 [14] 1303 ld ix, #0 - 00000660 DD 39 [15] 1304 add ix, sp - 00000662 F5 [11] 1305 push af - 00000663 4D [ 4] 1306 ld c, l - 00000664 44 [ 4] 1307 ld b, h - 1308 ;src/main.c:342: dst[0] = '0' + (val / 100) % 10; - 00000665 E1 [10] 1309 pop hl - 00000666 D5 [11] 1310 push de - 00000667 C5 [11] 1311 push bc - 00000668 11 64 00 [10] 1312 ld de, #0x0064 - 0000066B DD 6E FE [19] 1313 ld l, -2 (ix) - 0000066E DD 66 FF [19] 1314 ld h, -1 (ix) - 00000671 CDr00r00 [17] 1315 call __divuint - 00000674 EB [ 4] 1316 ex de, hl - 00000675 11 0A 00 [10] 1317 ld de, #0x000a - 00000678 CDr00r00 [17] 1318 call __moduint - 0000067B C1 [10] 1319 pop bc - 0000067C 7B [ 4] 1320 ld a, e - 0000067D C6 30 [ 7] 1321 add a, #0x30 - 0000067F 02 [ 7] 1322 ld (bc), a - 1323 ;src/main.c:343: dst[1] = '0' + (val / 10) % 10; - 00000680 69 [ 4] 1324 ld l, c - 00000681 60 [ 4] 1325 ld h, b - 00000682 23 [ 6] 1326 inc hl - 00000683 E5 [11] 1327 push hl - 00000684 C5 [11] 1328 push bc - 00000685 11 0A 00 [10] 1329 ld de, #0x000a - 00000688 DD 6E FE [19] 1330 ld l, -2 (ix) - 0000068B DD 66 FF [19] 1331 ld h, -1 (ix) - 0000068E CDr00r00 [17] 1332 call __divuint - 00000691 EB [ 4] 1333 ex de, hl - 00000692 11 0A 00 [10] 1334 ld de, #0x000a - 00000695 CDr00r00 [17] 1335 call __moduint - 00000698 C1 [10] 1336 pop bc - 00000699 E1 [10] 1337 pop hl - 0000069A 7B [ 4] 1338 ld a, e - 0000069B C6 30 [ 7] 1339 add a, #0x30 - 0000069D 77 [ 7] 1340 ld (hl), a - 1341 ;src/main.c:344: dst[2] = '0' + val % 10; - 0000069E 03 [ 6] 1342 inc bc - 0000069F 03 [ 6] 1343 inc bc - 000006A0 C5 [11] 1344 push bc - 000006A1 11 0A 00 [10] 1345 ld de, #0x000a - 000006A4 DD 6E FE [19] 1346 ld l, -2 (ix) - 000006A7 DD 66 FF [19] 1347 ld h, -1 (ix) - 000006AA CDr00r00 [17] 1348 call __moduint - 000006AD C1 [10] 1349 pop bc - 000006AE 7B [ 4] 1350 ld a, e - 000006AF C6 30 [ 7] 1351 add a, #0x30 - 000006B1 02 [ 7] 1352 ld (bc), a - 1353 ;src/main.c:345: } - 000006B2 DD F9 [10] 1354 ld sp, ix - 000006B4 DD E1 [14] 1355 pop ix - 000006B6 C9 [10] 1356 ret - 1357 ;src/main.c:347: void put_time(char *dst, u32 sec) - 1358 ; --------------------------------- - 1359 ; Function put_time - 1360 ; --------------------------------- - 000006B7 1361 _put_time:: - 000006B7 DD E5 [15] 1362 push ix - 000006B9 DD 21 00 00 [14] 1363 ld ix, #0 - 000006BD DD 39 [15] 1364 add ix, sp - 000006BF E5 [11] 1365 push hl - 1366 ;src/main.c:349: u8 m = (sec / 60) % 100; - 000006C0 21 00 00 [10] 1367 ld hl, #0x0000 - 000006C3 E5 [11] 1368 push hl - 000006C4 2E 3C [ 7] 1369 ld l, #0x3c - 000006C6 E5 [11] 1370 push hl - 000006C7 DD 5E 04 [19] 1371 ld e, 4 (ix) - 000006CA DD 56 05 [19] 1372 ld d, 5 (ix) - 000006CD DD 6E 06 [19] 1373 ld l, 6 (ix) - 000006D0 DD 66 07 [19] 1374 ld h, 7 (ix) - 000006D3 CDr00r00 [17] 1375 call __divulong - 000006D6 F1 [10] 1376 pop af - 000006D7 F1 [10] 1377 pop af - 000006D8 01 00 00 [10] 1378 ld bc, #0x0000 - 000006DB C5 [11] 1379 push bc - 000006DC 0E 64 [ 7] 1380 ld c, #0x64 - 000006DE C5 [11] 1381 push bc - 000006DF CDr00r00 [17] 1382 call __modulong - 000006E2 F1 [10] 1383 pop af - 000006E3 F1 [10] 1384 pop af - 000006E4 4B [ 4] 1385 ld c, e - 1386 ;src/main.c:350: u8 s = sec % 60; - 000006E5 C5 [11] 1387 push bc - 000006E6 21 00 00 [10] 1388 ld hl, #0x0000 - 000006E9 E5 [11] 1389 push hl - 000006EA 2E 3C [ 7] 1390 ld l, #0x3c - 000006EC E5 [11] 1391 push hl - 000006ED DD 5E 04 [19] 1392 ld e, 4 (ix) - 000006F0 DD 56 05 [19] 1393 ld d, 5 (ix) - 000006F3 DD 6E 06 [19] 1394 ld l, 6 (ix) - 000006F6 DD 66 07 [19] 1395 ld h, 7 (ix) - 000006F9 CDr00r00 [17] 1396 call __modulong - 000006FC F1 [10] 1397 pop af - 000006FD F1 [10] 1398 pop af - 000006FE C1 [10] 1399 pop bc - 1400 ;src/main.c:352: dst[0] = '0' + (m / 10) % 10; - 000006FF 51 [ 4] 1401 ld d, c - 00000700 D5 [11] 1402 push de - 00000701 2E 0A [ 7] 1403 ld l, #0x0a - 00000703 7A [ 4] 1404 ld a, d - 00000704 CDr00r00 [17] 1405 call __divuchar - 00000707 7B [ 4] 1406 ld a, e - 00000708 2E 0A [ 7] 1407 ld l, #0x0a - 0000070A CDr00r00 [17] 1408 call __moduchar - 0000070D 7B [ 4] 1409 ld a, e - 0000070E D1 [10] 1410 pop de - 0000070F C6 30 [ 7] 1411 add a, #0x30 - 00000711 E1 [10] 1412 pop hl - 00000712 E5 [11] 1413 push hl - 00000713 77 [ 7] 1414 ld (hl), a - 1415 ;src/main.c:353: dst[1] = '0' + m % 10; - 00000714 C1 [10] 1416 pop bc - 00000715 C5 [11] 1417 push bc - 00000716 03 [ 6] 1418 inc bc - 00000717 C5 [11] 1419 push bc - 00000718 D5 [11] 1420 push de - 00000719 2E 0A [ 7] 1421 ld l, #0x0a - 0000071B 7A [ 4] 1422 ld a, d - 0000071C CDr00r00 [17] 1423 call __moduchar - 0000071F 7B [ 4] 1424 ld a, e - 00000720 D1 [10] 1425 pop de - 00000721 C1 [10] 1426 pop bc - 00000722 C6 30 [ 7] 1427 add a, #0x30 - 00000724 02 [ 7] 1428 ld (bc), a - 1429 ;src/main.c:354: dst[2] = ':'; - 00000725 E1 [10] 1430 pop hl - 00000726 E5 [11] 1431 push hl - 00000727 23 [ 6] 1432 inc hl - 00000728 23 [ 6] 1433 inc hl - 00000729 36 3A [10] 1434 ld (hl), #0x3a - 1435 ;src/main.c:355: dst[3] = '0' + (s / 10) % 10; - 0000072B C1 [10] 1436 pop bc - 0000072C C5 [11] 1437 push bc - 0000072D 03 [ 6] 1438 inc bc - 0000072E 03 [ 6] 1439 inc bc - 0000072F 03 [ 6] 1440 inc bc - 00000730 C5 [11] 1441 push bc - 00000731 D5 [11] 1442 push de - 00000732 2E 0A [ 7] 1443 ld l, #0x0a - 00000734 7B [ 4] 1444 ld a, e - 00000735 CDr00r00 [17] 1445 call __divuchar - 00000738 7B [ 4] 1446 ld a, e - 00000739 2E 0A [ 7] 1447 ld l, #0x0a - 0000073B CDr00r00 [17] 1448 call __moduchar - 0000073E 7B [ 4] 1449 ld a, e - 0000073F D1 [10] 1450 pop de - 00000740 C1 [10] 1451 pop bc - 00000741 C6 30 [ 7] 1452 add a, #0x30 - 00000743 02 [ 7] 1453 ld (bc), a - 1454 ;src/main.c:356: dst[4] = '0' + s % 10; - 00000744 DD 7E FE [19] 1455 ld a, -2 (ix) - 00000747 C6 04 [ 7] 1456 add a, #0x04 - 00000749 4F [ 4] 1457 ld c, a - 0000074A DD 7E FF [19] 1458 ld a, -1 (ix) - 0000074D CE 00 [ 7] 1459 adc a, #0x00 - 0000074F 47 [ 4] 1460 ld b, a - 00000750 C5 [11] 1461 push bc - 00000751 2E 0A [ 7] 1462 ld l, #0x0a - 00000753 7B [ 4] 1463 ld a, e - 00000754 CDr00r00 [17] 1464 call __moduchar - 00000757 7B [ 4] 1465 ld a, e - 00000758 C1 [10] 1466 pop bc - 00000759 C6 30 [ 7] 1467 add a, #0x30 - 0000075B 02 [ 7] 1468 ld (bc), a - 1469 ;src/main.c:357: } - 0000075C DD F9 [10] 1470 ld sp, ix - 0000075E DD E1 [14] 1471 pop ix - 00000760 E1 [10] 1472 pop hl - 00000761 F1 [10] 1473 pop af - 00000762 F1 [10] 1474 pop af - 00000763 E9 [ 4] 1475 jp (hl) - 1476 ;src/main.c:359: void xm_draw_stats_labels() - 1477 ; --------------------------------- - 1478 ; Function xm_draw_stats_labels - 1479 ; --------------------------------- - 00000764 1480 _xm_draw_stats_labels:: - 1481 ;src/main.c:361: wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); - 00000764 21 09 00 [10] 1482 ld hl, #0x0009 - 00000767 E5 [11] 1483 push hl - 00000768 21 03 01 [10] 1484 ld hl, #0x103 - 0000076B E5 [11] 1485 push hl - 0000076C 11rBAr07 [10] 1486 ld de, #___str_11 - 0000076F 21r71r02 [10] 1487 ld hl, #_win_xm - 00000772 CDr00r00 [17] 1488 call _wc_prsrw - 1489 ;src/main.c:362: wc_prsrw(&win_xm, " Row:#", ROW_STATS, 12, 7); - 00000775 21 07 00 [10] 1490 ld hl, #0x0007 - 00000778 E5 [11] 1491 push hl - 00000779 21 03 0C [10] 1492 ld hl, #0xc03 - 0000077C E5 [11] 1493 push hl - 0000077D 11rC4r07 [10] 1494 ld de, #___str_12 - 00000780 21r71r02 [10] 1495 ld hl, #_win_xm - 00000783 CDr00r00 [17] 1496 call _wc_prsrw - 1497 ;src/main.c:363: wc_prsrw(&win_xm, " BPM:", ROW_STATS, 21, 6); - 00000786 21 06 00 [10] 1498 ld hl, #0x0006 - 00000789 E5 [11] 1499 push hl - 0000078A 21 03 15 [10] 1500 ld hl, #0x1503 - 0000078D E5 [11] 1501 push hl - 0000078E 11rCCr07 [10] 1502 ld de, #___str_13 - 00000791 21r71r02 [10] 1503 ld hl, #_win_xm - 00000794 CDr00r00 [17] 1504 call _wc_prsrw - 1505 ;src/main.c:365: wc_prsrw(&win_xm, "Time:", ROW_TIME, 1, 5); - 00000797 21 05 00 [10] 1506 ld hl, #0x0005 - 0000079A E5 [11] 1507 push hl - 0000079B 21 05 01 [10] 1508 ld hl, #0x105 - 0000079E E5 [11] 1509 push hl - 0000079F 11rD3r07 [10] 1510 ld de, #___str_14 - 000007A2 21r71r02 [10] 1511 ld hl, #_win_xm - 000007A5 CDr00r00 [17] 1512 call _wc_prsrw - 1513 ;src/main.c:366: wc_prsrw(&win_xm, " / ", ROW_TIME, 12, 3); - 000007A8 21 03 00 [10] 1514 ld hl, #0x0003 - 000007AB E5 [11] 1515 push hl - 000007AC 21 05 0C [10] 1516 ld hl, #0xc05 - 000007AF E5 [11] 1517 push hl - 000007B0 11rD9r07 [10] 1518 ld de, #___str_15 - 000007B3 21r71r02 [10] 1519 ld hl, #_win_xm - 000007B6 CDr00r00 [17] 1520 call _wc_prsrw - 1521 ;src/main.c:367: } - 000007B9 C9 [10] 1522 ret - 000007BA 1523 ___str_11: - 000007BA 50 61 74 74 65 72 6E 1524 .ascii "Pattern:#" + 000007CD 00 1562 .db 0x00 + 1563 ;src/main.c:450: void put_hex2(char *dst, u8 val) + 1564 ; --------------------------------- + 1565 ; Function put_hex2 + 1566 ; --------------------------------- + 000007CE 1567 _put_hex2:: + 000007CE DD E5 [15] 1568 push ix + 000007D0 DD 21 00 00 [14] 1569 ld ix, #0 + 000007D4 DD 39 [15] 1570 add ix, sp + 000007D6 EB [ 4] 1571 ex de, hl + 1572 ;src/main.c:453: dst[0] = hexch[(val >> 4) & 0xF]; + 000007D7 01rFAr07 [10] 1573 ld bc, #_put_hex2_hexch_10000_132+0 + 000007DA DD 7E 04 [19] 1574 ld a, 4 (ix) + 000007DD 07 [ 4] 1575 rlca + 000007DE 07 [ 4] 1576 rlca + 000007DF 07 [ 4] 1577 rlca + 000007E0 07 [ 4] 1578 rlca + 000007E1 E6 0F [ 7] 1579 and a, #0xf + 000007E3 6F [ 4] 1580 ld l, a + 000007E4 26 00 [ 7] 1581 ld h, #0x00 + 000007E6 09 [11] 1582 add hl, bc + 000007E7 7E [ 7] 1583 ld a, (hl) + 000007E8 12 [ 7] 1584 ld (de), a + 1585 ;src/main.c:454: dst[1] = hexch[val & 0xF]; + 000007E9 13 [ 6] 1586 inc de + 000007EA DD 7E 04 [19] 1587 ld a, 4 (ix) + 000007ED E6 0F [ 7] 1588 and a, #0x0f + 000007EF 6F [ 4] 1589 ld l, a + 000007F0 26 00 [ 7] 1590 ld h, #0x00 + 000007F2 09 [11] 1591 add hl, bc + 000007F3 7E [ 7] 1592 ld a, (hl) + 000007F4 12 [ 7] 1593 ld (de), a + 1594 ;src/main.c:455: } + 000007F5 DD E1 [14] 1595 pop ix + 000007F7 E1 [10] 1596 pop hl + 000007F8 33 [ 6] 1597 inc sp + 000007F9 E9 [ 4] 1598 jp (hl) + 000007FA 1599 _put_hex2_hexch_10000_132: + 000007FA 30 31 32 33 34 35 36 1600 .ascii "0123456789ABCDEF" + 37 38 39 41 42 43 44 + 45 46 + 0000080A 00 1601 .db 0x00 + 1602 ;src/main.c:457: void put_dec3(char *dst, u16 val) + 1603 ; --------------------------------- + 1604 ; Function put_dec3 + 1605 ; --------------------------------- + 0000080B 1606 _put_dec3:: + 0000080B DD E5 [15] 1607 push ix + 0000080D DD 21 00 00 [14] 1608 ld ix, #0 + 00000811 DD 39 [15] 1609 add ix, sp + 00000813 F5 [11] 1610 push af + 00000814 4D [ 4] 1611 ld c, l + 00000815 44 [ 4] 1612 ld b, h + 1613 ;src/main.c:459: dst[0] = '0' + (val / 100) % 10; + 00000816 E1 [10] 1614 pop hl + 00000817 D5 [11] 1615 push de + 00000818 C5 [11] 1616 push bc + 00000819 11 64 00 [10] 1617 ld de, #0x0064 + 0000081C DD 6E FE [19] 1618 ld l, -2 (ix) + 0000081F DD 66 FF [19] 1619 ld h, -1 (ix) + 00000822 CDr00r00 [17] 1620 call __divuint + 00000825 EB [ 4] 1621 ex de, hl + 00000826 11 0A 00 [10] 1622 ld de, #0x000a + 00000829 CDr00r00 [17] 1623 call __moduint + 0000082C C1 [10] 1624 pop bc + 0000082D 7B [ 4] 1625 ld a, e + 0000082E C6 30 [ 7] 1626 add a, #0x30 + 00000830 02 [ 7] 1627 ld (bc), a + 1628 ;src/main.c:460: dst[1] = '0' + (val / 10) % 10; + 00000831 69 [ 4] 1629 ld l, c + 00000832 60 [ 4] 1630 ld h, b + 00000833 23 [ 6] 1631 inc hl + 00000834 E5 [11] 1632 push hl + 00000835 C5 [11] 1633 push bc + 00000836 11 0A 00 [10] 1634 ld de, #0x000a + 00000839 DD 6E FE [19] 1635 ld l, -2 (ix) + 0000083C DD 66 FF [19] 1636 ld h, -1 (ix) + 0000083F CDr00r00 [17] 1637 call __divuint + 00000842 EB [ 4] 1638 ex de, hl + 00000843 11 0A 00 [10] 1639 ld de, #0x000a + 00000846 CDr00r00 [17] 1640 call __moduint + 00000849 C1 [10] 1641 pop bc + 0000084A E1 [10] 1642 pop hl + 0000084B 7B [ 4] 1643 ld a, e + 0000084C C6 30 [ 7] 1644 add a, #0x30 + 0000084E 77 [ 7] 1645 ld (hl), a + 1646 ;src/main.c:461: dst[2] = '0' + val % 10; + 0000084F 03 [ 6] 1647 inc bc + 00000850 03 [ 6] 1648 inc bc + 00000851 C5 [11] 1649 push bc + 00000852 11 0A 00 [10] 1650 ld de, #0x000a + 00000855 DD 6E FE [19] 1651 ld l, -2 (ix) + 00000858 DD 66 FF [19] 1652 ld h, -1 (ix) + 0000085B CDr00r00 [17] 1653 call __moduint + 0000085E C1 [10] 1654 pop bc + 0000085F 7B [ 4] 1655 ld a, e + 00000860 C6 30 [ 7] 1656 add a, #0x30 + 00000862 02 [ 7] 1657 ld (bc), a + 1658 ;src/main.c:462: } + 00000863 DD F9 [10] 1659 ld sp, ix + 00000865 DD E1 [14] 1660 pop ix + 00000867 C9 [10] 1661 ret + 1662 ;src/main.c:464: void put_time(char *dst, u32 sec) + 1663 ; --------------------------------- + 1664 ; Function put_time + 1665 ; --------------------------------- + 00000868 1666 _put_time:: + 00000868 DD E5 [15] 1667 push ix + 0000086A DD 21 00 00 [14] 1668 ld ix, #0 + 0000086E DD 39 [15] 1669 add ix, sp + 00000870 E5 [11] 1670 push hl + 1671 ;src/main.c:466: u8 m = (sec / 60) % 100; + 00000871 21 00 00 [10] 1672 ld hl, #0x0000 + 00000874 E5 [11] 1673 push hl + 00000875 2E 3C [ 7] 1674 ld l, #0x3c + 00000877 E5 [11] 1675 push hl + 00000878 DD 5E 04 [19] 1676 ld e, 4 (ix) + 0000087B DD 56 05 [19] 1677 ld d, 5 (ix) + 0000087E DD 6E 06 [19] 1678 ld l, 6 (ix) + 00000881 DD 66 07 [19] 1679 ld h, 7 (ix) + 00000884 CDr00r00 [17] 1680 call __divulong + 00000887 F1 [10] 1681 pop af + 00000888 F1 [10] 1682 pop af + 00000889 01 00 00 [10] 1683 ld bc, #0x0000 + 0000088C C5 [11] 1684 push bc + 0000088D 0E 64 [ 7] 1685 ld c, #0x64 + 0000088F C5 [11] 1686 push bc + 00000890 CDr00r00 [17] 1687 call __modulong + 00000893 F1 [10] 1688 pop af + 00000894 F1 [10] 1689 pop af + 00000895 4B [ 4] 1690 ld c, e + 1691 ;src/main.c:467: u8 s = sec % 60; + 00000896 C5 [11] 1692 push bc + 00000897 21 00 00 [10] 1693 ld hl, #0x0000 + 0000089A E5 [11] 1694 push hl + 0000089B 2E 3C [ 7] 1695 ld l, #0x3c + 0000089D E5 [11] 1696 push hl + 0000089E DD 5E 04 [19] 1697 ld e, 4 (ix) + 000008A1 DD 56 05 [19] 1698 ld d, 5 (ix) + 000008A4 DD 6E 06 [19] 1699 ld l, 6 (ix) + 000008A7 DD 66 07 [19] 1700 ld h, 7 (ix) + 000008AA CDr00r00 [17] 1701 call __modulong + 000008AD F1 [10] 1702 pop af + 000008AE F1 [10] 1703 pop af + 000008AF C1 [10] 1704 pop bc + 1705 ;src/main.c:469: dst[0] = '0' + (m / 10) % 10; + 000008B0 51 [ 4] 1706 ld d, c + 000008B1 D5 [11] 1707 push de + 000008B2 2E 0A [ 7] 1708 ld l, #0x0a + 000008B4 7A [ 4] 1709 ld a, d + 000008B5 CDr00r00 [17] 1710 call __divuchar + 000008B8 7B [ 4] 1711 ld a, e + 000008B9 2E 0A [ 7] 1712 ld l, #0x0a + 000008BB CDr00r00 [17] 1713 call __moduchar + 000008BE 7B [ 4] 1714 ld a, e + 000008BF D1 [10] 1715 pop de + 000008C0 C6 30 [ 7] 1716 add a, #0x30 + 000008C2 E1 [10] 1717 pop hl + 000008C3 E5 [11] 1718 push hl + 000008C4 77 [ 7] 1719 ld (hl), a + 1720 ;src/main.c:470: dst[1] = '0' + m % 10; + 000008C5 C1 [10] 1721 pop bc + 000008C6 C5 [11] 1722 push bc + 000008C7 03 [ 6] 1723 inc bc + 000008C8 C5 [11] 1724 push bc + 000008C9 D5 [11] 1725 push de + 000008CA 2E 0A [ 7] 1726 ld l, #0x0a + 000008CC 7A [ 4] 1727 ld a, d + 000008CD CDr00r00 [17] 1728 call __moduchar + 000008D0 7B [ 4] 1729 ld a, e + 000008D1 D1 [10] 1730 pop de + 000008D2 C1 [10] 1731 pop bc + 000008D3 C6 30 [ 7] 1732 add a, #0x30 + 000008D5 02 [ 7] 1733 ld (bc), a + 1734 ;src/main.c:471: dst[2] = ':'; + 000008D6 E1 [10] 1735 pop hl + 000008D7 E5 [11] 1736 push hl + 000008D8 23 [ 6] 1737 inc hl + 000008D9 23 [ 6] 1738 inc hl + 000008DA 36 3A [10] 1739 ld (hl), #0x3a + 1740 ;src/main.c:472: dst[3] = '0' + (s / 10) % 10; + 000008DC C1 [10] 1741 pop bc + 000008DD C5 [11] 1742 push bc + 000008DE 03 [ 6] 1743 inc bc + 000008DF 03 [ 6] 1744 inc bc + 000008E0 03 [ 6] 1745 inc bc + 000008E1 C5 [11] 1746 push bc + 000008E2 D5 [11] 1747 push de + 000008E3 2E 0A [ 7] 1748 ld l, #0x0a + 000008E5 7B [ 4] 1749 ld a, e + 000008E6 CDr00r00 [17] 1750 call __divuchar + 000008E9 7B [ 4] 1751 ld a, e + 000008EA 2E 0A [ 7] 1752 ld l, #0x0a + 000008EC CDr00r00 [17] 1753 call __moduchar + 000008EF 7B [ 4] 1754 ld a, e + 000008F0 D1 [10] 1755 pop de + 000008F1 C1 [10] 1756 pop bc + 000008F2 C6 30 [ 7] 1757 add a, #0x30 + 000008F4 02 [ 7] 1758 ld (bc), a + 1759 ;src/main.c:473: dst[4] = '0' + s % 10; + 000008F5 DD 7E FE [19] 1760 ld a, -2 (ix) + 000008F8 C6 04 [ 7] 1761 add a, #0x04 + 000008FA 4F [ 4] 1762 ld c, a + 000008FB DD 7E FF [19] 1763 ld a, -1 (ix) + 000008FE CE 00 [ 7] 1764 adc a, #0x00 + 00000900 47 [ 4] 1765 ld b, a + 00000901 C5 [11] 1766 push bc + 00000902 2E 0A [ 7] 1767 ld l, #0x0a + 00000904 7B [ 4] 1768 ld a, e + 00000905 CDr00r00 [17] 1769 call __moduchar + 00000908 7B [ 4] 1770 ld a, e + 00000909 C1 [10] 1771 pop bc + 0000090A C6 30 [ 7] 1772 add a, #0x30 + 0000090C 02 [ 7] 1773 ld (bc), a + 1774 ;src/main.c:474: } + 0000090D DD F9 [10] 1775 ld sp, ix + 0000090F DD E1 [14] 1776 pop ix + 00000911 E1 [10] 1777 pop hl + 00000912 F1 [10] 1778 pop af + 00000913 F1 [10] 1779 pop af + 00000914 E9 [ 4] 1780 jp (hl) + 1781 ;src/main.c:503: void xm_draw_stats_labels() + 1782 ; --------------------------------- + 1783 ; Function xm_draw_stats_labels + 1784 ; --------------------------------- + 00000915 1785 _xm_draw_stats_labels:: + 1786 ;src/main.c:507: wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); + 00000915 21 09 00 [10] 1787 ld hl, #0x0009 + 00000918 E5 [11] 1788 push hl + 00000919 21 04 01 [10] 1789 ld hl, #0x104 + 0000091C E5 [11] 1790 push hl + 0000091D 11rB4r09 [10] 1791 ld de, #___str_12 + 00000920 21r64r02 [10] 1792 ld hl, #_win_xm + 00000923 CDr00r00 [17] 1793 call _wc_prsrw + 1794 ;src/main.c:508: wc_prsrw(&win_xm, " Row:#", ROW_STATS, 12, 7); + 00000926 21 07 00 [10] 1795 ld hl, #0x0007 + 00000929 E5 [11] 1796 push hl + 0000092A 21 04 0C [10] 1797 ld hl, #0xc04 + 0000092D E5 [11] 1798 push hl + 0000092E 11rBEr09 [10] 1799 ld de, #___str_13 + 00000931 21r64r02 [10] 1800 ld hl, #_win_xm + 00000934 CDr00r00 [17] 1801 call _wc_prsrw + 1802 ;src/main.c:509: wc_prsrw(&win_xm, " BPM:", ROW_STATS, 21, 6); + 00000937 21 06 00 [10] 1803 ld hl, #0x0006 + 0000093A E5 [11] 1804 push hl + 0000093B 21 04 15 [10] 1805 ld hl, #0x1504 + 0000093E E5 [11] 1806 push hl + 0000093F 11rC6r09 [10] 1807 ld de, #___str_14 + 00000942 21r64r02 [10] 1808 ld hl, #_win_xm + 00000945 CDr00r00 [17] 1809 call _wc_prsrw + 1810 ;src/main.c:511: wc_prsrw(&win_xm, "Time:", ROW_TIME, 1, 5); + 00000948 21 05 00 [10] 1811 ld hl, #0x0005 + 0000094B E5 [11] 1812 push hl + 0000094C 21 06 01 [10] 1813 ld hl, #0x106 + 0000094F E5 [11] 1814 push hl + 00000950 11rCDr09 [10] 1815 ld de, #___str_15 + 00000953 21r64r02 [10] 1816 ld hl, #_win_xm + 00000956 CDr00r00 [17] 1817 call _wc_prsrw + 1818 ;src/main.c:512: wc_prsrw(&win_xm, " / ", ROW_TIME, 12, 3); + 00000959 21 03 00 [10] 1819 ld hl, #0x0003 + 0000095C E5 [11] 1820 push hl + 0000095D 21 06 0C [10] 1821 ld hl, #0xc06 + 00000960 E5 [11] 1822 push hl + 00000961 11rD3r09 [10] 1823 ld de, #___str_16 + 00000964 21r64r02 [10] 1824 ld hl, #_win_xm + 00000967 CDr00r00 [17] 1825 call _wc_prsrw + 1826 ;src/main.c:514: for (i = 0; i < BAR_WIDTH; i++) + 0000096A 11r6Cr10 [10] 1827 ld de, #_barbuf+0 + 0000096D 0E 00 [ 7] 1828 ld c, #0x00 + 0000096F 1829 00103$: + 1830 ;src/main.c:515: barbuf[i] = ' '; + 0000096F 69 [ 4] 1831 ld l, c + 00000970 26 00 [ 7] 1832 ld h, #0x00 + 00000972 19 [11] 1833 add hl, de + 00000973 36 20 [10] 1834 ld (hl), #0x20 + 1835 ;src/main.c:514: for (i = 0; i < BAR_WIDTH; i++) + 00000975 0C [ 4] 1836 inc c + 00000976 79 [ 4] 1837 ld a, c + 00000977 D6 20 [ 7] 1838 sub a, #0x20 + 00000979 38 F4 [12] 1839 jr c, 00103$ + 1840 ;src/main.c:516: wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); + 1841 ;src/main.c:507: wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); + 1842 ;src/main.c:516: wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); + 0000097B 21 20 00 [10] 1843 ld hl, #0x0020 + 0000097E E5 [11] 1844 push hl + 0000097F 21 08 04 [10] 1845 ld hl, #0x408 + 00000982 E5 [11] 1846 push hl + 00000983 21r64r02 [10] 1847 ld hl, #_win_xm + 00000986 CDr00r00 [17] 1848 call _wc_prsrw + 1849 ;src/main.c:518: bar_attr_ofs = (wc_gadrw(&win_xm, ROW_BAR, BAR_X) & 0x3FFF) | 0x0080; + 00000989 21 08 04 [10] 1850 ld hl, #0x408 + 0000098C E5 [11] 1851 push hl + 0000098D 21r64r02 [10] 1852 ld hl, #_win_xm + 00000990 CDr00r00 [17] 1853 call _wc_gadrw + 00000993 7A [ 4] 1854 ld a, d + 00000994 E6 3F [ 7] 1855 and a, #0x3f + 00000996 57 [ 4] 1856 ld d, a + 00000997 CB FB [ 8] 1857 set 7, e + 00000999 ED 53r8Cr10 [20] 1858 ld (_bar_attr_ofs), de + 1859 ;src/main.c:520: for (i = 0; i < BAR_WIDTH; i++) + 0000099D 0E 00 [ 7] 1860 ld c, #0x00 + 0000099F 1861 00105$: + 1862 ;src/main.c:521: *(volatile u8*)(0xC000 + bar_attr_ofs + i) = ATTR_BAR_EMPTY; + 0000099F 2Ar8Cr10 [16] 1863 ld hl, (_bar_attr_ofs) + 000009A2 5D [ 4] 1864 ld e, l + 000009A3 7C [ 4] 1865 ld a, h + 000009A4 C6 C0 [ 7] 1866 add a, #0xc0 + 000009A6 57 [ 4] 1867 ld d, a + 000009A7 69 [ 4] 1868 ld l, c + 000009A8 26 00 [ 7] 1869 ld h, #0x00 + 000009AA 19 [11] 1870 add hl, de + 000009AB 36 07 [10] 1871 ld (hl), #0x07 + 1872 ;src/main.c:520: for (i = 0; i < BAR_WIDTH; i++) + 000009AD 0C [ 4] 1873 inc c + 000009AE 79 [ 4] 1874 ld a, c + 000009AF D6 20 [ 7] 1875 sub a, #0x20 + 000009B1 38 EC [12] 1876 jr c, 00105$ + 1877 ;src/main.c:522: } + 000009B3 C9 [10] 1878 ret + 000009B4 1879 ___str_12: + 000009B4 50 61 74 74 65 72 6E 1880 .ascii "Pattern:#" 3A 23 - 000007C3 00 1525 .db 0x00 - 000007C4 1526 ___str_12: - 000007C4 20 20 52 6F 77 3A 23 1527 .ascii " Row:#" - 000007CB 00 1528 .db 0x00 - 000007CC 1529 ___str_13: - 000007CC 20 20 42 50 4D 3A 1530 .ascii " BPM:" - 000007D2 00 1531 .db 0x00 - 000007D3 1532 ___str_14: - 000007D3 54 69 6D 65 3A 1533 .ascii "Time:" - 000007D8 00 1534 .db 0x00 - 000007D9 1535 ___str_15: - 000007D9 20 2F 20 1536 .ascii " / " - 000007DC 00 1537 .db 0x00 - 1538 ;src/main.c:386: void draw_progress_bar(u32 samples, u32 total) - 1539 ; --------------------------------- - 1540 ; Function draw_progress_bar - 1541 ; --------------------------------- - 000007DD 1542 _draw_progress_bar:: - 000007DD DD E5 [15] 1543 push ix - 000007DF DD 21 00 00 [14] 1544 ld ix, #0 - 000007E3 DD 39 [15] 1545 add ix, sp - 000007E5 4B [ 4] 1546 ld c, e - 000007E6 42 [ 4] 1547 ld b, d - 000007E7 EB [ 4] 1548 ex de, hl - 1549 ;src/main.c:390: if (total) - 000007E8 DD 7E 07 [19] 1550 ld a, 7 (ix) - 000007EB DD B6 06 [19] 1551 or a, 6 (ix) - 000007EE DD B6 05 [19] 1552 or a, 5 (ix) - 000007F1 DD B6 04 [19] 1553 or a, 4 (ix) - 000007F4 28 30 [12] 1554 jr z, 00104$ - 1555 ;src/main.c:392: filled = (u16)(((u32)samples * BAR_WIDTH) / total); - 000007F6 D5 [11] 1556 push de - 000007F7 C5 [11] 1557 push bc - 000007F8 11 22 00 [10] 1558 ld de, #0x0022 - 000007FB 21 00 00 [10] 1559 ld hl, #0x0000 - 000007FE CDr00r00 [17] 1560 call __mullong - 00000801 F1 [10] 1561 pop af - 00000802 F1 [10] 1562 pop af - 00000803 DD 4E 06 [19] 1563 ld c, 6 (ix) - 00000806 DD 46 07 [19] 1564 ld b, 7 (ix) - 00000809 C5 [11] 1565 push bc - 0000080A DD 4E 04 [19] 1566 ld c, 4 (ix) - 0000080D DD 46 05 [19] 1567 ld b, 5 (ix) - 00000810 C5 [11] 1568 push bc - 00000811 CDr00r00 [17] 1569 call __divulong - 00000814 F1 [10] 1570 pop af - 00000815 F1 [10] 1571 pop af - 1572 ;src/main.c:393: if (filled > BAR_WIDTH) - 00000816 4B [ 4] 1573 ld c,e - 00000817 42 [ 4] 1574 ld b,d - 00000818 3E 22 [ 7] 1575 ld a, #0x22 - 0000081A BB [ 4] 1576 cp a, e - 0000081B 3E 00 [ 7] 1577 ld a, #0x00 - 0000081D 9A [ 4] 1578 sbc a, d - 0000081E 30 09 [12] 1579 jr nc, 00121$ - 1580 ;src/main.c:394: filled = BAR_WIDTH; - 00000820 01 22 00 [10] 1581 ld bc, #0x0022 - 00000823 C3r29r08 [10] 1582 jp 00121$ - 00000826 1583 00104$: - 1584 ;src/main.c:397: filled = 0; // total length unknown (measurement timed out) - show empty - 00000826 01 00 00 [10] 1585 ld bc, #0x0000 - 1586 ;src/main.c:399: for (i = 0; i < BAR_WIDTH; i++) - 00000829 1587 00121$: - 00000829 11 00 00 [10] 1588 ld de, #0x0000 - 0000082C 1589 00107$: - 1590 ;src/main.c:400: barbuf[i] = (i < filled) ? BAR_FILLED_CH : BAR_EMPTY_CH; - 0000082C 21r3Cr10 [10] 1591 ld hl, #_barbuf - 0000082F 19 [11] 1592 add hl, de - 00000830 7B [ 4] 1593 ld a, e - 00000831 91 [ 4] 1594 sub a, c - 00000832 7A [ 4] 1595 ld a, d - 00000833 98 [ 4] 1596 sbc a, b - 00000834 30 05 [12] 1597 jr nc, 00111$ - 00000836 3E 3D [ 7] 1598 ld a, #0x3d - 00000838 C3r3Dr08 [10] 1599 jp 00112$ - 0000083B 1600 00111$: - 0000083B 3E 2D [ 7] 1601 ld a, #0x2d - 0000083D 1602 00112$: - 0000083D 77 [ 7] 1603 ld (hl), a - 1604 ;src/main.c:399: for (i = 0; i < BAR_WIDTH; i++) - 0000083E 13 [ 6] 1605 inc de - 0000083F 6B [ 4] 1606 ld l, e - 00000840 62 [ 4] 1607 ld h, d - 00000841 7D [ 4] 1608 ld a, l - 00000842 D6 22 [ 7] 1609 sub a, #0x22 - 00000844 7C [ 4] 1610 ld a, h - 00000845 DE 00 [ 7] 1611 sbc a, #0x00 - 00000847 38 E3 [12] 1612 jr c, 00107$ - 1613 ;src/main.c:402: wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); - 00000849 21 22 00 [10] 1614 ld hl, #0x0022 - 0000084C E5 [11] 1615 push hl - 0000084D 21 06 01 [10] 1616 ld hl, #0x106 - 00000850 E5 [11] 1617 push hl - 00000851 11r3Cr10 [10] 1618 ld de, #_barbuf - 00000854 21r71r02 [10] 1619 ld hl, #_win_xm - 00000857 CDr00r00 [17] 1620 call _wc_prsrw - 1621 ;src/main.c:403: } - 0000085A DD E1 [14] 1622 pop ix - 0000085C E1 [10] 1623 pop hl - 0000085D F1 [10] 1624 pop af - 0000085E F1 [10] 1625 pop af - 0000085F E9 [ 4] 1626 jp (hl) - 1627 ;src/main.c:405: void xm_update_info() - 1628 ; --------------------------------- - 1629 ; Function xm_update_info - 1630 ; --------------------------------- - 00000860 1631 _xm_update_info:: - 00000860 DD E5 [15] 1632 push ix - 00000862 DD 21 00 00 [14] 1633 ld ix, #0 - 00000866 DD 39 [15] 1634 add ix, sp - 00000868 21 F8 FF [10] 1635 ld hl, #-8 - 0000086B 39 [11] 1636 add hl, sp - 0000086C F9 [ 6] 1637 ld sp, hl - 1638 ;src/main.c:411: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); - 0000086D 3Ar30r10 [13] 1639 ld a, (_xm_handle) - 00000870 6F [ 4] 1640 ld l, a - 00000871 3E 0B [ 7] 1641 ld a, #0x0b - 00000873 CDrDAr00 [17] 1642 call _esp_wr_reg8 - 1643 ;src/main.c:412: esp_cmd(ESP_CMD_TRACK_GET_INFO); - 00000876 3E A8 [ 7] 1644 ld a, #0xa8 - 00000878 CDr0Er00 [17] 1645 call _esp_cmd - 1646 ;src/main.c:413: esp_wait_busy(2000); - 0000087B 11 D0 07 [10] 1647 ld de, #0x07d0 - 0000087E 21 00 00 [10] 1648 ld hl, #0x0000 - 00000881 CDrDEr01 [17] 1649 call _esp_wait_busy - 1650 ;src/main.c:418: status = esp_rd_reg8(ESP_REG_TRACK_STATUS); - 00000884 3E 28 [ 7] 1651 ld a, #0x28 - 00000886 CDr27r00 [17] 1652 call _esp_rd_reg8 - 00000889 DD 77 FF [19] 1653 ld -1 (ix), a - 1654 ;src/main.c:419: if (last_track_status == TRACK_OBJ_ST_PLAYING && status == TRACK_OBJ_ST_STOPPED) - 0000088C 3Ar31r10 [13] 1655 ld a, (_last_track_status) - 0000088F D6 21 [ 7] 1656 sub a, #0x21 - 00000891 20 20 [12] 1657 jr nz, 00102$ - 00000893 DD 7E FF [19] 1658 ld a, -1 (ix) - 00000896 D6 20 [ 7] 1659 sub a, #0x20 - 00000898 20 19 [12] 1660 jr nz, 00102$ - 1661 ;src/main.c:421: esp_cmd(ESP_CMD_KILL_OBJECTS); - 0000089A 3E E4 [ 7] 1662 ld a, #0xe4 - 0000089C CDr0Er00 [17] 1663 call _esp_cmd - 1664 ;src/main.c:422: esp_wait_busy(10000); - 0000089F 11 10 27 [10] 1665 ld de, #0x2710 - 000008A2 21 00 00 [10] 1666 ld hl, #0x0000 - 000008A5 CDrDEr01 [17] 1667 call _esp_wait_busy - 1668 ;src/main.c:423: wc_rresb(&win_xm); - 000008A8 21r71r02 [10] 1669 ld hl, #_win_xm - 000008AB CDr00r00 [17] 1670 call _wc_rresb - 1671 ;src/main.c:424: wc_exit(WC_NEXT_FILE); - 000008AE 3E 02 [ 7] 1672 ld a, #0x02 - 000008B0 CDr00r00 [17] 1673 call _wc_exit - 000008B3 1674 00102$: - 1675 ;src/main.c:426: last_track_status = status; - 000008B3 DD 7E FF [19] 1676 ld a, -1 (ix) - 000008B6 32r31r10 [13] 1677 ld (#_last_track_status), a - 1678 ;src/main.c:428: pattern = esp_rd_reg8(ESP_REG_TRACK_PATTERN); - 000008B9 3E 2B [ 7] 1679 ld a, #0x2b - 000008BB CDr27r00 [17] 1680 call _esp_rd_reg8 - 000008BE DD 77 FA [19] 1681 ld -6 (ix), a - 1682 ;src/main.c:429: row = esp_rd_reg8(ESP_REG_TRACK_ROW); - 000008C1 3E 2C [ 7] 1683 ld a, #0x2c - 000008C3 CDr27r00 [17] 1684 call _esp_rd_reg8 - 000008C6 DD 77 FB [19] 1685 ld -5 (ix), a - 1686 ;src/main.c:430: esp_rd_regs(ESP_REG_TRACK_BPM, &bpm, 2); - 000008C9 3E 02 [ 7] 1687 ld a, #0x02 - 000008CB F5 [11] 1688 push af - 000008CC 33 [ 6] 1689 inc sp - 000008CD 21 01 00 [10] 1690 ld hl, #1 - 000008D0 39 [11] 1691 add hl, sp - 000008D1 EB [ 4] 1692 ex de, hl - 000008D2 3E 31 [ 7] 1693 ld a, #0x31 - 000008D4 CDrAEr00 [17] 1694 call _esp_rd_regs - 1695 ;src/main.c:431: samples = esp_rd_reg32(ESP_REG_TRACK_SAMPLES); - 000008D7 3E 2D [ 7] 1696 ld a, #0x2d - 000008D9 CDr40r00 [17] 1697 call _esp_rd_reg32 - 000008DC DD 73 FC [19] 1698 ld -4 (ix), e - 000008DF DD 72 FD [19] 1699 ld -3 (ix), d - 000008E2 DD 75 FE [19] 1700 ld -2 (ix), l - 000008E5 DD 74 FF [19] 1701 ld -1 (ix), h - 1702 ;src/main.c:433: if (!total_samples) - 000008E8 3Ar2Fr10 [13] 1703 ld a, (_total_samples+3) - 000008EB FD 21r2Cr10 [14] 1704 ld iy, #_total_samples - 000008EF FD B6 02 [19] 1705 or a, 2 (iy) - 000008F2 FD B6 01 [19] 1706 or a, 1 (iy) - 000008F5 FD B6 00 [19] 1707 or a, 0 (iy) - 000008F8 20 0C [12] 1708 jr nz, 00105$ - 1709 ;src/main.c:434: total_samples = esp_rd_reg32(ESP_REG_TRACK_TOTAL_SAMPLES); - 000008FA 3E 36 [ 7] 1710 ld a, #0x36 - 000008FC CDr40r00 [17] 1711 call _esp_rd_reg32 - 000008FF ED 53r2Cr10 [20] 1712 ld (_total_samples), de - 00000903 22r2Er10 [16] 1713 ld (_total_samples + 2), hl - 00000906 1714 00105$: - 1715 ;src/main.c:436: put_hex2(hexbuf, pattern); - 00000906 DD 7E FA [19] 1716 ld a, -6 (ix) - 00000909 F5 [11] 1717 push af - 0000090A 33 [ 6] 1718 inc sp - 0000090B 21r32r10 [10] 1719 ld hl, #_hexbuf - 0000090E CDr1Dr06 [17] 1720 call _put_hex2 - 1721 ;src/main.c:437: wc_prsrw(&win_xm, hexbuf, ROW_STATS, 10, 2); - 00000911 21 02 00 [10] 1722 ld hl, #0x0002 - 00000914 E5 [11] 1723 push hl - 00000915 21 03 0A [10] 1724 ld hl, #0xa03 - 00000918 E5 [11] 1725 push hl - 00000919 11r32r10 [10] 1726 ld de, #_hexbuf - 0000091C 21r71r02 [10] 1727 ld hl, #_win_xm - 0000091F CDr00r00 [17] 1728 call _wc_prsrw - 1729 ;src/main.c:439: put_hex2(hexbuf, row); - 00000922 DD 7E FB [19] 1730 ld a, -5 (ix) - 00000925 F5 [11] 1731 push af - 00000926 33 [ 6] 1732 inc sp - 00000927 21r32r10 [10] 1733 ld hl, #_hexbuf - 0000092A CDr1Dr06 [17] 1734 call _put_hex2 - 1735 ;src/main.c:440: wc_prsrw(&win_xm, hexbuf, ROW_STATS, 19, 2); - 0000092D 21 02 00 [10] 1736 ld hl, #0x0002 - 00000930 E5 [11] 1737 push hl - 00000931 21 03 13 [10] 1738 ld hl, #0x1303 - 00000934 E5 [11] 1739 push hl - 00000935 11r32r10 [10] 1740 ld de, #_hexbuf - 00000938 21r71r02 [10] 1741 ld hl, #_win_xm - 0000093B CDr00r00 [17] 1742 call _wc_prsrw - 1743 ;src/main.c:442: put_dec3(decbuf, bpm); - 0000093E D1 [10] 1744 pop de - 0000093F D5 [11] 1745 push de - 00000940 21r34r10 [10] 1746 ld hl, #_decbuf - 00000943 CDr5Ar06 [17] 1747 call _put_dec3 - 1748 ;src/main.c:443: wc_prsrw(&win_xm, decbuf, ROW_STATS, 27, 3); - 00000946 21 03 00 [10] 1749 ld hl, #0x0003 - 00000949 E5 [11] 1750 push hl - 0000094A 21 03 1B [10] 1751 ld hl, #0x1b03 - 0000094D E5 [11] 1752 push hl - 0000094E 11r34r10 [10] 1753 ld de, #_decbuf - 00000951 21r71r02 [10] 1754 ld hl, #_win_xm - 00000954 CDr00r00 [17] 1755 call _wc_prsrw - 1756 ;src/main.c:445: put_time(timebuf, samples / 44100UL); - 00000957 21 00 00 [10] 1757 ld hl, #0x0000 - 0000095A E5 [11] 1758 push hl - 0000095B 21 44 AC [10] 1759 ld hl, #0xac44 - 0000095E E5 [11] 1760 push hl - 0000095F DD 5E FC [19] 1761 ld e, -4 (ix) - 00000962 DD 56 FD [19] 1762 ld d, -3 (ix) - 00000965 DD 6E FE [19] 1763 ld l, -2 (ix) - 00000968 DD 66 FF [19] 1764 ld h, -1 (ix) - 0000096B CDr00r00 [17] 1765 call __divulong - 0000096E F1 [10] 1766 pop af - 0000096F E3 [19] 1767 ex (sp),hl - 00000970 D5 [11] 1768 push de - 00000971 21r37r10 [10] 1769 ld hl, #_timebuf - 00000974 CDrB7r06 [17] 1770 call _put_time - 1771 ;src/main.c:446: wc_prsrw(&win_xm, timebuf, ROW_TIME, 7, 5); - 00000977 21 05 00 [10] 1772 ld hl, #0x0005 - 0000097A E5 [11] 1773 push hl - 0000097B 21 05 07 [10] 1774 ld hl, #0x705 - 0000097E E5 [11] 1775 push hl - 0000097F 11r37r10 [10] 1776 ld de, #_timebuf - 00000982 21r71r02 [10] 1777 ld hl, #_win_xm - 00000985 CDr00r00 [17] 1778 call _wc_prsrw - 1779 ;src/main.c:448: put_time(timebuf, total_samples / 44100UL); - 00000988 21 00 00 [10] 1780 ld hl, #0x0000 - 0000098B E5 [11] 1781 push hl - 0000098C 21 44 AC [10] 1782 ld hl, #0xac44 - 0000098F E5 [11] 1783 push hl - 00000990 ED 5Br2Cr10 [20] 1784 ld de, (_total_samples) - 00000994 2Ar2Er10 [16] 1785 ld hl, (_total_samples + 2) - 00000997 CDr00r00 [17] 1786 call __divulong - 0000099A F1 [10] 1787 pop af - 0000099B E3 [19] 1788 ex (sp),hl - 0000099C D5 [11] 1789 push de - 0000099D 21r37r10 [10] 1790 ld hl, #_timebuf - 000009A0 CDrB7r06 [17] 1791 call _put_time - 1792 ;src/main.c:449: wc_prsrw(&win_xm, timebuf, ROW_TIME, 15, 5); - 000009A3 21 05 00 [10] 1793 ld hl, #0x0005 - 000009A6 E5 [11] 1794 push hl - 000009A7 21 05 0F [10] 1795 ld hl, #0xf05 - 000009AA E5 [11] 1796 push hl - 000009AB 11r37r10 [10] 1797 ld de, #_timebuf - 000009AE 21r71r02 [10] 1798 ld hl, #_win_xm - 000009B1 CDr00r00 [17] 1799 call _wc_prsrw - 1800 ;src/main.c:451: draw_progress_bar(samples, total_samples); - 000009B4 2Ar2Er10 [16] 1801 ld hl, (_total_samples + 2) - 000009B7 E5 [11] 1802 push hl - 000009B8 2Ar2Cr10 [16] 1803 ld hl, (_total_samples) - 000009BB E5 [11] 1804 push hl - 000009BC DD 5E FC [19] 1805 ld e, -4 (ix) - 000009BF DD 56 FD [19] 1806 ld d, -3 (ix) - 000009C2 DD 6E FE [19] 1807 ld l, -2 (ix) - 000009C5 DD 66 FF [19] 1808 ld h, -1 (ix) - 000009C8 CDrDDr07 [17] 1809 call _draw_progress_bar - 1810 ;src/main.c:453: } - 000009CB DD F9 [10] 1811 ld sp, ix - 000009CD DD E1 [14] 1812 pop ix - 000009CF C9 [10] 1813 ret - 1814 ;src/main.c:455: void main_start() - 1815 ; --------------------------------- - 1816 ; Function main_start - 1817 ; --------------------------------- - 000009D0 1818 _main_start:: - 000009D0 3B [ 6] 1819 dec sp - 1820 ;src/main.c:463: wc_set_freq_14mhz(); - 000009D1 CDr05r00 [17] 1821 call _wc_set_freq_14mhz - 1822 ;src/main.c:465: copy_file_name(); - 000009D4 CDrC8r05 [17] 1823 call _copy_file_name - 1824 ;src/main.c:467: if (state_esp == 0xFF) - 000009D7 3Ar00r00 [13] 1825 ld a, (_state_esp) - 000009DA 3C [ 4] 1826 inc a - 000009DB 20 0D [12] 1827 jr nz, 00102$ - 1828 ;src/main.c:468: state_esp = esp_init() ? 1 : 2; - 000009DD CDr2Er02 [17] 1829 call _esp_init - 000009E0 B7 [ 4] 1830 or a, a - 000009E1 3E 01 [ 7] 1831 ld a, #0x01 - 000009E3 20 02 [12] 1832 jr nz, 00124$ - 000009E5 3E 02 [ 7] 1833 ld a, #0x02 - 000009E7 1834 00124$: - 000009E7 32r00r00 [13] 1835 ld (#_state_esp), a - 000009EA 1836 00102$: - 1837 ;src/main.c:470: if (state_esp != 1) - 000009EA 3Ar00r00 [13] 1838 ld a, (_state_esp) - 000009ED 3D [ 4] 1839 dec a - 000009EE 28 07 [12] 1840 jr z, 00104$ - 1841 ;src/main.c:472: error_esp(); - 000009F0 33 [ 6] 1842 inc sp - 000009F1 C3r89r05 [10] 1843 jp _error_esp - 1844 ;src/main.c:473: return; - 000009F4 C3rDBr0A [10] 1845 jp 00121$ - 000009F7 1846 00104$: - 1847 ;src/main.c:476: total_samples = 0; - 000009F7 AF [ 4] 1848 xor a, a - 000009F8 32r2Cr10 [13] 1849 ld (_total_samples+0), a - 000009FB 32r2Dr10 [13] 1850 ld (_total_samples+1), a - 000009FE 32r2Er10 [13] 1851 ld (_total_samples+2), a - 00000A01 32r2Fr10 [13] 1852 ld (_total_samples+3), a - 1853 ;src/main.c:478: if (!play_xm()) - 00000A04 CDr32r03 [17] 1854 call _play_xm - 00000A07 B7 [ 4] 1855 or a, a - 00000A08 20 12 [12] 1856 jr nz, 00109$ - 1857 ;src/main.c:480: if (last_esp_status == ESP_ERR_OUT_OF_MEMORY) - 00000A0A 3Ar08r10 [13] 1858 ld a, (_last_esp_status) - 00000A0D D6 99 [ 7] 1859 sub a, #0x99 - 00000A0F 20 07 [12] 1860 jr nz, 00106$ - 1861 ;src/main.c:481: error_oom(); - 00000A11 33 [ 6] 1862 inc sp - 00000A12 C3r9Cr05 [10] 1863 jp _error_oom - 00000A15 C3rDBr0A [10] 1864 jp 00121$ - 00000A18 1865 00106$: - 1866 ;src/main.c:483: error_playback(); - 00000A18 33 [ 6] 1867 inc sp - 1868 ;src/main.c:484: return; - 00000A19 C3rB2r05 [10] 1869 jp _error_playback - 00000A1C 1870 00109$: - 1871 ;src/main.c:490: wc_prwow(&win_xm); - 00000A1C 21r71r02 [10] 1872 ld hl, #_win_xm - 00000A1F CDr00r00 [17] 1873 call _wc_prwow - 1874 ;src/main.c:491: xm_draw_static_labels(); - 00000A22 CDrEDr05 [17] 1875 call _xm_draw_static_labels - 1876 ;src/main.c:492: xm_draw_stats_labels(); - 00000A25 CDr64r07 [17] 1877 call _xm_draw_stats_labels - 1878 ;src/main.c:493: last_track_status = TRACK_OBJ_ST_PLAYING; - 00000A28 21r31r10 [10] 1879 ld hl, #_last_track_status - 00000A2B 36 21 [10] 1880 ld (hl), #0x21 - 1881 ;src/main.c:494: xm_update_info(); - 00000A2D CDr60r08 [17] 1882 call _xm_update_info - 1883 ;src/main.c:496: frame_ctr = 0; - 00000A30 FD 21 00 00 [14] 1884 ld iy, #0 - 00000A34 FD 39 [15] 1885 add iy, sp - 00000A36 FD 36 00 00 [19] 1886 ld 0 (iy), #0x00 - 1887 ;src/main.c:499: while (1) - 00000A3A 1888 00119$: - 1889 ;src/main.c:503: __endasm; - 00000A3A 76 [ 4] 1890 halt - 1891 ;src/main.c:505: if (++frame_ctr >= 10) // ~5 updates/sec at 50Hz - 00000A3B FD 21 00 00 [14] 1892 ld iy, #0 - 00000A3F FD 39 [15] 1893 add iy, sp - 00000A41 FD 34 00 [23] 1894 inc 0 (iy) - 00000A44 FD 7E 00 [19] 1895 ld a, 0 (iy) - 00000A47 D6 0A [ 7] 1896 sub a, #0x0a - 00000A49 38 07 [12] 1897 jr c, 00111$ - 1898 ;src/main.c:507: frame_ctr = 0; - 00000A4B FD 36 00 00 [19] 1899 ld 0 (iy), #0x00 - 1900 ;src/main.c:508: xm_update_info(); - 00000A4F CDr60r08 [17] 1901 call _xm_update_info - 00000A52 1902 00111$: - 1903 ;src/main.c:511: if (wc_key_pgdn()) // PgDn - unload and go to next file - 00000A52 CDr00r00 [17] 1904 call _wc_key_pgdn - 00000A55 B7 [ 4] 1905 or a, a - 00000A56 28 27 [12] 1906 jr z, 00113$ - 1907 ;src/main.c:513: esp_cmd(ESP_CMD_TRACK_STOP); - 00000A58 3E A2 [ 7] 1908 ld a, #0xa2 - 00000A5A CDr0Er00 [17] 1909 call _esp_cmd - 1910 ;src/main.c:514: esp_wait_busy(10000); - 00000A5D 11 10 27 [10] 1911 ld de, #0x2710 - 00000A60 21 00 00 [10] 1912 ld hl, #0x0000 - 00000A63 CDrDEr01 [17] 1913 call _esp_wait_busy - 1914 ;src/main.c:515: esp_cmd(ESP_CMD_KILL_OBJECTS); - 00000A66 3E E4 [ 7] 1915 ld a, #0xe4 - 00000A68 CDr0Er00 [17] 1916 call _esp_cmd - 1917 ;src/main.c:516: esp_wait_busy(10000); - 00000A6B 11 10 27 [10] 1918 ld de, #0x2710 - 00000A6E 21 00 00 [10] 1919 ld hl, #0x0000 - 00000A71 CDrDEr01 [17] 1920 call _esp_wait_busy - 1921 ;src/main.c:517: wc_rresb(&win_xm); - 00000A74 21r71r02 [10] 1922 ld hl, #_win_xm - 00000A77 CDr00r00 [17] 1923 call _wc_rresb - 1924 ;src/main.c:518: wc_exit(WC_NEXT_FILE); - 00000A7A 3E 02 [ 7] 1925 ld a, #0x02 - 00000A7C CDr00r00 [17] 1926 call _wc_exit - 00000A7F 1927 00113$: - 1928 ;src/main.c:521: if (wc_key_pgup()) // PgUp - unload and go to previous file - 00000A7F CDr00r00 [17] 1929 call _wc_key_pgup - 00000A82 B7 [ 4] 1930 or a, a - 00000A83 28 27 [12] 1931 jr z, 00115$ - 1932 ;src/main.c:523: esp_cmd(ESP_CMD_TRACK_STOP); - 00000A85 3E A2 [ 7] 1933 ld a, #0xa2 - 00000A87 CDr0Er00 [17] 1934 call _esp_cmd - 1935 ;src/main.c:524: esp_wait_busy(10000); - 00000A8A 11 10 27 [10] 1936 ld de, #0x2710 - 00000A8D 21 00 00 [10] 1937 ld hl, #0x0000 - 00000A90 CDrDEr01 [17] 1938 call _esp_wait_busy - 1939 ;src/main.c:525: esp_cmd(ESP_CMD_KILL_OBJECTS); - 00000A93 3E E4 [ 7] 1940 ld a, #0xe4 - 00000A95 CDr0Er00 [17] 1941 call _esp_cmd - 1942 ;src/main.c:526: esp_wait_busy(10000); - 00000A98 11 10 27 [10] 1943 ld de, #0x2710 - 00000A9B 21 00 00 [10] 1944 ld hl, #0x0000 - 00000A9E CDrDEr01 [17] 1945 call _esp_wait_busy - 1946 ;src/main.c:527: wc_rresb(&win_xm); - 00000AA1 21r71r02 [10] 1947 ld hl, #_win_xm - 00000AA4 CDr00r00 [17] 1948 call _wc_rresb - 1949 ;src/main.c:528: wc_exit(WC_PREV_FILE); - 00000AA7 3E 04 [ 7] 1950 ld a, #0x04 - 00000AA9 CDr00r00 [17] 1951 call _wc_exit - 00000AAC 1952 00115$: - 1953 ;src/main.c:531: if (wc_key_esc()) // Esc - unload and exit - 00000AAC CDr00r00 [17] 1954 call _wc_key_esc - 00000AAF B7 [ 4] 1955 or a, a - 00000AB0 28 88 [12] 1956 jr z, 00119$ - 1957 ;src/main.c:533: esp_cmd(ESP_CMD_TRACK_STOP); - 00000AB2 3E A2 [ 7] 1958 ld a, #0xa2 - 00000AB4 CDr0Er00 [17] 1959 call _esp_cmd - 1960 ;src/main.c:534: esp_wait_busy(10000); - 00000AB7 11 10 27 [10] 1961 ld de, #0x2710 - 00000ABA 21 00 00 [10] 1962 ld hl, #0x0000 - 00000ABD CDrDEr01 [17] 1963 call _esp_wait_busy - 1964 ;src/main.c:535: esp_cmd(ESP_CMD_KILL_OBJECTS); - 00000AC0 3E E4 [ 7] 1965 ld a, #0xe4 - 00000AC2 CDr0Er00 [17] 1966 call _esp_cmd - 1967 ;src/main.c:536: esp_wait_busy(10000); - 00000AC5 11 10 27 [10] 1968 ld de, #0x2710 - 00000AC8 21 00 00 [10] 1969 ld hl, #0x0000 - 00000ACB CDrDEr01 [17] 1970 call _esp_wait_busy - 1971 ;src/main.c:537: wc_rresb(&win_xm); - 00000ACE 21r71r02 [10] 1972 ld hl, #_win_xm - 00000AD1 CDr00r00 [17] 1973 call _wc_rresb - 1974 ;src/main.c:538: wc_exit(WC_EXIT); - 00000AD4 AF [ 4] 1975 xor a, a - 00000AD5 CDr00r00 [17] 1976 call _wc_exit - 00000AD8 C3r3Ar0A [10] 1977 jp 00119$ - 00000ADB 1978 00121$: - 1979 ;src/main.c:541: } - 00000ADB 33 [ 6] 1980 inc sp - 00000ADC C9 [10] 1981 ret - 1982 ;src/main.c:544: void main() - 1983 ; --------------------------------- - 1984 ; Function main - 1985 ; --------------------------------- - 00000ADD 1986 _main:: - 1987 ;src/main.c:554: __endasm; - 00000ADD ED 73r00r10 [20] 1988 ld (_ret_sp), sp - 00000AE1 32r07r10 [13] 1989 ld (_call_type), a - 00000AE4 ED 43r09r10 [20] 1990 ld (_p_file_name), bc - 00000AE8 08 [ 4] 1991 ex af, af - 00000AE9 32r06r10 [13] 1992 ld (_file_ext), a - 00000AEC 22r02r10 [16] 1993 ld (_filesize), hl - 00000AEF ED 53r04r10 [20] 1994 ld (_filesize + 2), de - 1995 ;src/main.c:556: switch (call_type) - 00000AF3 3Ar07r10 [13] 1996 ld a, (_call_type+0) - 00000AF6 B7 [ 4] 1997 or a, a - 00000AF7 CArD0r09 [10] 1998 jp z, _main_start - 00000AFA 3Ar07r10 [13] 1999 ld a, (_call_type) - 00000AFD D6 03 [ 7] 2000 sub a, #0x03 - 00000AFF CAr76r05 [10] 2001 jp z, _about - 2002 ;src/main.c:558: case WC_CALL_EXT: - 2003 ;src/main.c:559: main_start(); - 2004 ;src/main.c:560: break; - 2005 ;src/main.c:562: case WC_CALL_MENU: - 2006 ;src/main.c:563: about(); - 2007 ;src/main.c:564: break; - 2008 ;src/main.c:566: default: - 2009 ;src/main.c:567: wc_exit(WC_EXIT); - 00000B02 AF [ 4] 2010 xor a, a - 2011 ;src/main.c:568: } - 2012 ;src/main.c:569: } - 00000B03 C3r00r00 [10] 2013 jp _wc_exit - 2014 .area _CODE - 2015 .area _INITIALIZER - 00000000 2016 __xinit__state_esp: - 00000000 FF 2017 .db #0xff ; 255 - 2018 .area _CABS (ABS) + 000009BD 00 1881 .db 0x00 + 000009BE 1882 ___str_13: + 000009BE 20 20 52 6F 77 3A 23 1883 .ascii " Row:#" + 000009C5 00 1884 .db 0x00 + 000009C6 1885 ___str_14: + 000009C6 20 20 42 50 4D 3A 1886 .ascii " BPM:" + 000009CC 00 1887 .db 0x00 + 000009CD 1888 ___str_15: + 000009CD 54 69 6D 65 3A 1889 .ascii "Time:" + 000009D2 00 1890 .db 0x00 + 000009D3 1891 ___str_16: + 000009D3 20 2F 20 1892 .ascii " / " + 000009D6 00 1893 .db 0x00 + 1894 ;src/main.c:524: void draw_progress_bar(u32 samples, u32 total) + 1895 ; --------------------------------- + 1896 ; Function draw_progress_bar + 1897 ; --------------------------------- + 000009D7 1898 _draw_progress_bar:: + 000009D7 DD E5 [15] 1899 push ix + 000009D9 DD 21 00 00 [14] 1900 ld ix, #0 + 000009DD DD 39 [15] 1901 add ix, sp + 000009DF 4B [ 4] 1902 ld c, e + 000009E0 42 [ 4] 1903 ld b, d + 000009E1 EB [ 4] 1904 ex de, hl + 1905 ;src/main.c:528: if (total) + 000009E2 DD 7E 07 [19] 1906 ld a, 7 (ix) + 000009E5 DD B6 06 [19] 1907 or a, 6 (ix) + 000009E8 DD B6 05 [19] 1908 or a, 5 (ix) + 000009EB DD B6 04 [19] 1909 or a, 4 (ix) + 000009EE 28 30 [12] 1910 jr z, 00104$ + 1911 ;src/main.c:530: filled = (u16)(((u32)samples * BAR_WIDTH) / total); + 000009F0 69 [ 4] 1912 ld l, c + 000009F1 60 [ 4] 1913 ld h, b + 000009F2 3E 05 [ 7] 1914 ld a, #0x05 + 000009F4 1915 00146$: + 000009F4 29 [11] 1916 add hl, hl + 000009F5 CB 13 [ 8] 1917 rl e + 000009F7 CB 12 [ 8] 1918 rl d + 000009F9 3D [ 4] 1919 dec a + 000009FA 20 F8 [12] 1920 jr nz, 00146$ + 000009FC DD 4E 06 [19] 1921 ld c, 6 (ix) + 000009FF DD 46 07 [19] 1922 ld b, 7 (ix) + 00000A02 C5 [11] 1923 push bc + 00000A03 DD 4E 04 [19] 1924 ld c, 4 (ix) + 00000A06 DD 46 05 [19] 1925 ld b, 5 (ix) + 00000A09 C5 [11] 1926 push bc + 00000A0A EB [ 4] 1927 ex de, hl + 00000A0B CDr00r00 [17] 1928 call __divulong + 00000A0E F1 [10] 1929 pop af + 00000A0F F1 [10] 1930 pop af + 1931 ;src/main.c:531: if (filled > BAR_WIDTH) + 00000A10 4B [ 4] 1932 ld c,e + 00000A11 42 [ 4] 1933 ld b,d + 00000A12 3E 20 [ 7] 1934 ld a, #0x20 + 00000A14 BB [ 4] 1935 cp a, e + 00000A15 3E 00 [ 7] 1936 ld a, #0x00 + 00000A17 9A [ 4] 1937 sbc a, d + 00000A18 30 09 [12] 1938 jr nc, 00120$ + 1939 ;src/main.c:532: filled = BAR_WIDTH; + 00000A1A 01 20 00 [10] 1940 ld bc, #0x0020 + 00000A1D C3r23r0A [10] 1941 jp 00120$ + 00000A20 1942 00104$: + 1943 ;src/main.c:535: filled = 0; // total length unknown (measurement timed out) - show empty + 00000A20 01 00 00 [10] 1944 ld bc, #0x0000 + 1945 ;src/main.c:537: for (i = 0; i < BAR_WIDTH; i++) + 00000A23 1946 00120$: + 00000A23 11 00 00 [10] 1947 ld de, #0x0000 + 00000A26 1948 00107$: + 1949 ;src/main.c:538: *(volatile u8*)(0xC000 + bar_attr_ofs + i) = (i < filled) ? ATTR_BAR_FILLED : ATTR_BAR_EMPTY; + 00000A26 2Ar8Cr10 [16] 1950 ld hl, (_bar_attr_ofs) + 00000A29 7C [ 4] 1951 ld a, h + 00000A2A C6 C0 [ 7] 1952 add a, #0xc0 + 00000A2C 67 [ 4] 1953 ld h, a + 00000A2D 19 [11] 1954 add hl, de + 00000A2E 7B [ 4] 1955 ld a, e + 00000A2F 91 [ 4] 1956 sub a, c + 00000A30 7A [ 4] 1957 ld a, d + 00000A31 98 [ 4] 1958 sbc a, b + 00000A32 30 05 [12] 1959 jr nc, 00111$ + 00000A34 3E 40 [ 7] 1960 ld a, #0x40 + 00000A36 C3r3Br0A [10] 1961 jp 00112$ + 00000A39 1962 00111$: + 00000A39 3E 07 [ 7] 1963 ld a, #0x07 + 00000A3B 1964 00112$: + 00000A3B 77 [ 7] 1965 ld (hl), a + 1966 ;src/main.c:537: for (i = 0; i < BAR_WIDTH; i++) + 00000A3C 13 [ 6] 1967 inc de + 00000A3D 6B [ 4] 1968 ld l, e + 00000A3E 62 [ 4] 1969 ld h, d + 00000A3F 7D [ 4] 1970 ld a, l + 00000A40 D6 20 [ 7] 1971 sub a, #0x20 + 00000A42 7C [ 4] 1972 ld a, h + 00000A43 DE 00 [ 7] 1973 sbc a, #0x00 + 00000A45 38 DF [12] 1974 jr c, 00107$ + 1975 ;src/main.c:539: } + 00000A47 DD E1 [14] 1976 pop ix + 00000A49 E1 [10] 1977 pop hl + 00000A4A F1 [10] 1978 pop af + 00000A4B F1 [10] 1979 pop af + 00000A4C E9 [ 4] 1980 jp (hl) + 1981 ;src/main.c:541: void xm_update_info() + 1982 ; --------------------------------- + 1983 ; Function xm_update_info + 1984 ; --------------------------------- + 00000A4D 1985 _xm_update_info:: + 00000A4D DD E5 [15] 1986 push ix + 00000A4F DD 21 00 00 [14] 1987 ld ix, #0 + 00000A53 DD 39 [15] 1988 add ix, sp + 00000A55 21 F8 FF [10] 1989 ld hl, #-8 + 00000A58 39 [11] 1990 add hl, sp + 00000A59 F9 [ 6] 1991 ld sp, hl + 1992 ;src/main.c:547: esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); + 00000A5A 3Ar30r10 [13] 1993 ld a, (_xm_handle) + 00000A5D 6F [ 4] 1994 ld l, a + 00000A5E 3E 0B [ 7] 1995 ld a, #0x0b + 00000A60 CDrD1r00 [17] 1996 call _esp_wr_reg8 + 1997 ;src/main.c:548: esp_cmd(ESP_CMD_TRACK_GET_INFO); + 00000A63 3E A8 [ 7] 1998 ld a, #0xa8 + 00000A65 CDr05r00 [17] 1999 call _esp_cmd + 2000 ;src/main.c:549: esp_wait_busy(50); // 1s - a plain info read should be near-instant + 00000A68 21 32 00 [10] 2001 ld hl, #0x0032 + 00000A6B CDrE5r01 [17] 2002 call _esp_wait_busy + 2003 ;src/main.c:554: status = esp_rd_reg8(ESP_REG_TRACK_STATUS); + 00000A6E 3E 28 [ 7] 2004 ld a, #0x28 + 00000A70 CDr1Er00 [17] 2005 call _esp_rd_reg8 + 00000A73 DD 77 FF [19] 2006 ld -1 (ix), a + 2007 ;src/main.c:555: if (last_track_status == TRACK_OBJ_ST_PLAYING && status == TRACK_OBJ_ST_STOPPED) + 00000A76 3Ar31r10 [13] 2008 ld a, (_last_track_status) + 00000A79 D6 21 [ 7] 2009 sub a, #0x21 + 00000A7B 20 1D [12] 2010 jr nz, 00102$ + 00000A7D DD 7E FF [19] 2011 ld a, -1 (ix) + 00000A80 D6 20 [ 7] 2012 sub a, #0x20 + 00000A82 20 16 [12] 2013 jr nz, 00102$ + 2014 ;src/main.c:557: esp_cmd(ESP_CMD_KILL_OBJECTS); + 00000A84 3E E4 [ 7] 2015 ld a, #0xe4 + 00000A86 CDr05r00 [17] 2016 call _esp_cmd + 2017 ;src/main.c:558: esp_wait_busy(100); + 00000A89 21 64 00 [10] 2018 ld hl, #0x0064 + 00000A8C CDrE5r01 [17] 2019 call _esp_wait_busy + 2020 ;src/main.c:559: wc_rresb(&win_xm); + 00000A8F 21r64r02 [10] 2021 ld hl, #_win_xm + 00000A92 CDr00r00 [17] 2022 call _wc_rresb + 2023 ;src/main.c:560: wc_exit(WC_NEXT_FILE); + 00000A95 3E 02 [ 7] 2024 ld a, #0x02 + 00000A97 CDr00r00 [17] 2025 call _wc_exit + 00000A9A 2026 00102$: + 2027 ;src/main.c:562: last_track_status = status; + 00000A9A DD 7E FF [19] 2028 ld a, -1 (ix) + 00000A9D 32r31r10 [13] 2029 ld (#_last_track_status), a + 2030 ;src/main.c:564: pattern = esp_rd_reg8(ESP_REG_TRACK_PATTERN); + 00000AA0 3E 2B [ 7] 2031 ld a, #0x2b + 00000AA2 CDr1Er00 [17] 2032 call _esp_rd_reg8 + 00000AA5 DD 77 FA [19] 2033 ld -6 (ix), a + 2034 ;src/main.c:565: row = esp_rd_reg8(ESP_REG_TRACK_ROW); + 00000AA8 3E 2C [ 7] 2035 ld a, #0x2c + 00000AAA CDr1Er00 [17] 2036 call _esp_rd_reg8 + 00000AAD DD 77 FB [19] 2037 ld -5 (ix), a + 2038 ;src/main.c:566: esp_rd_regs(ESP_REG_TRACK_BPM, &bpm, 2); + 00000AB0 3E 02 [ 7] 2039 ld a, #0x02 + 00000AB2 F5 [11] 2040 push af + 00000AB3 33 [ 6] 2041 inc sp + 00000AB4 21 01 00 [10] 2042 ld hl, #1 + 00000AB7 39 [11] 2043 add hl, sp + 00000AB8 EB [ 4] 2044 ex de, hl + 00000AB9 3E 31 [ 7] 2045 ld a, #0x31 + 00000ABB CDrA5r00 [17] 2046 call _esp_rd_regs + 2047 ;src/main.c:567: samples = esp_rd_reg32(ESP_REG_TRACK_SAMPLES); + 00000ABE 3E 2D [ 7] 2048 ld a, #0x2d + 00000AC0 CDr37r00 [17] 2049 call _esp_rd_reg32 + 00000AC3 DD 73 FC [19] 2050 ld -4 (ix), e + 00000AC6 DD 72 FD [19] 2051 ld -3 (ix), d + 00000AC9 DD 75 FE [19] 2052 ld -2 (ix), l + 00000ACC DD 74 FF [19] 2053 ld -1 (ix), h + 2054 ;src/main.c:569: if (!total_samples) + 00000ACF 3Ar2Fr10 [13] 2055 ld a, (_total_samples+3) + 00000AD2 FD 21r2Cr10 [14] 2056 ld iy, #_total_samples + 00000AD6 FD B6 02 [19] 2057 or a, 2 (iy) + 00000AD9 FD B6 01 [19] 2058 or a, 1 (iy) + 00000ADC FD B6 00 [19] 2059 or a, 0 (iy) + 00000ADF 20 0C [12] 2060 jr nz, 00105$ + 2061 ;src/main.c:570: total_samples = esp_rd_reg32(ESP_REG_TRACK_TOTAL_SAMPLES); + 00000AE1 3E 36 [ 7] 2062 ld a, #0x36 + 00000AE3 CDr37r00 [17] 2063 call _esp_rd_reg32 + 00000AE6 ED 53r2Cr10 [20] 2064 ld (_total_samples), de + 00000AEA 22r2Er10 [16] 2065 ld (_total_samples + 2), hl + 00000AED 2066 00105$: + 2067 ;src/main.c:572: put_hex2(hexbuf, pattern); + 00000AED DD 7E FA [19] 2068 ld a, -6 (ix) + 00000AF0 F5 [11] 2069 push af + 00000AF1 33 [ 6] 2070 inc sp + 00000AF2 21r62r10 [10] 2071 ld hl, #_hexbuf + 00000AF5 CDrCEr07 [17] 2072 call _put_hex2 + 2073 ;src/main.c:573: wc_prsrw_attr(&win_xm, hexbuf, ROW_STATS, 10, 2, ATTR_VALUE); + 00000AF8 3E 71 [ 7] 2074 ld a, #0x71 + 00000AFA F5 [11] 2075 push af + 00000AFB 33 [ 6] 2076 inc sp + 00000AFC 21 02 00 [10] 2077 ld hl, #0x0002 + 00000AFF E5 [11] 2078 push hl + 00000B00 21 04 0A [10] 2079 ld hl, #0xa04 + 00000B03 E5 [11] 2080 push hl + 00000B04 11r62r10 [10] 2081 ld de, #_hexbuf + 00000B07 21r64r02 [10] 2082 ld hl, #_win_xm + 00000B0A CDr00r00 [17] 2083 call _wc_prsrw_attr + 2084 ;src/main.c:575: put_hex2(hexbuf, row); + 00000B0D DD 7E FB [19] 2085 ld a, -5 (ix) + 00000B10 F5 [11] 2086 push af + 00000B11 33 [ 6] 2087 inc sp + 00000B12 21r62r10 [10] 2088 ld hl, #_hexbuf + 00000B15 CDrCEr07 [17] 2089 call _put_hex2 + 2090 ;src/main.c:576: wc_prsrw_attr(&win_xm, hexbuf, ROW_STATS, 19, 2, ATTR_VALUE); + 00000B18 3E 71 [ 7] 2091 ld a, #0x71 + 00000B1A F5 [11] 2092 push af + 00000B1B 33 [ 6] 2093 inc sp + 00000B1C 21 02 00 [10] 2094 ld hl, #0x0002 + 00000B1F E5 [11] 2095 push hl + 00000B20 21 04 13 [10] 2096 ld hl, #0x1304 + 00000B23 E5 [11] 2097 push hl + 00000B24 11r62r10 [10] 2098 ld de, #_hexbuf + 00000B27 21r64r02 [10] 2099 ld hl, #_win_xm + 00000B2A CDr00r00 [17] 2100 call _wc_prsrw_attr + 2101 ;src/main.c:578: put_dec3(decbuf, bpm); + 00000B2D D1 [10] 2102 pop de + 00000B2E D5 [11] 2103 push de + 00000B2F 21r64r10 [10] 2104 ld hl, #_decbuf + 00000B32 CDr0Br08 [17] 2105 call _put_dec3 + 2106 ;src/main.c:579: wc_prsrw_attr(&win_xm, decbuf, ROW_STATS, 27, 3, ATTR_VALUE); + 00000B35 3E 71 [ 7] 2107 ld a, #0x71 + 00000B37 F5 [11] 2108 push af + 00000B38 33 [ 6] 2109 inc sp + 00000B39 21 03 00 [10] 2110 ld hl, #0x0003 + 00000B3C E5 [11] 2111 push hl + 00000B3D 21 04 1B [10] 2112 ld hl, #0x1b04 + 00000B40 E5 [11] 2113 push hl + 00000B41 11r64r10 [10] 2114 ld de, #_decbuf + 00000B44 21r64r02 [10] 2115 ld hl, #_win_xm + 00000B47 CDr00r00 [17] 2116 call _wc_prsrw_attr + 2117 ;src/main.c:581: put_time(timebuf, samples / 44100UL); + 00000B4A 21 00 00 [10] 2118 ld hl, #0x0000 + 00000B4D E5 [11] 2119 push hl + 00000B4E 21 44 AC [10] 2120 ld hl, #0xac44 + 00000B51 E5 [11] 2121 push hl + 00000B52 DD 5E FC [19] 2122 ld e, -4 (ix) + 00000B55 DD 56 FD [19] 2123 ld d, -3 (ix) + 00000B58 DD 6E FE [19] 2124 ld l, -2 (ix) + 00000B5B DD 66 FF [19] 2125 ld h, -1 (ix) + 00000B5E CDr00r00 [17] 2126 call __divulong + 00000B61 F1 [10] 2127 pop af + 00000B62 E3 [19] 2128 ex (sp),hl + 00000B63 D5 [11] 2129 push de + 00000B64 21r67r10 [10] 2130 ld hl, #_timebuf + 00000B67 CDr68r08 [17] 2131 call _put_time + 2132 ;src/main.c:582: wc_prsrw_attr(&win_xm, timebuf, ROW_TIME, 7, 5, ATTR_VALUE); + 00000B6A 3E 71 [ 7] 2133 ld a, #0x71 + 00000B6C F5 [11] 2134 push af + 00000B6D 33 [ 6] 2135 inc sp + 00000B6E 21 05 00 [10] 2136 ld hl, #0x0005 + 00000B71 E5 [11] 2137 push hl + 00000B72 21 06 07 [10] 2138 ld hl, #0x706 + 00000B75 E5 [11] 2139 push hl + 00000B76 11r67r10 [10] 2140 ld de, #_timebuf + 00000B79 21r64r02 [10] 2141 ld hl, #_win_xm + 00000B7C CDr00r00 [17] 2142 call _wc_prsrw_attr + 2143 ;src/main.c:584: put_time(timebuf, total_samples / 44100UL); + 00000B7F 21 00 00 [10] 2144 ld hl, #0x0000 + 00000B82 E5 [11] 2145 push hl + 00000B83 21 44 AC [10] 2146 ld hl, #0xac44 + 00000B86 E5 [11] 2147 push hl + 00000B87 ED 5Br2Cr10 [20] 2148 ld de, (_total_samples) + 00000B8B 2Ar2Er10 [16] 2149 ld hl, (_total_samples + 2) + 00000B8E CDr00r00 [17] 2150 call __divulong + 00000B91 F1 [10] 2151 pop af + 00000B92 E3 [19] 2152 ex (sp),hl + 00000B93 D5 [11] 2153 push de + 00000B94 21r67r10 [10] 2154 ld hl, #_timebuf + 00000B97 CDr68r08 [17] 2155 call _put_time + 2156 ;src/main.c:585: wc_prsrw_attr(&win_xm, timebuf, ROW_TIME, 15, 5, ATTR_VALUE); + 00000B9A 3E 71 [ 7] 2157 ld a, #0x71 + 00000B9C F5 [11] 2158 push af + 00000B9D 33 [ 6] 2159 inc sp + 00000B9E 21 05 00 [10] 2160 ld hl, #0x0005 + 00000BA1 E5 [11] 2161 push hl + 00000BA2 21 06 0F [10] 2162 ld hl, #0xf06 + 00000BA5 E5 [11] 2163 push hl + 00000BA6 11r67r10 [10] 2164 ld de, #_timebuf + 00000BA9 21r64r02 [10] 2165 ld hl, #_win_xm + 00000BAC CDr00r00 [17] 2166 call _wc_prsrw_attr + 2167 ;src/main.c:587: draw_progress_bar(samples, total_samples); + 00000BAF 2Ar2Er10 [16] 2168 ld hl, (_total_samples + 2) + 00000BB2 E5 [11] 2169 push hl + 00000BB3 2Ar2Cr10 [16] 2170 ld hl, (_total_samples) + 00000BB6 E5 [11] 2171 push hl + 00000BB7 DD 5E FC [19] 2172 ld e, -4 (ix) + 00000BBA DD 56 FD [19] 2173 ld d, -3 (ix) + 00000BBD DD 6E FE [19] 2174 ld l, -2 (ix) + 00000BC0 DD 66 FF [19] 2175 ld h, -1 (ix) + 00000BC3 CDrD7r09 [17] 2176 call _draw_progress_bar + 2177 ;src/main.c:589: } + 00000BC6 DD F9 [10] 2178 ld sp, ix + 00000BC8 DD E1 [14] 2179 pop ix + 00000BCA C9 [10] 2180 ret + 2181 ;src/main.c:591: void main_start() + 2182 ; --------------------------------- + 2183 ; Function main_start + 2184 ; --------------------------------- + 00000BCB 2185 _main_start:: + 00000BCB 3B [ 6] 2186 dec sp + 2187 ;src/main.c:595: copy_file_name(); + 00000BCC CDr06r06 [17] 2188 call _copy_file_name + 2189 ;src/main.c:607: wc_prwow(&win_xm); + 00000BCF 21r64r02 [10] 2190 ld hl, #_win_xm + 00000BD2 CDr00r00 [17] 2191 call _wc_prwow + 2192 ;src/main.c:608: xm_draw_static_labels(); + 00000BD5 CDr2Br06 [17] 2193 call _xm_draw_static_labels + 2194 ;src/main.c:609: xm_set_status("Loading, please wait..."); + 00000BD8 21r84r0C [10] 2195 ld hl, #___str_17 + 00000BDB CDr0Er07 [17] 2196 call _xm_set_status + 2197 ;src/main.c:611: if (state_esp == 0xFF) + 00000BDE 3Ar00r00 [13] 2198 ld a, (_state_esp) + 00000BE1 3C [ 4] 2199 inc a + 00000BE2 20 0D [12] 2200 jr nz, 00102$ + 2201 ;src/main.c:612: state_esp = esp_init() ? 1 : 2; + 00000BE4 CDr57r02 [17] 2202 call _esp_init + 00000BE7 B7 [ 4] 2203 or a, a + 00000BE8 3E 01 [ 7] 2204 ld a, #0x01 + 00000BEA 20 02 [12] 2205 jr nz, 00126$ + 00000BEC 3E 02 [ 7] 2206 ld a, #0x02 + 00000BEE 2207 00126$: + 00000BEE 32r00r00 [13] 2208 ld (#_state_esp), a + 00000BF1 2209 00102$: + 2210 ;src/main.c:614: if (state_esp != 1) + 00000BF1 3Ar00r00 [13] 2211 ld a, (_state_esp) + 00000BF4 3D [ 4] 2212 dec a + 00000BF5 28 07 [12] 2213 jr z, 00104$ + 2214 ;src/main.c:616: error_esp(); + 00000BF7 33 [ 6] 2215 inc sp + 00000BF8 C3r6Dr05 [10] 2216 jp _error_esp + 2217 ;src/main.c:617: return; + 00000BFB C3r82r0C [10] 2218 jp 00123$ + 00000BFE 2219 00104$: + 2220 ;src/main.c:620: total_samples = 0; + 00000BFE AF [ 4] 2221 xor a, a + 00000BFF 32r2Cr10 [13] 2222 ld (_total_samples+0), a + 00000C02 32r2Dr10 [13] 2223 ld (_total_samples+1), a + 00000C05 32r2Er10 [13] 2224 ld (_total_samples+2), a + 00000C08 32r2Fr10 [13] 2225 ld (_total_samples+3), a + 2226 ;src/main.c:622: if (!play_xm()) + 00000C0B CDrBEr02 [17] 2227 call _play_xm + 00000C0E B7 [ 4] 2228 or a, a + 00000C0F 20 12 [12] 2229 jr nz, 00109$ + 2230 ;src/main.c:624: if (last_esp_status == ESP_ERR_OUT_OF_MEMORY) + 00000C11 3Ar08r10 [13] 2231 ld a, (_last_esp_status) + 00000C14 D6 99 [ 7] 2232 sub a, #0x99 + 00000C16 20 07 [12] 2233 jr nz, 00106$ + 2234 ;src/main.c:625: error_oom(); + 00000C18 33 [ 6] 2235 inc sp + 00000C19 C3rA0r05 [10] 2236 jp _error_oom + 00000C1C C3r82r0C [10] 2237 jp 00123$ + 00000C1F 2238 00106$: + 2239 ;src/main.c:627: error_playback(); + 00000C1F 33 [ 6] 2240 inc sp + 2241 ;src/main.c:628: return; + 00000C20 C3rD3r05 [10] 2242 jp _error_playback + 00000C23 2243 00109$: + 2244 ;src/main.c:631: xm_set_status("Playing"); + 00000C23 21r9Cr0C [10] 2245 ld hl, #___str_18 + 00000C26 CDr0Er07 [17] 2246 call _xm_set_status + 2247 ;src/main.c:632: xm_draw_stats_labels(); + 00000C29 CDr15r09 [17] 2248 call _xm_draw_stats_labels + 2249 ;src/main.c:633: last_track_status = TRACK_OBJ_ST_PLAYING; + 00000C2C 21r31r10 [10] 2250 ld hl, #_last_track_status + 00000C2F 36 21 [10] 2251 ld (hl), #0x21 + 2252 ;src/main.c:634: xm_update_info(); + 00000C31 CDr4Dr0A [17] 2253 call _xm_update_info + 2254 ;src/main.c:636: frame_ctr = 0; + 00000C34 FD 21 00 00 [14] 2255 ld iy, #0 + 00000C38 FD 39 [15] 2256 add iy, sp + 00000C3A FD 36 00 00 [19] 2257 ld 0 (iy), #0x00 + 2258 ;src/main.c:639: while (1) + 00000C3E 2259 00121$: + 2260 ;src/main.c:643: __endasm; + 00000C3E 76 [ 4] 2261 halt + 2262 ;src/main.c:645: if (++frame_ctr >= 10) // ~5 updates/sec at 50Hz + 00000C3F FD 21 00 00 [14] 2263 ld iy, #0 + 00000C43 FD 39 [15] 2264 add iy, sp + 00000C45 FD 34 00 [23] 2265 inc 0 (iy) + 00000C48 FD 7E 00 [19] 2266 ld a, 0 (iy) + 00000C4B D6 0A [ 7] 2267 sub a, #0x0a + 00000C4D 38 07 [12] 2268 jr c, 00111$ + 2269 ;src/main.c:647: frame_ctr = 0; + 00000C4F FD 36 00 00 [19] 2270 ld 0 (iy), #0x00 + 2271 ;src/main.c:648: xm_update_info(); + 00000C53 CDr4Dr0A [17] 2272 call _xm_update_info + 00000C56 2273 00111$: + 2274 ;src/main.c:651: if (wc_key_pgdn()) // PgDn - unload and go to next file + 00000C56 CDr00r00 [17] 2275 call _wc_key_pgdn + 00000C59 B7 [ 4] 2276 or a, a + 00000C5A 28 05 [12] 2277 jr z, 00113$ + 2278 ;src/main.c:652: unload_and_exit(WC_NEXT_FILE); + 00000C5C 3E 02 [ 7] 2279 ld a, #0x02 + 00000C5E CDr0Er05 [17] 2280 call _unload_and_exit + 00000C61 2281 00113$: + 2282 ;src/main.c:654: if (wc_key_pgup()) // PgUp - unload and go to previous file + 00000C61 CDr00r00 [17] 2283 call _wc_key_pgup + 00000C64 B7 [ 4] 2284 or a, a + 00000C65 28 05 [12] 2285 jr z, 00115$ + 2286 ;src/main.c:655: unload_and_exit(WC_PREV_FILE); + 00000C67 3E 04 [ 7] 2287 ld a, #0x04 + 00000C69 CDr0Er05 [17] 2288 call _unload_and_exit + 00000C6C 2289 00115$: + 2290 ;src/main.c:657: if (wc_key_esc()) // Esc - unload and exit + 00000C6C CDr00r00 [17] 2291 call _wc_key_esc + 00000C6F B7 [ 4] 2292 or a, a + 00000C70 28 04 [12] 2293 jr z, 00117$ + 2294 ;src/main.c:658: unload_and_exit(WC_EXIT); + 00000C72 AF [ 4] 2295 xor a, a + 00000C73 CDr0Er05 [17] 2296 call _unload_and_exit + 00000C76 2297 00117$: + 2298 ;src/main.c:660: if (wc_key_space()) // Space - leave the track playing, just exit + 00000C76 CDr00r00 [17] 2299 call _wc_key_space + 00000C79 B7 [ 4] 2300 or a, a + 00000C7A 28 C2 [12] 2301 jr z, 00121$ + 2302 ;src/main.c:661: leave_playing_and_exit(); + 00000C7C CDr3Fr05 [17] 2303 call _leave_playing_and_exit + 00000C7F C3r3Er0C [10] 2304 jp 00121$ + 00000C82 2305 00123$: + 2306 ;src/main.c:663: } + 00000C82 33 [ 6] 2307 inc sp + 00000C83 C9 [10] 2308 ret + 00000C84 2309 ___str_17: + 00000C84 4C 6F 61 64 69 6E 67 2310 .ascii "Loading, please wait..." + 2C 20 70 6C 65 61 73 + 65 20 77 61 69 74 2E + 2E 2E + 00000C9B 00 2311 .db 0x00 + 00000C9C 2312 ___str_18: + 00000C9C 50 6C 61 79 69 6E 67 2313 .ascii "Playing" + 00000CA3 00 2314 .db 0x00 + 2315 ;src/main.c:666: void main() + 2316 ; --------------------------------- + 2317 ; Function main + 2318 ; --------------------------------- + 00000CA4 2319 _main:: + 2320 ;src/main.c:676: __endasm; + 00000CA4 ED 73r00r10 [20] 2321 ld (_ret_sp), sp + 00000CA8 32r07r10 [13] 2322 ld (_call_type), a + 00000CAB ED 43r09r10 [20] 2323 ld (_p_file_name), bc + 00000CAF 08 [ 4] 2324 ex af, af + 00000CB0 32r06r10 [13] 2325 ld (_file_ext), a + 00000CB3 22r02r10 [16] 2326 ld (_filesize), hl + 00000CB6 ED 53r04r10 [20] 2327 ld (_filesize + 2), de + 2328 ;src/main.c:678: switch (call_type) + 00000CBA 3Ar07r10 [13] 2329 ld a, (_call_type+0) + 00000CBD B7 [ 4] 2330 or a, a + 00000CBE CArCBr0B [10] 2331 jp z, _main_start + 00000CC1 3Ar07r10 [13] 2332 ld a, (_call_type) + 00000CC4 D6 03 [ 7] 2333 sub a, #0x03 + 00000CC6 CArFBr04 [10] 2334 jp z, _about + 2335 ;src/main.c:680: case WC_CALL_EXT: + 2336 ;src/main.c:681: main_start(); + 2337 ;src/main.c:682: break; + 2338 ;src/main.c:684: case WC_CALL_MENU: + 2339 ;src/main.c:685: about(); + 2340 ;src/main.c:686: break; + 2341 ;src/main.c:688: default: + 2342 ;src/main.c:689: wc_exit(WC_EXIT); + 00000CC9 AF [ 4] 2343 xor a, a + 2344 ;src/main.c:690: } + 2345 ;src/main.c:691: } + 00000CCA C3r00r00 [10] 2346 jp _wc_exit + 2347 .area _CODE + 2348 .area _INITIALIZER + 00000000 2349 __xinit__state_esp: + 00000000 FF 2350 .db #0xff ; 255 + 2351 .area _CABS (ABS) diff --git a/obj/out.map b/obj/out.map index 2dd9944..f878d52 100644 --- a/obj/out.map +++ b/obj/out.map @@ -7,7 +7,7 @@ Area Addr Size Decimal Bytes (A Value Global Global Defined In Module ----- -------------------------------- ------------------------ - 00000000 .__.ABS. mul + 00000000 .__.ABS. wc_key_pgup 00000000 l__BSEG 00000000 l__BSS 00000000 l__CABS @@ -23,98 +23,103 @@ Area Addr Size Decimal Bytes (A 00000001 l__INITIALIZED 00000001 l__INITIALIZER 00000003 l__HEADER0 - 000001ED l__HOME - 00000C33 l__CODE - 0000105E l__DATA + 0000010A l__HOME + 00000E21 l__CODE + 0000108E l__DATA 00008003 s__CODE 0000A800 s__DATA - 0000B85E s__INITIALIZED - 0000B85F s__HOME - 0000BA4C s__GSFINAL - 0000BA4C s__GSINIT - 0000BA4C s__INITIALIZER - 0000BA4D s__BSEG - 0000BA4D s__BSS - 0000BA4D s__HEAP + 0000B88E s__INITIALIZED + 0000B88F s__HOME + 0000B999 s__GSFINAL + 0000B999 s__GSINIT + 0000B999 s__INITIALIZER + 0000B99A s__BSEG + 0000B99A s__BSS + 0000B99A s__HEAP ASxxxx Linker V05.50.4-SDLD, page 2. Hexadecimal [32-Bits] Area Addr Size Decimal Bytes (Attributes) -------------------------------- ---- ---- ------- ----- ------------ -_CODE 00008003 00000C33 = 3123. bytes (REL,CON) +_CODE 00008003 00000E21 = 3617. bytes (REL,CON) Value Global Global Defined In Module ----- -------------------------------- ------------------------ 00008003 _wc_exit main - 00008008 _wc_set_freq_14mhz main - 00008011 _esp_cmd main - 0000802A _esp_rd_reg8 main - 00008043 _esp_rd_reg32 main - 000080B1 _esp_rd_regs main - 000080DD _esp_wr_reg8 main - 000080F4 _esp_wr_reg32 main - 00008124 _esp_wr_end main - 00008133 _esp_send_dma main - 00008197 _esp_rd_end main - 000081A6 _esp_wait_status main - 000081E1 _esp_wait_busy main - 00008203 _esp_create_obj main - 00008231 _esp_init main - 0000823E _err_no_esp main - 00008250 _err_out_of_mem main - 00008262 _err_playback main - 00008274 _win_xm main - 00008286 _win_about main - 00008335 _play_xm main - 00008568 _wait_esc_key main - 00008570 _wait_frames main - 00008579 _about main - 0000858C _error_esp main - 0000859F _error_oom main - 000085B5 _error_playback main - 000085CB _copy_file_name main - 000085F0 _xm_draw_static_labels main - 00008620 _put_hex2 main - 0000865D _put_dec3 main - 000086BA _put_time main - 00008767 _xm_draw_stats_labels main - 000087E0 _draw_progress_bar main - 00008863 _xm_update_info main - 000089D3 _main_start main - 00008AE0 _main main - 00008B09 __divuchar divunsigned - 00008B0B __divu8 divunsigned - 00008B0E __divu16 divunsigned - 00008B0E __divuint divunsigned - 00008B3D _wc_load512 wc_load512 - 00008B52 __moduchar modunsigned - 00008B59 __moduint modunsigned - 00008B5E _wc_prsrw wc_prsrw - 00008B94 _wc_prwow wc_prwow - 00008BA1 _wc_key_pgdn wc_key_pgdn - 00008BAB _wc_prsrw_attr wc_prsrw_attr - 00008BF2 _wc_rresb wc_rresb - 00008BFF _strlen strlen + 00008008 _esp_cmd main + 00008021 _esp_rd_reg8 main + 0000803A _esp_rd_reg32 main + 000080A8 _esp_rd_regs main + 000080D4 _esp_wr_reg8 main + 000080EB _esp_wr_reg32 main + 0000811B _esp_wr_end main + 0000812A _esp_send_dma main + 0000818B _esp_rd_end main + 0000819A _esp_wait_status main + 000081E8 _esp_wait_busy main + 0000822F _esp_create_obj main + 0000825A _esp_init main + 00008267 _win_xm main + 00008279 _win_about main + 000082C1 _play_xm main + 000084ED _wait_esc_key main + 000084F5 _wait_frames main + 000084FE _about main + 00008511 _unload_and_exit main + 00008542 _leave_playing_and_exit main + 0000854C _wait_for_manual_exit main + 00008570 _error_esp main + 00008597 _stop_on_error main + 000085A3 _error_oom main + 000085D6 _error_playback main + 00008609 _copy_file_name main + 0000862E _xm_draw_static_labels main + 000086AD _xm_set_status_attr main + 00008711 _xm_set_status main + 00008719 _xm_set_status_code main + 000087D1 _put_hex2 main + 0000880E _put_dec3 main + 0000886B _put_time main + 00008918 _xm_draw_stats_labels main + 000089DA _draw_progress_bar main + 00008A50 _xm_update_info main + 00008BCE _main_start main + 00008CA7 _main main + 00008CD0 __divuchar divunsigned + 00008CD2 __divu8 divunsigned + 00008CD5 __divu16 divunsigned + 00008CD5 __divuint divunsigned + 00008D04 _wc_key_space wc_key_space + 00008D0E _wc_load512 wc_load512 + 00008D23 __moduchar modunsigned + 00008D2A __moduint modunsigned + 00008D2F _wc_prsrw wc_prsrw + 00008D65 _wc_prwow wc_prwow ASxxxx Linker V05.50.4-SDLD, page 3. Hexadecimal [32-Bits] Area Addr Size Decimal Bytes (Attributes) -------------------------------- ---- ---- ------- ----- ------------ -_CODE 00008003 00000C33 = 3123. bytes (REL,CON) +_CODE 00008003 00000E21 = 3617. bytes (REL,CON) Value Global Global Defined In Module ----- -------------------------------- ------------------------ - 00008C0B _wc_key_esc wc_key_esc - 00008C15 _wc_key_pgup wc_key_pgup - 00008C1F __mulint mul - 00008C21 __mul16 mul + 00008D72 _wc_prm_pl wc_prm_pl + 00008D81 _wc_key_pgdn wc_key_pgdn + 00008D8B _wc_gadrw wc_gadrw + 00008DB0 _wc_prsrw_attr wc_prsrw_attr + 00008DF7 _wc_rresb wc_rresb + 00008E04 _strlen strlen + 00008E10 _wc_key_esc wc_key_esc + 00008E1A _wc_key_pgup wc_key_pgup + ASxxxx Linker V05.50.4-SDLD, page 4. Hexadecimal [32-Bits] Area Addr Size Decimal Bytes (Attributes) -------------------------------- ---- ---- ------- ----- ------------ -_DATA 0000A800 0000105E = 4190. bytes (REL,CON) +_DATA 0000A800 0000108E = 4238. bytes (REL,CON) Value Global Global Defined In Module ----- -------------------------------- ------------------------ @@ -129,36 +134,36 @@ _DATA 0000A800 0000105E = 4190. bytes (R 0000B82C _total_samples main 0000B830 _xm_handle main 0000B831 _last_track_status main - + 0000B88C _bar_attr_ofs main ASxxxx Linker V05.50.4-SDLD, page 5. Hexadecimal [32-Bits] Area Addr Size Decimal Bytes (Attributes) -------------------------------- ---- ---- ------- ----- ------------ -_INITIALIZED 0000B85E 00000001 = 1. bytes (REL,CON) +_INITIALIZED 0000B88E 00000001 = 1. bytes (REL,CON) Value Global Global Defined In Module ----- -------------------------------- ------------------------ - 0000B85E _state_esp main + 0000B88E _state_esp main ASxxxx Linker V05.50.4-SDLD, page 6. Hexadecimal [32-Bits] Area Addr Size Decimal Bytes (Attributes) -------------------------------- ---- ---- ------- ----- ------------ -_HOME 0000B85F 000001ED = 493. bytes (REL,CON) +_HOME 0000B88F 0000010A = 266. bytes (REL,CON) Value Global Global Defined In Module ----- -------------------------------- ------------------------ - 0000B85F __modulong _modulong - 0000B8E6 __divulong _divulong - 0000B969 __mullong _mullong + 0000B88F __modulong _modulong + 0000B916 __divulong _divulong + ASxxxx Linker V05.50.4-SDLD, page 7. Hexadecimal [32-Bits] Area Addr Size Decimal Bytes (Attributes) -------------------------------- ---- ---- ------- ----- ------------ -_INITIALIZER 0000BA4C 00000001 = 1. bytes (REL,CON) +_INITIALIZER 0000B999 00000001 = 1. bytes (REL,CON) Value Global Global Defined In Module ----- -------------------------------- ------------------------ @@ -182,20 +187,21 @@ obj/crt0.rel [ crt0 ] Libraries Linked [ object file ] E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ divunsigned.rel ] +vgm_wc_api.lib [ wc_key_space.rel ] vgm_wc_api.lib [ wc_load512.rel ] E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ modunsigned.rel ] vgm_wc_api.lib [ wc_prsrw.rel ] vgm_wc_api.lib [ wc_prwow.rel ] +vgm_wc_api.lib [ wc_prm_pl.rel ] E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ _modulong.rel ] E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ _divulong.rel ] vgm_wc_api.lib [ wc_key_pgdn.rel ] +vgm_wc_api.lib [ wc_gadrw.rel ] vgm_wc_api.lib [ wc_prsrw_attr.rel ] vgm_wc_api.lib [ wc_rresb.rel ] E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ strlen.rel ] vgm_wc_api.lib [ wc_key_esc.rel ] vgm_wc_api.lib [ wc_key_pgup.rel ] -E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ _mullong.rel ] -E:\SDCC\4.6.0\bin\..\lib\z80/z80.lib [ mul.rel ] ASxxxx Linker V05.50.4-SDLD, page 10. diff --git a/obj/out.noi b/obj/out.noi index c865ac5..d9c2f6a 100644 --- a/obj/out.noi +++ b/obj/out.noi @@ -14,73 +14,77 @@ DEF s__HEADER0 0x0 DEF l__INITIALIZED 0x1 DEF l__INITIALIZER 0x1 DEF l__HEADER0 0x3 -DEF l__HOME 0x1ED -DEF l__CODE 0xC33 -DEF l__DATA 0x105E +DEF l__HOME 0x10A +DEF l__CODE 0xE21 +DEF l__DATA 0x108E DEF s__CODE 0x8003 DEF s__DATA 0xA800 -DEF s__INITIALIZED 0xB85E -DEF s__HOME 0xB85F -DEF s__GSFINAL 0xBA4C -DEF s__GSINIT 0xBA4C -DEF s__INITIALIZER 0xBA4C -DEF s__BSEG 0xBA4D -DEF s__BSS 0xBA4D -DEF s__HEAP 0xBA4D +DEF s__INITIALIZED 0xB88E +DEF s__HOME 0xB88F +DEF s__GSFINAL 0xB999 +DEF s__GSINIT 0xB999 +DEF s__INITIALIZER 0xB999 +DEF s__BSEG 0xB99A +DEF s__BSS 0xB99A +DEF s__HEAP 0xB99A DEF _wc_exit 0x8003 -DEF _wc_set_freq_14mhz 0x8008 -DEF _esp_cmd 0x8011 -DEF _esp_rd_reg8 0x802A -DEF _esp_rd_reg32 0x8043 -DEF _esp_rd_regs 0x80B1 -DEF _esp_wr_reg8 0x80DD -DEF _esp_wr_reg32 0x80F4 -DEF _esp_wr_end 0x8124 -DEF _esp_send_dma 0x8133 -DEF _esp_rd_end 0x8197 -DEF _esp_wait_status 0x81A6 -DEF _esp_wait_busy 0x81E1 -DEF _esp_create_obj 0x8203 -DEF _esp_init 0x8231 -DEF _err_no_esp 0x823E -DEF _err_out_of_mem 0x8250 -DEF _err_playback 0x8262 -DEF _win_xm 0x8274 -DEF _win_about 0x8286 -DEF _play_xm 0x8335 -DEF _wait_esc_key 0x8568 -DEF _wait_frames 0x8570 -DEF _about 0x8579 -DEF _error_esp 0x858C -DEF _error_oom 0x859F -DEF _error_playback 0x85B5 -DEF _copy_file_name 0x85CB -DEF _xm_draw_static_labels 0x85F0 -DEF _put_hex2 0x8620 -DEF _put_dec3 0x865D -DEF _put_time 0x86BA -DEF _xm_draw_stats_labels 0x8767 -DEF _draw_progress_bar 0x87E0 -DEF _xm_update_info 0x8863 -DEF _main_start 0x89D3 -DEF _main 0x8AE0 -DEF __divuchar 0x8B09 -DEF __divu8 0x8B0B -DEF __divu16 0x8B0E -DEF __divuint 0x8B0E -DEF _wc_load512 0x8B3D -DEF __moduchar 0x8B52 -DEF __moduint 0x8B59 -DEF _wc_prsrw 0x8B5E -DEF _wc_prwow 0x8B94 -DEF _wc_key_pgdn 0x8BA1 -DEF _wc_prsrw_attr 0x8BAB -DEF _wc_rresb 0x8BF2 -DEF _strlen 0x8BFF -DEF _wc_key_esc 0x8C0B -DEF _wc_key_pgup 0x8C15 -DEF __mulint 0x8C1F -DEF __mul16 0x8C21 +DEF _esp_cmd 0x8008 +DEF _esp_rd_reg8 0x8021 +DEF _esp_rd_reg32 0x803A +DEF _esp_rd_regs 0x80A8 +DEF _esp_wr_reg8 0x80D4 +DEF _esp_wr_reg32 0x80EB +DEF _esp_wr_end 0x811B +DEF _esp_send_dma 0x812A +DEF _esp_rd_end 0x818B +DEF _esp_wait_status 0x819A +DEF _esp_wait_busy 0x81E8 +DEF _esp_create_obj 0x822F +DEF _esp_init 0x825A +DEF _win_xm 0x8267 +DEF _win_about 0x8279 +DEF _play_xm 0x82C1 +DEF _wait_esc_key 0x84ED +DEF _wait_frames 0x84F5 +DEF _about 0x84FE +DEF _unload_and_exit 0x8511 +DEF _leave_playing_and_exit 0x8542 +DEF _wait_for_manual_exit 0x854C +DEF _error_esp 0x8570 +DEF _stop_on_error 0x8597 +DEF _error_oom 0x85A3 +DEF _error_playback 0x85D6 +DEF _copy_file_name 0x8609 +DEF _xm_draw_static_labels 0x862E +DEF _xm_set_status_attr 0x86AD +DEF _xm_set_status 0x8711 +DEF _xm_set_status_code 0x8719 +DEF _put_hex2 0x87D1 +DEF _put_dec3 0x880E +DEF _put_time 0x886B +DEF _xm_draw_stats_labels 0x8918 +DEF _draw_progress_bar 0x89DA +DEF _xm_update_info 0x8A50 +DEF _main_start 0x8BCE +DEF _main 0x8CA7 +DEF __divuchar 0x8CD0 +DEF __divu8 0x8CD2 +DEF __divu16 0x8CD5 +DEF __divuint 0x8CD5 +DEF _wc_key_space 0x8D04 +DEF _wc_load512 0x8D0E +DEF __moduchar 0x8D23 +DEF __moduint 0x8D2A +DEF _wc_prsrw 0x8D2F +DEF _wc_prwow 0x8D65 +DEF _wc_prm_pl 0x8D72 +DEF _wc_key_pgdn 0x8D81 +DEF _wc_gadrw 0x8D8B +DEF _wc_prsrw_attr 0x8DB0 +DEF _wc_rresb 0x8DF7 +DEF _strlen 0x8E04 +DEF _wc_key_esc 0x8E10 +DEF _wc_key_pgup 0x8E1A DEF _fs_buf 0xA800 DEF _ret_sp 0xB800 DEF _filesize 0xB802 @@ -92,8 +96,8 @@ DEF _file_name 0xB80B DEF _total_samples 0xB82C DEF _xm_handle 0xB830 DEF _last_track_status 0xB831 -DEF _state_esp 0xB85E -DEF __modulong 0xB85F -DEF __divulong 0xB8E6 -DEF __mullong 0xB969 +DEF _bar_attr_ofs 0xB88C +DEF _state_esp 0xB88E +DEF __modulong 0xB88F +DEF __divulong 0xB916 LOAD obj/out.ihx diff --git a/obj/out.rel b/obj/out.rel index f230060..fcf7683 100644 --- a/obj/out.rel +++ b/obj/out.rel @@ -1,67 +1,73 @@ XL4 -H 9 areas 42 global symbols +H 9 areas 48 global symbols M main O -mz80 sdcccall(1) S __divuint Ref00000000 +S _wc_key_space Ref00000000 S _wc_load512 Ref00000000 S __moduchar Ref00000000 S __divuchar Ref00000000 S _wc_prsrw Ref00000000 S _wc_prwow Ref00000000 S .__.ABS. Def00000000 +S _wc_prm_pl Ref00000000 S __modulong Ref00000000 S __divulong Ref00000000 S _wc_key_pgdn Ref00000000 +S _wc_gadrw Ref00000000 S _wc_prsrw_attr Ref00000000 S _wc_rresb Ref00000000 S _strlen Ref00000000 S _wc_key_esc Ref00000000 -S __mullong Ref00000000 S _wc_key_pgup Ref00000000 S __moduint Ref00000000 -A _CODE size B06 flags 0 addr 0 -S _esp_send_dma Def00000130 -S _wc_set_freq_14mhz Def00000005 -S _esp_wr_reg8 Def000000DA -S _main Def00000ADD -S _esp_wr_end Def00000121 -S _put_time Def000006B7 -S _xm_draw_static_labels Def000005ED -S _err_no_esp Def0000023B -S _err_playback Def0000025F -S _put_hex2 Def0000061D -S _main_start Def000009D0 +A _CODE size CCD flags 0 addr 0 +S _esp_send_dma Def00000127 +S _esp_wr_reg8 Def000000D1 +S _main Def00000CA4 +S _esp_wr_end Def00000118 +S _put_time Def00000868 +S _xm_draw_static_labels Def0000062B +S _xm_set_status_attr Def000006AA +S _unload_and_exit Def0000050E +S _put_hex2 Def000007CE +S _main_start Def00000BCB S _wc_exit Def00000000 -S _esp_create_obj Def00000200 -S _wait_esc_key Def00000565 -S _play_xm Def00000332 -S _copy_file_name Def000005C8 -S _esp_wait_busy Def000001DE -S _esp_rd_reg32 Def00000040 -S _win_about Def00000283 -S _esp_rd_regs Def000000AE -S _error_playback Def000005B2 -S _error_esp Def00000589 -S _err_out_of_mem Def0000024D -S _win_xm Def00000271 -S _esp_rd_reg8 Def00000027 -S _esp_wr_reg32 Def000000F1 -S _wait_frames Def0000056D -S _xm_draw_stats_labels Def00000764 -S _xm_update_info Def00000860 -S _esp_rd_end Def00000194 -S _error_oom Def0000059C -S _draw_progress_bar Def000007DD -S _put_dec3 Def0000065A -S _esp_cmd Def0000000E -S _esp_init Def0000022E -S _about Def00000576 -S _esp_wait_status Def000001A3 -A _DATA size 105E flags 0 addr 0 +S _esp_create_obj Def0000022C +S _wait_esc_key Def000004EA +S _play_xm Def000002BE +S _copy_file_name Def00000606 +S _esp_wait_busy Def000001E5 +S _esp_rd_reg32 Def00000037 +S _win_about Def00000276 +S _leave_playing_and_exit Def0000053F +S _stop_on_error Def00000594 +S _xm_set_status_code Def00000716 +S _esp_rd_regs Def000000A5 +S _error_playback Def000005D3 +S _wait_for_manual_exit Def00000549 +S _error_esp Def0000056D +S _win_xm Def00000264 +S _esp_rd_reg8 Def0000001E +S _esp_wr_reg32 Def000000E8 +S _wait_frames Def000004F2 +S _xm_draw_stats_labels Def00000915 +S _xm_update_info Def00000A4D +S _xm_set_status Def0000070E +S _esp_rd_end Def00000188 +S _error_oom Def000005A0 +S _draw_progress_bar Def000009D7 +S _put_dec3 Def0000080B +S _esp_cmd Def00000005 +S _esp_init Def00000257 +S _about Def000004FB +S _esp_wait_status Def00000197 +A _DATA size 108E flags 0 addr 0 S _last_track_status Def00001031 S _p_file_name Def00001009 S _xm_handle Def00001030 S _fs_buf Def00000000 +S _bar_attr_ofs Def0000108C S _total_samples Def0000102C S _call_type Def00001007 S _ret_sp Def00001000 @@ -125,17 +131,29 @@ T 32 10 00 00 R 00 00 01 00 T 32 10 00 00 R 00 00 01 00 -T 34 10 00 00 +T 4A 10 00 00 R 00 00 01 00 -T 34 10 00 00 +T 4A 10 00 00 R 00 00 01 00 -T 37 10 00 00 +T 62 10 00 00 R 00 00 01 00 -T 37 10 00 00 +T 62 10 00 00 R 00 00 01 00 -T 3C 10 00 00 +T 64 10 00 00 R 00 00 01 00 -T 3C 10 00 00 +T 64 10 00 00 +R 00 00 01 00 +T 67 10 00 00 +R 00 00 01 00 +T 67 10 00 00 +R 00 00 01 00 +T 6C 10 00 00 +R 00 00 01 00 +T 6C 10 00 00 +R 00 00 01 00 +T 8C 10 00 00 +R 00 00 01 00 +T 8C 10 00 00 R 00 00 01 00 T 00 00 00 00 R 00 00 02 00 @@ -147,747 +165,909 @@ T 00 00 00 00 ED 7B 00 10 C9 R 00 00 00 00 00 06 01 00 T 05 00 00 00 R 00 00 00 00 -T 05 00 00 00 06 00 0E 02 3E 0E C3 06 60 +T 05 00 00 00 4F 3E 13 D3 77 3E 01 D3 57 AF D3 57 R 00 00 00 00 -T 0E 00 00 00 +T 11 00 00 00 DB 57 79 D3 57 AF D3 57 3E 03 D3 77 R 00 00 00 00 -T 0E 00 00 00 4F 3E 13 D3 77 3E 01 D3 57 AF D3 57 +T 1D 00 00 00 C9 R 00 00 00 00 -T 1A 00 00 00 DB 57 79 D3 57 AF D3 57 3E 03 D3 77 +T 1E 00 00 00 R 00 00 00 00 -T 26 00 00 00 C9 +T 1E 00 00 00 4F 3E 13 D3 77 3E 02 D3 57 79 D3 57 R 00 00 00 00 -T 27 00 00 00 +T 2A 00 00 00 DB 57 DB 57 DB 57 4F 3E 03 D3 77 79 R 00 00 00 00 -T 27 00 00 00 4F 3E 13 D3 77 3E 02 D3 57 79 D3 57 +T 36 00 00 00 C9 R 00 00 00 00 -T 33 00 00 00 DB 57 DB 57 DB 57 4F 3E 03 D3 77 79 +T 37 00 00 00 R 00 00 00 00 -T 3F 00 00 00 C9 +T 37 00 00 00 DD E5 DD 21 00 00 DD 39 F5 F5 4F 3E R 00 00 00 00 -T 40 00 00 00 +T 43 00 00 00 13 D3 77 3E 02 D3 57 79 D3 57 DB 57 R 00 00 00 00 -T 40 00 00 00 DD E5 DD 21 00 00 DD 39 F5 F5 4F 3E +T 4F 00 00 00 DB 57 DB 57 4F DB 57 57 59 DB 57 DD R 00 00 00 00 -T 4C 00 00 00 13 D3 77 3E 02 D3 57 79 D3 57 DB 57 +T 5B 00 00 00 77 FC AF DD 77 FD DD 77 FE DD 77 FF R 00 00 00 00 -T 58 00 00 00 DB 57 DB 57 4F DB 57 57 59 DB 57 DD +T 67 00 00 00 DD 7E FC DD 77 FE AF DD 77 FF DD 77 R 00 00 00 00 -T 64 00 00 00 77 FC AF DD 77 FD DD 77 FE DD 77 FF +T 73 00 00 00 FC DD 77 FD DD 6E FE DB 57 DD 77 FC R 00 00 00 00 -T 70 00 00 00 DD 7E FC DD 77 FE AF DD 77 FF DD 77 +T 7F 00 00 00 AF DD 77 FD DD 77 FE DD 77 FF DD 7E R 00 00 00 00 -T 7C 00 00 00 FC DD 77 FD DD 6E FE DB 57 DD 77 FC +T 8B 00 00 00 FC DD 77 FF AF DD 77 FC DD 77 FD DD R 00 00 00 00 -T 88 00 00 00 AF DD 77 FD DD 77 FE DD 77 FF DD 7E +T 97 00 00 00 77 FE DD 66 FF 3E 03 D3 77 DD F9 DD R 00 00 00 00 -T 94 00 00 00 FC DD 77 FF AF DD 77 FC DD 77 FD DD +T A3 00 00 00 E1 C9 R 00 00 00 00 -T A0 00 00 00 77 FE DD 66 FF 3E 03 D3 77 DD F9 DD +T A5 00 00 00 R 00 00 00 00 -T AC 00 00 00 E1 C9 +T A5 00 00 00 4F 3E 13 D3 77 3E 02 D3 57 79 D3 57 R 00 00 00 00 -T AE 00 00 00 +T B1 00 00 00 DB 57 DB 57 FD 21 02 00 FD 39 FD 4E R 00 00 00 00 -T AE 00 00 00 4F 3E 13 D3 77 3E 02 D3 57 79 D3 57 +T BD 00 00 00 00 R 00 00 00 00 -T BA 00 00 00 DB 57 DB 57 FD 21 02 00 FD 39 FD 4E +T BE 00 00 00 R 00 00 00 00 -T C6 00 00 00 00 -R 00 00 00 00 -T C7 00 00 00 -R 00 00 00 00 -T C7 00 00 00 79 0D B7 28 07 DB 57 12 13 C3 C7 00 +T BE 00 00 00 79 0D B7 28 07 DB 57 12 13 C3 BE 00 R 00 00 00 00 00 0E 00 00 -T D3 00 00 00 +T CA 00 00 00 R 00 00 00 00 -T D3 00 00 00 3E 03 D3 77 E1 33 E9 +T CA 00 00 00 3E 03 D3 77 E1 33 E9 R 00 00 00 00 -T DA 00 00 00 +T D1 00 00 00 R 00 00 00 00 -T DA 00 00 00 47 4D 3E 13 D3 77 3E 01 D3 57 78 D3 +T D1 00 00 00 47 4D 3E 13 D3 77 3E 01 D3 57 78 D3 R 00 00 00 00 -T E6 00 00 00 57 DB 57 79 D3 57 3E 03 D3 77 C9 +T DD 00 00 00 57 DB 57 79 D3 57 3E 03 D3 77 C9 R 00 00 00 00 -T F1 00 00 00 +T E8 00 00 00 R 00 00 00 00 -T F1 00 00 00 4F 3E 13 D3 77 3E 01 D3 57 79 D3 57 +T E8 00 00 00 4F 3E 13 D3 77 3E 01 D3 57 79 D3 57 R 00 00 00 00 -T FD 00 00 00 DB 57 FD 21 02 00 FD 39 FD 7E 00 D3 +T F4 00 00 00 DB 57 FD 21 02 00 FD 39 FD 7E 00 D3 R 00 00 00 00 -T 09 01 00 00 57 FD 7E 01 D3 57 FD 7E 02 D3 57 FD +T 00 01 00 00 57 FD 7E 01 D3 57 FD 7E 02 D3 57 FD R 00 00 00 00 -T 15 01 00 00 7E 03 D3 57 3E 03 D3 77 E1 F1 F1 E9 +T 0C 01 00 00 7E 03 D3 57 3E 03 D3 77 E1 F1 F1 E9 R 00 00 00 00 -T 21 01 00 00 +T 18 01 00 00 R 00 00 00 00 -T 21 01 00 00 3E 13 D3 77 3E 07 D3 57 DB 57 3E 03 +T 18 01 00 00 3E 13 D3 77 3E 07 D3 57 DB 57 3E 03 R 00 00 00 00 -T 2D 01 00 00 D3 77 C9 +T 24 01 00 00 D3 77 C9 R 00 00 00 00 -T 30 01 00 00 +T 27 01 00 00 R 00 00 00 00 -T 30 01 00 00 7D 01 AF 1A ED 79 7C 01 AF 1B ED 79 +T 27 01 00 00 7D 01 AF 1A ED 79 7C 01 AF 1B ED 79 R 00 00 00 00 -T 3C 01 00 00 FD 21 02 00 FD 39 FD 7E 00 01 AF 1C +T 33 01 00 00 FD 21 02 00 FD 39 FD 7E 00 01 AF 1C R 00 00 00 00 -T 48 01 00 00 ED 79 FD 7E 01 FD 4E 02 FD 23 CB 39 +T 3F 01 00 00 ED 79 FD 7E 01 FD 4E 02 FD 23 CB 39 R 00 00 00 00 -T 54 01 00 00 CB 1F 3D 01 AF 26 ED 79 FD 7E 02 3D +T 4B 01 00 00 CB 1F 3D 01 AF 26 ED 79 FD 7E 02 3D R 00 00 00 00 -T 60 01 00 00 01 AF 28 ED 79 3E 13 D3 77 3E 03 D3 +T 57 01 00 00 01 AF 28 ED 79 3E 13 D3 77 3E 03 D3 R 00 00 00 00 -T 6C 01 00 00 57 DB 57 DB 57 3E 82 01 AF 27 ED 79 +T 63 01 00 00 57 DB 57 DB 57 3E 82 01 AF 27 ED 79 R 00 00 00 00 -T 78 01 00 00 +T 6F 01 00 00 R 00 00 00 00 -T 78 01 00 00 3E 27 DB AF 07 38 F9 3E 03 D3 77 CD +T 6F 01 00 00 3E 27 DB AF 07 38 F9 3E 03 D3 77 CD R 00 00 00 00 -T 84 01 00 00 21 01 11 60 EA 21 00 00 CD DE 01 E1 -R 00 00 00 00 00 04 00 00 00 0D 00 00 -T 90 01 00 00 F1 F1 33 E9 +T 7B 01 00 00 18 01 21 64 00 CD E5 01 E1 F1 F1 33 +R 00 00 00 00 00 04 00 00 00 0A 00 00 +T 87 01 00 00 E9 R 00 00 00 00 -T 94 01 00 00 +T 88 01 00 00 R 00 00 00 00 -T 94 01 00 00 3E 13 D3 77 3E 08 D3 57 DB 57 3E 03 +T 88 01 00 00 3E 13 D3 77 3E 08 D3 57 DB 57 3E 03 R 00 00 00 00 -T A0 01 00 00 D3 77 C9 +T 94 01 00 00 D3 77 C9 R 00 00 00 00 -T A3 01 00 00 +T 97 01 00 00 R 00 00 00 00 -T A3 01 00 00 DD E5 DD 21 00 00 DD 39 4F DD 5E 04 +T 97 01 00 00 DD E5 DD 21 00 00 DD 39 21 FB FF 39 R 00 00 00 00 -T AF 01 00 00 DD 56 05 DD 6E 06 DD 66 07 +T A3 01 00 00 F9 DD 77 FF DD 73 FD DD 72 FE 21 R 00 00 00 00 -T B8 01 00 00 +T AE 01 00 00 09 60 7E DD 77 FB 23 7E DD 77 FC R 00 00 00 00 -T B8 01 00 00 7B C6 FF 5F 7A CE FF 57 7D CE FF 6F +T B9 01 00 00 R 00 00 00 00 -T C4 01 00 00 7C CE FF 67 B5 B2 B3 28 0E E5 C5 D5 +T B9 01 00 00 2A 09 60 7D DD 96 FB 4F 7C DD 9E FC R 00 00 00 00 -T D0 01 00 00 3E 01 CD 27 00 D1 C1 E1 91 20 DD -R 00 00 00 00 00 07 00 00 -T DB 01 00 00 +T C5 01 00 00 47 79 DD 96 FD 78 DD 9E FE 30 0F 3E R 00 00 00 00 -T DB 01 00 00 DD E1 C9 -R 00 00 00 00 -T DE 01 00 00 -R 00 00 00 00 -T DE 01 00 00 -R 00 00 00 00 -T DE 01 00 00 7B C6 FF 5F 7A CE FF 57 7D CE FF 6F -R 00 00 00 00 -T EA 01 00 00 7C CE FF 67 B5 B2 B3 C8 E5 D5 3E 01 -R 00 00 00 00 -T F6 01 00 00 CD 27 00 D1 E1 FE 02 28 DF C9 -R 00 00 00 00 00 05 00 00 -T 00 02 00 00 -R 00 00 00 00 -T 00 02 00 00 E5 D5 3E 03 CD F1 00 FD 21 02 00 FD -R 00 00 00 00 00 09 00 00 -T 0C 02 00 00 39 FD 6E 00 3E 02 CD DA 00 3E E0 CD -R 00 00 00 00 00 0B 00 00 -T 18 02 00 00 0E 00 11 20 4E 21 00 00 CD DE 01 3E -R 00 00 00 00 00 04 00 00 00 0D 00 00 -T 24 02 00 00 0B CD 27 00 5F 16 00 E1 33 E9 +T D1 01 00 00 01 CD 1E 00 DD 96 FF 20 DF 3E 01 C3 R 00 00 00 00 00 06 00 00 -T 2E 02 00 00 +T DD 01 00 00 E0 01 +R 00 00 00 00 00 04 00 00 +T DF 01 00 00 R 00 00 00 00 -T 2E 02 00 00 AF CD 0E 00 CD 94 01 CD 21 01 3E 01 +T DF 01 00 00 AF +R 00 00 00 00 +T E0 01 00 00 +R 00 00 00 00 +T E0 01 00 00 DD F9 DD E1 C9 +R 00 00 00 00 +T E5 01 00 00 +R 00 00 00 00 +T E5 01 00 00 DD E5 DD 21 00 00 DD 39 F5 F5 DD 75 +R 00 00 00 00 +T F1 01 00 00 FE DD 74 FF 21 09 60 7E DD 77 FC 23 +R 00 00 00 00 +T FD 01 00 00 7E DD 77 FD +R 00 00 00 00 +T 01 02 00 00 +R 00 00 00 00 +T 01 02 00 00 2A 09 60 7D DD 96 FC 4F 7C DD 9E FD +R 00 00 00 00 +T 0D 02 00 00 47 79 DD 96 FE 78 DD 9E FF 30 0E 3E +R 00 00 00 00 +T 19 02 00 00 01 CD 1E 00 FE 02 28 E0 3E 01 C3 +R 00 00 00 00 00 06 00 00 +T 24 02 00 00 27 02 +R 00 00 00 00 00 04 00 00 +T 26 02 00 00 +R 00 00 00 00 +T 26 02 00 00 AF +R 00 00 00 00 +T 27 02 00 00 +R 00 00 00 00 +T 27 02 00 00 DD F9 DD E1 C9 +R 00 00 00 00 +T 2C 02 00 00 +R 00 00 00 00 +T 2C 02 00 00 E5 D5 3E 03 CD E8 00 FD 21 02 00 FD +R 00 00 00 00 00 09 00 00 +T 38 02 00 00 39 FD 6E 00 3E 02 CD D1 00 3E E0 CD +R 00 00 00 00 00 0B 00 00 +T 44 02 00 00 05 00 21 64 00 CD E5 01 3E 0B CD +R 00 00 00 00 00 04 00 00 00 0A 00 00 +T 4F 02 00 00 1E 00 5F 16 00 E1 33 E9 +R 00 00 00 00 00 04 00 00 +T 57 02 00 00 +R 00 00 00 00 +T 57 02 00 00 AF CD 05 00 CD 88 01 CD 18 01 3E 01 R 00 00 00 00 00 06 00 00 00 09 00 00 00 0C 00 00 -T 3A 02 00 00 C9 +T 63 02 00 00 C9 R 00 00 00 00 -T 3B 02 00 00 +T 64 02 00 00 R 00 00 00 00 -T 3B 02 00 00 01 00 18 0A 20 05 2F 00 00 00 00 00 +T 64 02 00 00 81 00 19 0A 28 0C 70 00 00 00 00 00 R 00 00 00 00 -T 47 02 00 00 95 02 9F 02 A0 02 +T 70 02 00 00 88 02 A2 02 A2 02 R 00 00 00 00 00 04 00 00 00 06 00 00 00 08 00 00 -T 4D 02 00 00 +T 76 02 00 00 R 00 00 00 00 -T 4D 02 00 00 01 00 FF FF 20 05 2F 00 00 00 00 00 +T 76 02 00 00 01 00 16 0A 24 05 4F 00 00 00 00 00 R 00 00 00 00 -T 59 02 00 00 95 02 9F 02 B6 02 +T 82 02 00 00 A3 02 A2 02 AC 02 R 00 00 00 00 00 04 00 00 00 06 00 00 00 08 00 00 -T 5F 02 00 00 +T 88 02 00 00 R 00 00 00 00 -T 5F 02 00 00 01 00 FF FF 20 05 2F 00 00 00 00 00 +T 88 02 00 00 0E 20 58 4D 2F 58 4D 5A 2F 53 33 4D R 00 00 00 00 -T 6B 02 00 00 95 02 9F 02 D6 02 -R 00 00 00 00 00 04 00 00 00 06 00 00 00 08 00 00 -T 71 02 00 00 +T 94 02 00 00 20 50 6C 61 79 65 72 20 76 30 2E 31 R 00 00 00 00 -T 71 02 00 00 81 00 19 0A 28 0B 4F 00 00 00 00 00 +T A0 02 00 00 20 00 R 00 00 00 00 -T 7D 02 00 00 F4 02 9F 02 09 03 -R 00 00 00 00 00 04 00 00 00 06 00 00 00 08 00 00 -T 83 02 00 00 +T A2 02 00 00 R 00 00 00 00 -T 83 02 00 00 01 00 16 0A 24 05 4F 00 00 00 00 00 +T A2 02 00 00 00 R 00 00 00 00 -T 8F 02 00 00 17 03 9F 02 20 03 -R 00 00 00 00 00 04 00 00 00 06 00 00 00 08 00 00 -T 95 02 00 00 +T A3 02 00 00 R 00 00 00 00 -T 95 02 00 00 0E 20 45 72 72 6F 72 21 20 00 +T A3 02 00 00 0E 20 41 62 6F 75 74 20 00 R 00 00 00 00 -T 9F 02 00 00 +T AC 02 00 00 R 00 00 00 00 -T 9F 02 00 00 00 +T AC 02 00 00 0E 0C 01 58 4D 20 50 6C 61 79 65 72 R 00 00 00 00 -T A0 02 00 00 +T B8 02 00 00 20 76 30 2E 31 00 R 00 00 00 00 -T A0 02 00 00 0E 0C 01 4E 6F 20 45 53 50 33 32 20 +T BE 02 00 00 R 00 00 00 00 -T AC 02 00 00 64 65 74 65 63 74 65 64 21 00 +T BE 02 00 00 DD E5 DD 21 00 00 DD 39 21 EC FF 39 R 00 00 00 00 -T B6 02 00 00 +T CA 02 00 00 F9 3E A2 CD 05 00 21 64 00 CD E5 01 +R 00 00 00 00 00 08 00 00 00 0E 00 00 +T D6 02 00 00 3E E4 CD 05 00 21 64 00 CD E5 01 3A +R 00 00 00 00 00 07 00 00 00 0D 00 00 +T E2 02 00 00 06 10 3D 28 0A 3A 06 10 D6 02 28 08 +R 00 00 00 00 00 04 01 00 00 0A 01 00 +T EE 02 00 00 C3 FB 02 +R 00 00 00 00 00 05 00 00 +T F1 02 00 00 R 00 00 00 00 -T B6 02 00 00 0E 0C 01 4F 75 74 20 6F 66 20 6D 65 -R 00 00 00 00 -T C2 02 00 00 6D 6F 72 79 20 28 66 69 6C 65 20 74 -R 00 00 00 00 -T CE 02 00 00 6F 6F 20 62 69 67 29 00 -R 00 00 00 00 -T D6 02 00 00 -R 00 00 00 00 -T D6 02 00 00 0E 0C 01 50 6C 61 79 62 61 63 6B 20 -R 00 00 00 00 -T E2 02 00 00 65 72 72 6F 72 20 28 62 61 64 20 66 -R 00 00 00 00 -T EE 02 00 00 69 6C 65 3F 29 00 -R 00 00 00 00 -T F4 02 00 00 -R 00 00 00 00 -T F4 02 00 00 0E 20 58 4D 2F 58 4D 5A 2F 53 33 4D -R 00 00 00 00 -T 00 03 00 00 20 50 6C 61 79 65 72 20 00 -R 00 00 00 00 -T 09 03 00 00 -R 00 00 00 00 -T 09 03 00 00 0E 0C 01 50 6C 61 79 69 6E 67 2E 2E -R 00 00 00 00 -T 15 03 00 00 2E 00 -R 00 00 00 00 -T 17 03 00 00 -R 00 00 00 00 -T 17 03 00 00 0E 20 41 62 6F 75 74 20 00 -R 00 00 00 00 -T 20 03 00 00 -R 00 00 00 00 -T 20 03 00 00 0E 0C 01 58 4D 20 50 6C 61 79 65 72 -R 00 00 00 00 -T 2C 03 00 00 20 76 31 2E 30 00 -R 00 00 00 00 -T 32 03 00 00 -R 00 00 00 00 -T 32 03 00 00 DD E5 DD 21 00 00 DD 39 21 EC FF 39 -R 00 00 00 00 -T 3E 03 00 00 F9 3E A2 CD 0E 00 11 10 27 21 00 00 -R 00 00 00 00 00 08 00 00 -T 4A 03 00 00 CD DE 01 3E E4 CD 0E 00 11 10 27 21 -R 00 00 00 00 00 05 00 00 00 0A 00 00 -T 56 03 00 00 00 00 CD DE 01 3A 06 10 3D 28 0A 3A -R 00 00 00 00 00 07 00 00 00 0A 01 00 -T 62 03 00 00 06 10 D6 02 28 08 C3 75 03 -R 00 00 00 00 00 04 01 00 00 0B 00 00 -T 6B 03 00 00 -R 00 00 00 00 -T 6B 03 00 00 3E 08 C3 77 03 +T F1 02 00 00 3E 08 C3 FD 02 R 00 00 00 00 00 07 00 00 -T 70 03 00 00 +T F6 02 00 00 R 00 00 00 00 -T 70 03 00 00 3E 0C C3 77 03 +T F6 02 00 00 3E 0C C3 FD 02 R 00 00 00 00 00 07 00 00 -T 75 03 00 00 +T FB 02 00 00 R 00 00 00 00 -T 75 03 00 00 3E 05 +T FB 02 00 00 3E 05 R 00 00 00 00 -T 77 03 00 00 +T FD 02 00 00 R 00 00 00 00 -T 77 03 00 00 F5 33 ED 5B 02 10 2A 04 10 CD 00 02 +T FD 02 00 00 F5 33 ED 5B 02 10 2A 04 10 CD 2C 02 R 00 00 00 00 00 08 01 00 00 0B 01 00 00 0E 00 00 -T 83 03 00 00 21 30 10 73 3E 01 CD 27 00 32 08 10 +T 09 03 00 00 21 30 10 73 3E 01 CD 1E 00 32 08 10 R 00 00 00 00 00 05 01 00 00 0B 00 00 00 0E 01 00 -T 8F 03 00 00 3A 08 10 3D 28 04 AF C3 60 05 +T 15 03 00 00 3A 08 10 3D 28 04 AF C3 E5 04 R 00 00 00 00 00 05 01 00 00 0C 00 00 -T 99 03 00 00 +T 1F 03 00 00 R 00 00 00 00 -T 99 03 00 00 21 0C 00 39 EB 21 02 10 01 04 00 ED +T 1F 03 00 00 21 0C 00 39 EB 21 02 10 01 04 00 ED R 00 00 00 00 00 0A 01 00 -T A5 03 00 00 B0 AF DD 77 FC DD 77 FD DD 77 FE DD +T 2B 03 00 00 B0 AF DD 77 FC DD 77 FD DD 77 FE DD R 00 00 00 00 -T B1 03 00 00 77 FF +T 37 03 00 00 77 FF R 00 00 00 00 -T B3 03 00 00 +T 39 03 00 00 R 00 00 00 00 -T B3 03 00 00 DD 7E FB DD B6 FA DD B6 F9 DD B6 F8 +T 39 03 00 00 DD 7E FB DD B6 FA DD B6 F9 DD B6 F8 R 00 00 00 00 -T BF 03 00 00 CA CF 04 DD 7E F9 D6 10 DD 7E FA DE +T 45 03 00 00 CA 4E 04 DD 7E F9 D6 10 DD 7E FA DE R 00 00 00 00 00 05 00 00 -T CB 03 00 00 00 DD 7E FB DE 00 30 11 21 00 00 39 +T 51 03 00 00 00 DD 7E FB DE 00 30 11 21 00 00 39 R 00 00 00 00 -T D7 03 00 00 EB 21 0C 00 39 01 04 00 ED B0 C3 +T 5D 03 00 00 EB 21 0C 00 39 01 04 00 ED B0 C3 R 00 00 00 00 -T E2 03 00 00 F3 03 +T 68 03 00 00 79 03 R 00 00 00 00 00 04 00 00 -T E4 03 00 00 +T 6A 03 00 00 R 00 00 00 00 -T E4 03 00 00 DD 36 EC 00 DD 36 ED 10 AF DD 77 EE +T 6A 03 00 00 DD 36 EC 00 DD 36 ED 10 AF DD 77 EE R 00 00 00 00 -T F0 03 00 00 DD 77 EF +T 76 03 00 00 DD 77 EF R 00 00 00 00 -T F3 03 00 00 +T 79 03 00 00 R 00 00 00 00 -T F3 03 00 00 21 05 00 39 EB 21 00 00 39 01 04 00 +T 79 03 00 00 21 05 00 39 EB 21 00 00 39 01 04 00 R 00 00 00 00 -T FF 03 00 00 ED B0 DD 7E F1 C6 FF DD 7E F2 CE 01 +T 85 03 00 00 ED B0 DD 7E F1 C6 FF DD 7E F2 CE 01 R 00 00 00 00 -T 0B 04 00 00 47 3E 00 CE 00 5F 3E 00 CE 00 57 48 +T 91 03 00 00 47 3E 00 CE 00 5F 3E 00 CE 00 57 48 R 00 00 00 00 -T 17 04 00 00 43 5A CB 3B CB 18 CB 19 DD 71 F7 79 +T 9D 03 00 00 43 5A CB 3B CB 18 CB 19 DD 71 F7 79 R 00 00 00 00 -T 23 04 00 00 F5 33 21 00 00 CD 00 00 21 00 00 E5 -R 00 00 00 00 00 07 01 00 02 0A 01 00 -T 2F 04 00 00 DD 6E F1 DD 66 F2 E5 3E 03 CD F1 00 +T A9 03 00 00 F5 33 21 00 00 CD 00 00 21 00 00 E5 +R 00 00 00 00 00 07 01 00 02 0A 02 00 +T B5 03 00 00 DD 6E F1 DD 66 F2 E5 3E 03 CD E8 00 R 00 00 00 00 00 0E 00 00 -T 3B 04 00 00 DD 6E FE DD 66 FF E5 DD 6E FC DD 66 +T C1 03 00 00 DD 6E FE DD 66 FF E5 DD 6E FC DD 66 R 00 00 00 00 -T 47 04 00 00 FD E5 3E 07 CD F1 00 3E E1 CD 0E 00 +T CD 03 00 00 FD E5 3E 07 CD E8 00 3E E1 CD 05 00 R 00 00 00 00 00 09 00 00 00 0E 00 00 -T 53 04 00 00 21 00 00 E5 21 D0 07 E5 3E 03 CD -R 00 00 00 00 -T 5E 04 00 00 A3 01 F1 F1 DD 7E F7 DD 77 F5 DD 36 -R 00 00 00 00 00 04 00 00 -T 6A 04 00 00 F6 00 3A 02 60 DD 77 F7 DD 6E F5 26 -R 00 00 00 00 -T 76 04 00 00 00 E5 21 00 02 E5 DD 7E F7 F5 33 21 -R 00 00 00 00 -T 82 04 00 00 00 00 CD 30 01 DD 5E F1 DD 56 F2 DD -R 00 00 00 00 00 04 01 00 00 07 00 00 -T 8E 04 00 00 6E FC DD 66 FD 19 DD 75 FC DD 74 FD -R 00 00 00 00 -T 9A 04 00 00 DD 7E FE DD 8E F3 DD 77 FE 30 03 DD -R 00 00 00 00 -T A6 04 00 00 34 FF -R 00 00 00 00 -T A8 04 00 00 -R 00 00 00 00 -T A8 04 00 00 DD 7E F8 DD 96 F1 DD 77 F8 DD 7E F9 -R 00 00 00 00 -T B4 04 00 00 DD 9E F2 DD 77 F9 DD 7E FA DD 9E F3 -R 00 00 00 00 -T C0 04 00 00 DD 77 FA DD 7E FB DD 9E F4 DD 77 FB -R 00 00 00 00 -T CC 04 00 00 C3 B3 03 -R 00 00 00 00 00 05 00 00 -T CF 04 00 00 -R 00 00 00 00 -T CF 04 00 00 3A 06 10 3D 20 3D 3A 30 10 6F 3E 0B -R 00 00 00 00 00 05 01 00 00 0B 01 00 -T DB 04 00 00 CD DA 00 2E 05 3E 02 CD DA 00 2A -R 00 00 00 00 00 05 00 00 00 0C 00 00 -T E6 04 00 00 04 10 E5 2A 02 10 E5 3E 03 CD F1 00 -R 00 00 00 00 00 04 01 00 00 08 01 00 00 0E 00 00 -T F2 04 00 00 3E F2 CD 0E 00 11 10 27 21 00 00 CD -R 00 00 00 00 00 07 00 00 -T FE 04 00 00 DE 01 3E 01 CD 27 00 32 08 10 3A -R 00 00 00 00 00 04 00 00 00 09 00 00 00 0C 01 00 -T 09 05 00 00 08 10 3D 28 04 AF C3 60 05 -R 00 00 00 00 00 04 01 00 00 0B 00 00 -T 12 05 00 00 -R 00 00 00 00 -T 12 05 00 00 3E A0 CD 0E 00 11 40 42 21 0F 00 CD -R 00 00 00 00 00 07 00 00 -T 1E 05 00 00 DE 01 3E 01 CD 27 00 32 08 10 3A -R 00 00 00 00 00 04 00 00 00 09 00 00 00 0C 01 00 -T 29 05 00 00 08 10 3D 28 04 AF C3 60 05 -R 00 00 00 00 00 04 01 00 00 0B 00 00 -T 32 05 00 00 -R 00 00 00 00 -T 32 05 00 00 3A 30 10 6F 3E 0B CD DA 00 2E 01 3E -R 00 00 00 00 00 05 01 00 00 0B 00 00 -T 3E 05 00 00 3A CD DA 00 3E A6 CD 0E 00 11 10 27 -R 00 00 00 00 00 06 00 00 00 0B 00 00 -T 4A 05 00 00 21 00 00 CD DE 01 3E A1 CD 0E 00 11 -R 00 00 00 00 00 08 00 00 00 0D 00 00 -T 56 05 00 00 10 27 21 00 00 CD DE 01 3E 01 +T D9 03 00 00 11 64 00 3E 03 CD 97 01 DD 7E F7 DD R 00 00 00 00 00 0A 00 00 +T E5 03 00 00 77 F5 DD 36 F6 00 3A 02 60 DD 77 F7 +R 00 00 00 00 +T F1 03 00 00 DD 6E F5 26 00 E5 21 00 02 E5 DD 7E +R 00 00 00 00 +T FD 03 00 00 F7 F5 33 21 00 00 CD 27 01 DD 5E F1 +R 00 00 00 00 00 08 01 00 00 0B 00 00 +T 09 04 00 00 DD 56 F2 DD 6E FC DD 66 FD 19 DD 75 +R 00 00 00 00 +T 15 04 00 00 FC DD 74 FD DD 7E FE DD 8E F3 DD 77 +R 00 00 00 00 +T 21 04 00 00 FE 30 03 DD 34 FF +R 00 00 00 00 +T 27 04 00 00 +R 00 00 00 00 +T 27 04 00 00 DD 7E F8 DD 96 F1 DD 77 F8 DD 7E F9 +R 00 00 00 00 +T 33 04 00 00 DD 9E F2 DD 77 F9 DD 7E FA DD 9E F3 +R 00 00 00 00 +T 3F 04 00 00 DD 77 FA DD 7E FB DD 9E F4 DD 77 FB +R 00 00 00 00 +T 4B 04 00 00 C3 39 03 +R 00 00 00 00 00 05 00 00 +T 4E 04 00 00 +R 00 00 00 00 +T 4E 04 00 00 3A 06 10 3D 20 3A 3A 30 10 6F 3E 0B +R 00 00 00 00 00 05 01 00 00 0B 01 00 +T 5A 04 00 00 CD D1 00 2E 05 3E 02 CD D1 00 2A +R 00 00 00 00 00 05 00 00 00 0C 00 00 +T 65 04 00 00 04 10 E5 2A 02 10 E5 3E 03 CD E8 00 +R 00 00 00 00 00 04 01 00 00 08 01 00 00 0E 00 00 +T 71 04 00 00 3E F2 CD 05 00 21 FA 00 CD E5 01 3E +R 00 00 00 00 00 07 00 00 00 0D 00 00 +T 7D 04 00 00 01 CD 1E 00 32 08 10 3A 08 10 3D 28 +R 00 00 00 00 00 06 00 00 00 09 01 00 00 0C 01 00 +T 89 04 00 00 04 AF C3 E5 04 +R 00 00 00 00 00 07 00 00 +T 8E 04 00 00 +R 00 00 00 00 +T 8E 04 00 00 3E A0 CD 05 00 21 90 01 CD E5 01 3E +R 00 00 00 00 00 07 00 00 00 0D 00 00 +T 9A 04 00 00 01 CD 1E 00 32 08 10 3A 08 10 3D 28 +R 00 00 00 00 00 06 00 00 00 09 01 00 00 0C 01 00 +T A6 04 00 00 04 AF C3 E5 04 +R 00 00 00 00 00 07 00 00 +T AB 04 00 00 +R 00 00 00 00 +T AB 04 00 00 3A 30 10 6F 3E 0B CD D1 00 2E 01 3E +R 00 00 00 00 00 05 01 00 00 0B 00 00 +T B7 04 00 00 3A CD D1 00 3E A6 CD 05 00 21 64 00 +R 00 00 00 00 00 06 00 00 00 0B 00 00 +T C3 04 00 00 CD E5 01 3E A1 CD 05 00 21 64 00 CD +R 00 00 00 00 00 05 00 00 00 0A 00 00 +T CF 04 00 00 E5 01 3E 01 CD 1E 00 32 08 10 3A +R 00 00 00 00 00 04 00 00 00 09 00 00 00 0C 01 00 +T DA 04 00 00 08 10 3D 28 04 AF C3 E5 04 +R 00 00 00 00 00 04 01 00 00 0B 00 00 +T E3 04 00 00 +R 00 00 00 00 +T E3 04 00 00 3E 01 +R 00 00 00 00 +T E5 04 00 00 +R 00 00 00 00 +T E5 04 00 00 DD F9 DD E1 C9 +R 00 00 00 00 +T EA 04 00 00 +R 00 00 00 00 +T EA 04 00 00 +R 00 00 00 00 +T EA 04 00 00 76 CD 00 00 B7 28 F9 C9 +R 00 00 00 00 02 06 10 00 +T F2 04 00 00 +R 00 00 00 00 +T F2 04 00 00 4F +R 00 00 00 00 +T F3 04 00 00 +R 00 00 00 00 +T F3 04 00 00 79 0D B7 C8 76 C3 F3 04 +R 00 00 00 00 00 0A 00 00 +T FB 04 00 00 +R 00 00 00 00 +T FB 04 00 00 21 76 02 CD 00 00 CD EA 04 21 +R 00 00 00 00 00 05 00 00 02 08 06 00 00 0B 00 00 +T 05 05 00 00 76 02 CD 00 00 AF C3 00 00 +R 00 00 00 00 00 04 00 00 02 07 0E 00 00 0B 00 00 +T 0E 05 00 00 +R 00 00 00 00 +T 0E 05 00 00 3B FD 21 00 00 FD 39 FD 77 00 3E A2 +R 00 00 00 00 +T 1A 05 00 00 CD 05 00 21 64 00 CD E5 01 3E E4 CD +R 00 00 00 00 00 05 00 00 00 0B 00 00 +T 26 05 00 00 05 00 21 64 00 CD E5 01 21 64 02 CD +R 00 00 00 00 00 04 00 00 00 0A 00 00 00 0D 00 00 +T 32 05 00 00 00 00 21 00 00 39 7E 33 C3 00 00 33 +R 00 00 00 00 02 04 0E 00 00 0D 00 00 +T 3E 05 00 00 C9 +R 00 00 00 00 +T 3F 05 00 00 +R 00 00 00 00 +T 3F 05 00 00 21 64 02 CD 00 00 AF C3 00 00 +R 00 00 00 00 00 05 00 00 02 08 0E 00 00 0C 00 00 +T 49 05 00 00 +R 00 00 00 00 +T 49 05 00 00 +R 00 00 00 00 +T 49 05 00 00 76 CD 00 00 B7 28 05 3E 02 CD 0E 05 +R 00 00 00 00 02 06 0B 00 00 0E 00 00 +T 55 05 00 00 +R 00 00 00 00 +T 55 05 00 00 CD 00 00 B7 28 05 3E 04 CD 0E 05 +R 00 00 00 00 02 05 11 00 00 0D 00 00 T 60 05 00 00 R 00 00 00 00 -T 60 05 00 00 DD F9 DD E1 C9 -R 00 00 00 00 -T 65 05 00 00 -R 00 00 00 00 -T 65 05 00 00 -R 00 00 00 00 -T 65 05 00 00 76 CD 00 00 B7 28 F9 C9 -R 00 00 00 00 02 06 0D 00 +T 60 05 00 00 CD 00 00 B7 28 E3 AF CD 0E 05 C3 +R 00 00 00 00 02 05 10 00 00 0C 00 00 +T 6B 05 00 00 49 05 +R 00 00 00 00 00 04 00 00 T 6D 05 00 00 R 00 00 00 00 -T 6D 05 00 00 4F +T 6D 05 00 00 3A 00 00 F5 33 21 85 05 CD 16 07 CD +R 00 00 00 00 00 05 02 00 00 0A 00 00 00 0D 00 00 +T 79 05 00 00 EA 04 21 64 02 CD 00 00 AF C3 +R 00 00 00 00 00 04 00 00 00 07 00 00 02 0A 0E 00 +T 83 05 00 00 00 00 +R 00 00 00 00 00 04 00 00 +T 85 05 00 00 R 00 00 00 00 -T 6E 05 00 00 +T 85 05 00 00 4E 6F 20 45 53 50 33 32 20 66 6F 75 R 00 00 00 00 -T 6E 05 00 00 79 0D B7 C8 76 C3 6E 05 -R 00 00 00 00 00 0A 00 00 -T 76 05 00 00 +T 91 05 00 00 6E 64 00 R 00 00 00 00 -T 76 05 00 00 21 83 02 CD 00 00 CD 65 05 21 -R 00 00 00 00 00 05 00 00 02 08 05 00 00 0B 00 00 -T 80 05 00 00 83 02 CD 00 00 AF C3 00 00 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0B 00 00 -T 89 05 00 00 +T 94 05 00 00 R 00 00 00 00 -T 89 05 00 00 21 3B 02 CD 00 00 CD 65 05 21 -R 00 00 00 00 00 05 00 00 02 08 05 00 00 0B 00 00 -T 93 05 00 00 3B 02 CD 00 00 AF C3 00 00 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0B 00 00 -T 9C 05 00 00 +T 94 05 00 00 3E 01 CD 00 00 FE 02 3E 01 C8 AF C9 +R 00 00 00 00 02 07 08 00 +T A0 05 00 00 R 00 00 00 00 -T 9C 05 00 00 21 4D 02 CD 00 00 3E 32 CD 6D 05 21 -R 00 00 00 00 00 05 00 00 02 08 05 00 00 0D 00 00 -T A8 05 00 00 4D 02 CD 00 00 3E 02 C3 00 00 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0C 00 00 -T B2 05 00 00 +T A0 05 00 00 3A 08 10 F5 33 21 C4 05 CD 16 07 CD +R 00 00 00 00 00 05 01 00 00 0A 00 00 00 0D 00 00 +T AC 05 00 00 94 05 B7 28 03 CD 49 05 +R 00 00 00 00 00 04 00 00 00 0A 00 00 +T B4 05 00 00 R 00 00 00 00 -T B2 05 00 00 21 5F 02 CD 00 00 3E 32 CD 6D 05 21 -R 00 00 00 00 00 05 00 00 02 08 05 00 00 0D 00 00 -T BE 05 00 00 5F 02 CD 00 00 3E 02 C3 00 00 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0C 00 00 -T C8 05 00 00 +T B4 05 00 00 3E 32 CD F2 04 21 64 02 CD 00 00 3E +R 00 00 00 00 00 07 00 00 00 0A 00 00 02 0D 0E 00 +T C0 05 00 00 02 C3 00 00 +R 00 00 00 00 00 06 00 00 +T C4 05 00 00 R 00 00 00 00 -T C8 05 00 00 ED 4B 09 10 1E 00 +T C4 05 00 00 46 69 6C 65 20 74 6F 6F 20 6C 61 72 +R 00 00 00 00 +T D0 05 00 00 67 65 00 +R 00 00 00 00 +T D3 05 00 00 +R 00 00 00 00 +T D3 05 00 00 3A 08 10 F5 33 21 F7 05 CD 16 07 CD +R 00 00 00 00 00 05 01 00 00 0A 00 00 00 0D 00 00 +T DF 05 00 00 94 05 B7 28 03 CD 49 05 +R 00 00 00 00 00 04 00 00 00 0A 00 00 +T E7 05 00 00 +R 00 00 00 00 +T E7 05 00 00 3E 32 CD F2 04 21 64 02 CD 00 00 3E +R 00 00 00 00 00 07 00 00 00 0A 00 00 02 0D 0E 00 +T F3 05 00 00 02 C3 00 00 +R 00 00 00 00 00 06 00 00 +T F7 05 00 00 +R 00 00 00 00 +T F7 05 00 00 50 6C 61 79 62 61 63 6B 20 65 72 72 +R 00 00 00 00 +T 03 06 00 00 6F 72 00 +R 00 00 00 00 +T 06 06 00 00 +R 00 00 00 00 +T 06 06 00 00 ED 4B 09 10 1E 00 R 00 00 00 00 00 06 01 00 -T CE 05 00 00 +T 0C 06 00 00 R 00 00 00 00 -T CE 05 00 00 6B 26 00 09 56 3E 0B 10 00 00 83 6F +T 0C 06 00 00 6B 26 00 09 56 3E 0B 10 00 00 83 6F R 00 00 00 00 09 0A 01 00 -T D7 05 00 00 3E 0B 10 00 00 CE 00 67 7A B7 28 0A +T 15 06 00 00 3E 0B 10 00 00 CE 00 67 7A B7 28 0A R 00 00 00 00 89 05 01 00 -T E0 05 00 00 7B D6 20 30 05 72 1C C3 CE 05 +T 1E 06 00 00 7B D6 20 30 05 72 1C C3 0C 06 R 00 00 00 00 00 0C 00 00 -T EA 05 00 00 +T 28 06 00 00 R 00 00 00 00 -T EA 05 00 00 36 00 C9 +T 28 06 00 00 36 00 C9 R 00 00 00 00 -T ED 05 00 00 +T 2B 06 00 00 R 00 00 00 00 -T ED 05 00 00 3E 45 F5 33 21 05 00 E5 21 01 01 E5 -R 00 00 00 00 -T F9 05 00 00 11 17 06 21 71 02 CD 00 00 21 -R 00 00 00 00 00 05 00 00 00 08 00 00 02 0B 0A 00 -T 03 06 00 00 0B 10 CD 00 00 D5 21 01 07 E5 11 -R 00 00 00 00 00 04 01 00 02 07 0C 00 -T 0E 06 00 00 0B 10 21 71 02 CD 00 00 C9 -R 00 00 00 00 00 04 01 00 00 07 00 00 02 0A 04 00 -T 17 06 00 00 -R 00 00 00 00 -T 17 06 00 00 46 69 6C 65 3A 00 -R 00 00 00 00 -T 1D 06 00 00 -R 00 00 00 00 -T 1D 06 00 00 DD E5 DD 21 00 00 DD 39 EB 01 49 06 -R 00 00 00 00 00 0E 00 00 -T 29 06 00 00 DD 7E 04 07 07 07 07 E6 0F 6F 26 00 -R 00 00 00 00 -T 35 06 00 00 09 7E 12 13 DD 7E 04 E6 0F 6F 26 00 -R 00 00 00 00 -T 41 06 00 00 09 7E 12 DD E1 E1 33 E9 -R 00 00 00 00 -T 49 06 00 00 -R 00 00 00 00 -T 49 06 00 00 30 31 32 33 34 35 36 37 38 39 41 42 -R 00 00 00 00 -T 55 06 00 00 43 44 45 46 00 -R 00 00 00 00 -T 5A 06 00 00 -R 00 00 00 00 -T 5A 06 00 00 DD E5 DD 21 00 00 DD 39 F5 4D 44 E1 -R 00 00 00 00 -T 66 06 00 00 D5 C5 11 64 00 DD 6E FE DD 66 FF CD -R 00 00 00 00 -T 72 06 00 00 00 00 EB 11 0A 00 CD 00 00 C1 7B C6 -R 00 00 00 00 02 04 00 00 02 0B 10 00 -T 7E 06 00 00 30 02 69 60 23 E5 C5 11 0A 00 DD 6E -R 00 00 00 00 -T 8A 06 00 00 FE DD 66 FF CD 00 00 EB 11 0A 00 CD -R 00 00 00 00 02 09 00 00 -T 96 06 00 00 00 00 C1 E1 7B C6 30 77 03 03 C5 11 -R 00 00 00 00 02 04 10 00 -T A2 06 00 00 0A 00 DD 6E FE DD 66 FF CD 00 00 C1 -R 00 00 00 00 02 0D 10 00 -T AE 06 00 00 7B C6 30 02 DD F9 DD E1 C9 -R 00 00 00 00 -T B7 06 00 00 -R 00 00 00 00 -T B7 06 00 00 DD E5 DD 21 00 00 DD 39 E5 21 00 00 -R 00 00 00 00 -T C3 06 00 00 E5 2E 3C E5 DD 5E 04 DD 56 05 DD 6E -R 00 00 00 00 -T CF 06 00 00 06 DD 66 07 CD 00 00 F1 F1 01 00 00 -R 00 00 00 00 02 09 08 00 -T DB 06 00 00 C5 0E 64 C5 CD 00 00 F1 F1 4B C5 21 -R 00 00 00 00 02 09 07 00 -T E7 06 00 00 00 00 E5 2E 3C E5 DD 5E 04 DD 56 05 -R 00 00 00 00 -T F3 06 00 00 DD 6E 06 DD 66 07 CD 00 00 F1 F1 C1 -R 00 00 00 00 02 0B 07 00 -T FF 06 00 00 51 D5 2E 0A 7A CD 00 00 7B 2E 0A CD -R 00 00 00 00 02 0A 03 00 -T 0B 07 00 00 00 00 7B D1 C6 30 E1 E5 77 C1 C5 03 -R 00 00 00 00 02 04 02 00 -T 17 07 00 00 C5 D5 2E 0A 7A CD 00 00 7B D1 C1 C6 -R 00 00 00 00 02 0A 02 00 -T 23 07 00 00 30 02 E1 E5 23 23 36 3A C1 C5 03 03 -R 00 00 00 00 -T 2F 07 00 00 03 C5 D5 2E 0A 7B CD 00 00 7B 2E 0A -R 00 00 00 00 02 0B 03 00 -T 3B 07 00 00 CD 00 00 7B D1 C1 C6 30 02 DD 7E FE -R 00 00 00 00 02 05 02 00 -T 47 07 00 00 C6 04 4F DD 7E FF CE 00 47 C5 2E 0A -R 00 00 00 00 -T 53 07 00 00 7B CD 00 00 7B C1 C6 30 02 DD F9 DD -R 00 00 00 00 02 06 02 00 -T 5F 07 00 00 E1 E1 F1 F1 E9 -R 00 00 00 00 -T 64 07 00 00 -R 00 00 00 00 -T 64 07 00 00 21 09 00 E5 21 03 01 E5 11 BA 07 21 +T 2B 06 00 00 21 05 00 E5 21 02 01 E5 11 77 06 21 R 00 00 00 00 00 0D 00 00 -T 70 07 00 00 71 02 CD 00 00 21 07 00 E5 21 03 0C -R 00 00 00 00 00 04 00 00 02 07 04 00 -T 7C 07 00 00 E5 11 C4 07 21 71 02 CD 00 00 21 -R 00 00 00 00 00 06 00 00 00 09 00 00 02 0C 04 00 -T 87 07 00 00 06 00 E5 21 03 15 E5 11 CC 07 21 -R 00 00 00 00 00 0C 00 00 -T 92 07 00 00 71 02 CD 00 00 21 05 00 E5 21 05 01 -R 00 00 00 00 00 04 00 00 02 07 04 00 -T 9E 07 00 00 E5 11 D3 07 21 71 02 CD 00 00 21 -R 00 00 00 00 00 06 00 00 00 09 00 00 02 0C 04 00 -T A9 07 00 00 03 00 E5 21 05 0C E5 11 D9 07 21 -R 00 00 00 00 00 0C 00 00 -T B4 07 00 00 71 02 CD 00 00 C9 -R 00 00 00 00 00 04 00 00 02 07 04 00 -T BA 07 00 00 -R 00 00 00 00 -T BA 07 00 00 50 61 74 74 65 72 6E 3A 23 00 -R 00 00 00 00 -T C4 07 00 00 -R 00 00 00 00 -T C4 07 00 00 20 20 52 6F 77 3A 23 00 -R 00 00 00 00 -T CC 07 00 00 -R 00 00 00 00 -T CC 07 00 00 20 20 42 50 4D 3A 00 -R 00 00 00 00 -T D3 07 00 00 -R 00 00 00 00 -T D3 07 00 00 54 69 6D 65 3A 00 -R 00 00 00 00 -T D9 07 00 00 -R 00 00 00 00 -T D9 07 00 00 20 2F 20 00 -R 00 00 00 00 -T DD 07 00 00 -R 00 00 00 00 -T DD 07 00 00 DD E5 DD 21 00 00 DD 39 4B 42 EB DD -R 00 00 00 00 -T E9 07 00 00 7E 07 DD B6 06 DD B6 05 DD B6 04 28 -R 00 00 00 00 -T F5 07 00 00 30 D5 C5 11 22 00 21 00 00 CD 00 00 -R 00 00 00 00 02 0E 0E 00 -T 01 08 00 00 F1 F1 DD 4E 06 DD 46 07 C5 DD 4E 04 -R 00 00 00 00 -T 0D 08 00 00 DD 46 05 C5 CD 00 00 F1 F1 4B 42 3E -R 00 00 00 00 02 09 08 00 -T 19 08 00 00 22 BB 3E 00 9A 30 09 01 22 00 C3 -R 00 00 00 00 -T 24 08 00 00 29 08 -R 00 00 00 00 00 04 00 00 -T 26 08 00 00 -R 00 00 00 00 -T 26 08 00 00 01 00 00 -R 00 00 00 00 -T 29 08 00 00 -R 00 00 00 00 -T 29 08 00 00 11 00 00 -R 00 00 00 00 -T 2C 08 00 00 -R 00 00 00 00 -T 2C 08 00 00 21 3C 10 19 7B 91 7A 98 30 05 3E 3D -R 00 00 00 00 00 05 01 00 -T 38 08 00 00 C3 3D 08 -R 00 00 00 00 00 05 00 00 -T 3B 08 00 00 -R 00 00 00 00 -T 3B 08 00 00 3E 2D -R 00 00 00 00 -T 3D 08 00 00 -R 00 00 00 00 -T 3D 08 00 00 77 13 6B 62 7D D6 22 7C DE 00 38 E3 -R 00 00 00 00 -T 49 08 00 00 21 22 00 E5 21 06 01 E5 11 3C 10 21 -R 00 00 00 00 00 0D 01 00 -T 55 08 00 00 71 02 CD 00 00 DD E1 E1 F1 F1 E9 -R 00 00 00 00 00 04 00 00 02 07 04 00 -T 60 08 00 00 -R 00 00 00 00 -T 60 08 00 00 DD E5 DD 21 00 00 DD 39 21 F8 FF 39 -R 00 00 00 00 -T 6C 08 00 00 F9 3A 30 10 6F 3E 0B CD DA 00 3E A8 -R 00 00 00 00 00 06 01 00 00 0C 00 00 -T 78 08 00 00 CD 0E 00 11 D0 07 21 00 00 CD DE 01 -R 00 00 00 00 00 05 00 00 00 0E 00 00 -T 84 08 00 00 3E 28 CD 27 00 DD 77 FF 3A 31 10 D6 -R 00 00 00 00 00 07 00 00 00 0D 01 00 -T 90 08 00 00 21 20 20 DD 7E FF D6 20 20 19 3E E4 -R 00 00 00 00 -T 9C 08 00 00 CD 0E 00 11 10 27 21 00 00 CD DE 01 -R 00 00 00 00 00 05 00 00 00 0E 00 00 -T A8 08 00 00 21 71 02 CD 00 00 3E 02 CD 00 00 -R 00 00 00 00 00 05 00 00 02 08 0B 00 00 0D 00 00 -T B3 08 00 00 -R 00 00 00 00 -T B3 08 00 00 DD 7E FF 32 31 10 3E 2B CD 27 00 DD -R 00 00 00 00 00 08 01 00 00 0D 00 00 -T BF 08 00 00 77 FA 3E 2C CD 27 00 DD 77 FB 3E 02 -R 00 00 00 00 00 09 00 00 -T CB 08 00 00 F5 33 21 01 00 39 EB 3E 31 CD AE 00 -R 00 00 00 00 00 0E 00 00 -T D7 08 00 00 3E 2D CD 40 00 DD 73 FC DD 72 FD DD -R 00 00 00 00 00 07 00 00 -T E3 08 00 00 75 FE DD 74 FF 3A 2F 10 FD 21 2C 10 -R 00 00 00 00 00 0A 01 00 00 0E 01 00 -T EF 08 00 00 FD B6 02 FD B6 01 FD B6 00 20 0C 3E -R 00 00 00 00 -T FB 08 00 00 36 CD 40 00 ED 53 2C 10 22 2E 10 -R 00 00 00 00 00 06 00 00 00 0A 01 00 00 0D 01 00 -T 06 09 00 00 -R 00 00 00 00 -T 06 09 00 00 DD 7E FA F5 33 21 32 10 CD 1D 06 21 -R 00 00 00 00 00 0A 01 00 00 0D 00 00 -T 12 09 00 00 02 00 E5 21 03 0A E5 11 32 10 21 -R 00 00 00 00 00 0C 01 00 -T 1D 09 00 00 71 02 CD 00 00 DD 7E FB F5 33 21 -R 00 00 00 00 00 04 00 00 02 07 04 00 -T 28 09 00 00 32 10 CD 1D 06 21 02 00 E5 21 03 13 -R 00 00 00 00 00 04 01 00 00 07 00 00 -T 34 09 00 00 E5 11 32 10 21 71 02 CD 00 00 D1 D5 -R 00 00 00 00 00 06 01 00 00 09 00 00 02 0C 04 00 -T 40 09 00 00 21 34 10 CD 5A 06 21 03 00 E5 21 -R 00 00 00 00 00 05 01 00 00 08 00 00 -T 4B 09 00 00 03 1B E5 11 34 10 21 71 02 CD 00 00 -R 00 00 00 00 00 08 01 00 00 0B 00 00 02 0E 04 00 -T 57 09 00 00 21 00 00 E5 21 44 AC E5 DD 5E FC DD -R 00 00 00 00 -T 63 09 00 00 56 FD DD 6E FE DD 66 FF CD 00 00 F1 -R 00 00 00 00 02 0D 08 00 -T 6F 09 00 00 E3 D5 21 37 10 CD B7 06 21 05 00 E5 -R 00 00 00 00 00 07 01 00 00 0A 00 00 -T 7B 09 00 00 21 05 07 E5 11 37 10 21 71 02 CD -R 00 00 00 00 00 09 01 00 00 0C 00 00 -T 86 09 00 00 00 00 21 00 00 E5 21 44 AC E5 ED 5B -R 00 00 00 00 02 04 04 00 -T 92 09 00 00 2C 10 2A 2E 10 CD 00 00 F1 E3 D5 21 -R 00 00 00 00 00 04 01 00 00 07 01 00 02 0A 08 00 -T 9E 09 00 00 37 10 CD B7 06 21 05 00 E5 21 05 0F -R 00 00 00 00 00 04 01 00 00 07 00 00 -T AA 09 00 00 E5 11 37 10 21 71 02 CD 00 00 2A -R 00 00 00 00 00 06 01 00 00 09 00 00 02 0C 04 00 -T B5 09 00 00 2E 10 E5 2A 2C 10 E5 DD 5E FC DD 56 -R 00 00 00 00 00 04 01 00 00 08 01 00 -T C1 09 00 00 FD DD 6E FE DD 66 FF CD DD 07 DD F9 -R 00 00 00 00 00 0C 00 00 -T CD 09 00 00 DD E1 C9 -R 00 00 00 00 -T D0 09 00 00 -R 00 00 00 00 -T D0 09 00 00 3B CD 05 00 CD C8 05 3A 00 00 3C 20 -R 00 00 00 00 00 06 00 00 00 09 00 00 00 0C 02 00 -T DC 09 00 00 0D CD 2E 02 B7 3E 01 20 02 3E 02 -R 00 00 00 00 00 06 00 00 -T E7 09 00 00 -R 00 00 00 00 -T E7 09 00 00 32 00 00 -R 00 00 00 00 00 05 02 00 -T EA 09 00 00 -R 00 00 00 00 -T EA 09 00 00 3A 00 00 3D 28 07 33 C3 89 05 C3 -R 00 00 00 00 00 05 02 00 00 0C 00 00 -T F5 09 00 00 DB 0A -R 00 00 00 00 00 04 00 00 -T F7 09 00 00 -R 00 00 00 00 -T F7 09 00 00 AF 32 2C 10 32 2D 10 32 2E 10 32 -R 00 00 00 00 00 06 01 00 00 09 01 00 00 0C 01 00 -T 02 0A 00 00 2F 10 CD 32 03 B7 20 12 3A 08 10 D6 -R 00 00 00 00 00 04 01 00 00 07 00 00 00 0D 01 00 -T 0E 0A 00 00 99 20 07 33 C3 9C 05 C3 DB 0A +T 37 06 00 00 64 02 CD 00 00 21 0B 10 CD +R 00 00 00 00 00 04 00 00 02 07 05 00 00 0A 01 00 +T 40 06 00 00 00 00 3E 71 F5 33 D5 21 02 07 E5 11 +R 00 00 00 00 02 04 0F 00 +T 4C 06 00 00 0B 10 21 64 02 CD 00 00 21 07 00 E5 +R 00 00 00 00 00 04 01 00 00 07 00 00 02 0A 0D 00 +T 58 06 00 00 21 03 01 E5 11 7D 06 21 64 02 CD R 00 00 00 00 00 09 00 00 00 0C 00 00 -T 18 0A 00 00 +T 63 06 00 00 00 00 21 24 00 E5 21 0A 02 E5 11 +R 00 00 00 00 02 04 05 00 +T 6E 06 00 00 85 06 21 64 02 CD 00 00 C9 +R 00 00 00 00 00 04 00 00 00 07 00 00 02 0A 05 00 +T 77 06 00 00 R 00 00 00 00 -T 18 0A 00 00 33 C3 B2 05 -R 00 00 00 00 00 06 00 00 -T 1C 0A 00 00 +T 77 06 00 00 46 69 6C 65 3A 00 R 00 00 00 00 -T 1C 0A 00 00 21 71 02 CD 00 00 CD ED 05 CD -R 00 00 00 00 00 05 00 00 02 08 05 00 00 0B 00 00 -T 26 0A 00 00 64 07 21 31 10 36 21 CD 60 08 FD 21 -R 00 00 00 00 00 04 00 00 00 07 01 00 00 0C 00 00 -T 32 0A 00 00 00 00 FD 39 FD 36 00 00 +T 7D 06 00 00 R 00 00 00 00 -T 3A 0A 00 00 +T 7D 06 00 00 53 74 61 74 75 73 3A 00 R 00 00 00 00 -T 3A 0A 00 00 76 FD 21 00 00 FD 39 FD 34 00 FD 7E +T 85 06 00 00 R 00 00 00 00 -T 46 0A 00 00 00 D6 0A 38 07 FD 36 00 00 CD 60 08 -R 00 00 00 00 00 0E 00 00 -T 52 0A 00 00 +T 85 06 00 00 50 67 55 70 2F 50 67 44 6E 3A 54 72 R 00 00 00 00 -T 52 0A 00 00 CD 00 00 B7 28 27 3E A2 CD 0E 00 11 -R 00 00 00 00 02 05 09 00 00 0D 00 00 -T 5E 0A 00 00 10 27 21 00 00 CD DE 01 3E E4 CD -R 00 00 00 00 00 0A 00 00 -T 69 0A 00 00 0E 00 11 10 27 21 00 00 CD DE 01 21 -R 00 00 00 00 00 04 00 00 00 0D 00 00 -T 75 0A 00 00 71 02 CD 00 00 3E 02 CD 00 00 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0C 00 00 -T 7F 0A 00 00 +T 91 06 00 00 61 63 6B 20 45 73 63 3A 53 74 6F 70 R 00 00 00 00 -T 7F 0A 00 00 CD 00 00 B7 28 27 3E A2 CD 0E 00 11 -R 00 00 00 00 02 05 0F 00 00 0D 00 00 -T 8B 0A 00 00 10 27 21 00 00 CD DE 01 3E E4 CD -R 00 00 00 00 00 0A 00 00 -T 96 0A 00 00 0E 00 11 10 27 21 00 00 CD DE 01 21 -R 00 00 00 00 00 04 00 00 00 0D 00 00 -T A2 0A 00 00 71 02 CD 00 00 3E 04 CD 00 00 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0C 00 00 -T AC 0A 00 00 +T 9D 06 00 00 20 53 70 61 63 65 3A 4C 65 61 76 65 R 00 00 00 00 -T AC 0A 00 00 CD 00 00 B7 28 88 3E A2 CD 0E 00 11 -R 00 00 00 00 02 05 0D 00 00 0D 00 00 -T B8 0A 00 00 10 27 21 00 00 CD DE 01 3E E4 CD -R 00 00 00 00 00 0A 00 00 -T C3 0A 00 00 0E 00 11 10 27 21 00 00 CD DE 01 21 -R 00 00 00 00 00 04 00 00 00 0D 00 00 -T CF 0A 00 00 71 02 CD 00 00 AF CD 00 00 C3 -R 00 00 00 00 00 04 00 00 02 07 0B 00 00 0B 00 00 -T D9 0A 00 00 3A 0A +T A9 06 00 00 00 +R 00 00 00 00 +T AA 06 00 00 +R 00 00 00 00 +T AA 06 00 00 DD E5 DD 21 00 00 DD 39 F5 1E 00 +R 00 00 00 00 +T B5 06 00 00 +R 00 00 00 00 +T B5 06 00 00 7B 85 4F 3E 00 8C 47 0A 4F B7 28 1F +R 00 00 00 00 +T C1 06 00 00 7B D6 18 30 1A 3E 32 10 00 00 83 DD +R 00 00 00 00 09 0A 01 00 +T CA 06 00 00 77 FE 3E 32 10 00 00 CE 00 DD 77 FF +R 00 00 00 00 89 07 01 00 +T D3 06 00 00 E5 DD 6E FE DD 66 FF 71 E1 1C C3 +R 00 00 00 00 +T DE 06 00 00 B5 06 R 00 00 00 00 00 04 00 00 -T DB 0A 00 00 +T E0 06 00 00 R 00 00 00 00 -T DB 0A 00 00 33 C9 +T E0 06 00 00 R 00 00 00 00 -T DD 0A 00 00 +T E0 06 00 00 7B D6 18 30 0C 21 32 10 16 00 19 1C +R 00 00 00 00 00 0A 01 00 +T EC 06 00 00 36 20 C3 E0 06 +R 00 00 00 00 00 07 00 00 +T F1 06 00 00 R 00 00 00 00 -T DD 0A 00 00 ED 73 00 10 32 07 10 ED 43 09 10 08 +T F1 06 00 00 21 64 02 DD 7E 04 F5 33 11 18 00 D5 +R 00 00 00 00 00 05 00 00 +T FD 06 00 00 11 03 09 D5 11 32 10 CD 00 00 DD F9 +R 00 00 00 00 00 09 01 00 02 0C 0D 00 +T 09 07 00 00 DD E1 E1 33 E9 +R 00 00 00 00 +T 0E 07 00 00 +R 00 00 00 00 +T 0E 07 00 00 3E 71 F5 33 CD AA 06 C9 +R 00 00 00 00 00 09 00 00 +T 16 07 00 00 +R 00 00 00 00 +T 16 07 00 00 DD E5 DD 21 00 00 DD 39 3B EB 0E 00 +R 00 00 00 00 +T 22 07 00 00 +R 00 00 00 00 +T 22 07 00 00 69 26 00 19 46 3E 4A 10 00 00 81 6F +R 00 00 00 00 09 0A 01 00 +T 2B 07 00 00 3E 4A 10 00 00 CE 00 67 79 3C DD 77 +R 00 00 00 00 89 05 01 00 +T 34 07 00 00 FF 78 B7 28 0C 79 D6 11 30 07 70 DD +R 00 00 00 00 +T 40 07 00 00 4E FF C3 22 07 +R 00 00 00 00 00 07 00 00 +T 45 07 00 00 +R 00 00 00 00 +T 45 07 00 00 DD 4E FF 36 20 69 0C 26 00 11 4A 10 +R 00 00 00 00 00 0E 01 00 +T 51 07 00 00 19 36 28 69 0C 26 00 11 4A 10 19 36 +R 00 00 00 00 00 0C 01 00 +T 5D 07 00 00 30 69 0C 26 00 11 4A 10 19 36 78 69 +R 00 00 00 00 00 0A 01 00 +T 69 07 00 00 0C 26 00 11 4A 10 19 DD 7E 04 07 07 +R 00 00 00 00 00 08 01 00 +T 75 07 00 00 07 07 E6 0F C6 BD 07 00 00 5F 3E 00 +R 00 00 00 00 09 09 00 00 +T 7E 07 00 00 CE BD 07 00 00 57 1A 77 69 0C 26 00 +R 00 00 00 00 89 05 00 00 +T 87 07 00 00 11 4A 10 19 DD 7E 04 E6 0F C6 +R 00 00 00 00 00 05 01 00 +T 91 07 00 00 BD 07 00 00 5F 3E 00 CE BD 07 00 00 +R 00 00 00 00 09 04 00 00 89 0C 00 00 +T 97 07 00 00 57 1A 77 69 0C 26 00 11 4A 10 19 36 +R 00 00 00 00 00 0C 01 00 +T A3 07 00 00 29 69 26 00 11 4A 10 19 36 00 3E 72 +R 00 00 00 00 00 09 01 00 +T AF 07 00 00 F5 33 21 4A 10 CD AA 06 33 DD E1 E1 +R 00 00 00 00 00 07 01 00 00 0A 00 00 +T BB 07 00 00 33 E9 +R 00 00 00 00 +T BD 07 00 00 +R 00 00 00 00 +T BD 07 00 00 30 31 32 33 34 35 36 37 38 39 41 42 +R 00 00 00 00 +T C9 07 00 00 43 44 45 46 00 +R 00 00 00 00 +T CE 07 00 00 +R 00 00 00 00 +T CE 07 00 00 DD E5 DD 21 00 00 DD 39 EB 01 FA 07 +R 00 00 00 00 00 0E 00 00 +T DA 07 00 00 DD 7E 04 07 07 07 07 E6 0F 6F 26 00 +R 00 00 00 00 +T E6 07 00 00 09 7E 12 13 DD 7E 04 E6 0F 6F 26 00 +R 00 00 00 00 +T F2 07 00 00 09 7E 12 DD E1 E1 33 E9 +R 00 00 00 00 +T FA 07 00 00 +R 00 00 00 00 +T FA 07 00 00 30 31 32 33 34 35 36 37 38 39 41 42 +R 00 00 00 00 +T 06 08 00 00 43 44 45 46 00 +R 00 00 00 00 +T 0B 08 00 00 +R 00 00 00 00 +T 0B 08 00 00 DD E5 DD 21 00 00 DD 39 F5 4D 44 E1 +R 00 00 00 00 +T 17 08 00 00 D5 C5 11 64 00 DD 6E FE DD 66 FF CD +R 00 00 00 00 +T 23 08 00 00 00 00 EB 11 0A 00 CD 00 00 C1 7B C6 +R 00 00 00 00 02 04 00 00 02 0B 12 00 +T 2F 08 00 00 30 02 69 60 23 E5 C5 11 0A 00 DD 6E +R 00 00 00 00 +T 3B 08 00 00 FE DD 66 FF CD 00 00 EB 11 0A 00 CD +R 00 00 00 00 02 09 00 00 +T 47 08 00 00 00 00 C1 E1 7B C6 30 77 03 03 C5 11 +R 00 00 00 00 02 04 12 00 +T 53 08 00 00 0A 00 DD 6E FE DD 66 FF CD 00 00 C1 +R 00 00 00 00 02 0D 12 00 +T 5F 08 00 00 7B C6 30 02 DD F9 DD E1 C9 +R 00 00 00 00 +T 68 08 00 00 +R 00 00 00 00 +T 68 08 00 00 DD E5 DD 21 00 00 DD 39 E5 21 00 00 +R 00 00 00 00 +T 74 08 00 00 E5 2E 3C E5 DD 5E 04 DD 56 05 DD 6E +R 00 00 00 00 +T 80 08 00 00 06 DD 66 07 CD 00 00 F1 F1 01 00 00 +R 00 00 00 00 02 09 0A 00 +T 8C 08 00 00 C5 0E 64 C5 CD 00 00 F1 F1 4B C5 21 +R 00 00 00 00 02 09 09 00 +T 98 08 00 00 00 00 E5 2E 3C E5 DD 5E 04 DD 56 05 +R 00 00 00 00 +T A4 08 00 00 DD 6E 06 DD 66 07 CD 00 00 F1 F1 C1 +R 00 00 00 00 02 0B 09 00 +T B0 08 00 00 51 D5 2E 0A 7A CD 00 00 7B 2E 0A CD +R 00 00 00 00 02 0A 04 00 +T BC 08 00 00 00 00 7B D1 C6 30 E1 E5 77 C1 C5 03 +R 00 00 00 00 02 04 03 00 +T C8 08 00 00 C5 D5 2E 0A 7A CD 00 00 7B D1 C1 C6 +R 00 00 00 00 02 0A 03 00 +T D4 08 00 00 30 02 E1 E5 23 23 36 3A C1 C5 03 03 +R 00 00 00 00 +T E0 08 00 00 03 C5 D5 2E 0A 7B CD 00 00 7B 2E 0A +R 00 00 00 00 02 0B 04 00 +T EC 08 00 00 CD 00 00 7B D1 C1 C6 30 02 DD 7E FE +R 00 00 00 00 02 05 03 00 +T F8 08 00 00 C6 04 4F DD 7E FF CE 00 47 C5 2E 0A +R 00 00 00 00 +T 04 09 00 00 7B CD 00 00 7B C1 C6 30 02 DD F9 DD +R 00 00 00 00 02 06 03 00 +T 10 09 00 00 E1 E1 F1 F1 E9 +R 00 00 00 00 +T 15 09 00 00 +R 00 00 00 00 +T 15 09 00 00 21 09 00 E5 21 04 01 E5 11 B4 09 21 +R 00 00 00 00 00 0D 00 00 +T 21 09 00 00 64 02 CD 00 00 21 07 00 E5 21 04 0C +R 00 00 00 00 00 04 00 00 02 07 05 00 +T 2D 09 00 00 E5 11 BE 09 21 64 02 CD 00 00 21 +R 00 00 00 00 00 06 00 00 00 09 00 00 02 0C 05 00 +T 38 09 00 00 06 00 E5 21 04 15 E5 11 C6 09 21 +R 00 00 00 00 00 0C 00 00 +T 43 09 00 00 64 02 CD 00 00 21 05 00 E5 21 06 01 +R 00 00 00 00 00 04 00 00 02 07 05 00 +T 4F 09 00 00 E5 11 CD 09 21 64 02 CD 00 00 21 +R 00 00 00 00 00 06 00 00 00 09 00 00 02 0C 05 00 +T 5A 09 00 00 03 00 E5 21 06 0C E5 11 D3 09 21 +R 00 00 00 00 00 0C 00 00 +T 65 09 00 00 64 02 CD 00 00 11 6C 10 0E 00 +R 00 00 00 00 00 04 00 00 02 07 05 00 00 0A 01 00 +T 6F 09 00 00 +R 00 00 00 00 +T 6F 09 00 00 69 26 00 19 36 20 0C 79 D6 20 38 F4 +R 00 00 00 00 +T 7B 09 00 00 21 20 00 E5 21 08 04 E5 21 64 02 CD +R 00 00 00 00 00 0D 00 00 +T 87 09 00 00 00 00 21 08 04 E5 21 64 02 CD 00 00 +R 00 00 00 00 02 04 05 00 00 0B 00 00 02 0E 0C 00 +T 93 09 00 00 7A E6 3F 57 CB FB ED 53 8C 10 0E 00 +R 00 00 00 00 00 0C 01 00 +T 9F 09 00 00 +R 00 00 00 00 +T 9F 09 00 00 2A 8C 10 5D 7C C6 C0 57 69 26 00 19 +R 00 00 00 00 00 05 01 00 +T AB 09 00 00 36 07 0C 79 D6 20 38 EC C9 +R 00 00 00 00 +T B4 09 00 00 +R 00 00 00 00 +T B4 09 00 00 50 61 74 74 65 72 6E 3A 23 00 +R 00 00 00 00 +T BE 09 00 00 +R 00 00 00 00 +T BE 09 00 00 20 20 52 6F 77 3A 23 00 +R 00 00 00 00 +T C6 09 00 00 +R 00 00 00 00 +T C6 09 00 00 20 20 42 50 4D 3A 00 +R 00 00 00 00 +T CD 09 00 00 +R 00 00 00 00 +T CD 09 00 00 54 69 6D 65 3A 00 +R 00 00 00 00 +T D3 09 00 00 +R 00 00 00 00 +T D3 09 00 00 20 2F 20 00 +R 00 00 00 00 +T D7 09 00 00 +R 00 00 00 00 +T D7 09 00 00 DD E5 DD 21 00 00 DD 39 4B 42 EB DD +R 00 00 00 00 +T E3 09 00 00 7E 07 DD B6 06 DD B6 05 DD B6 04 28 +R 00 00 00 00 +T EF 09 00 00 30 69 60 3E 05 +R 00 00 00 00 +T F4 09 00 00 +R 00 00 00 00 +T F4 09 00 00 29 CB 13 CB 12 3D 20 F8 DD 4E 06 DD +R 00 00 00 00 +T 00 0A 00 00 46 07 C5 DD 4E 04 DD 46 05 C5 EB CD +R 00 00 00 00 +T 0C 0A 00 00 00 00 F1 F1 4B 42 3E 20 BB 3E 00 9A +R 00 00 00 00 02 04 0A 00 +T 18 0A 00 00 30 09 01 20 00 C3 23 0A +R 00 00 00 00 00 0A 00 00 +T 20 0A 00 00 +R 00 00 00 00 +T 20 0A 00 00 01 00 00 +R 00 00 00 00 +T 23 0A 00 00 +R 00 00 00 00 +T 23 0A 00 00 11 00 00 +R 00 00 00 00 +T 26 0A 00 00 +R 00 00 00 00 +T 26 0A 00 00 2A 8C 10 7C C6 C0 67 19 7B 91 7A 98 +R 00 00 00 00 00 05 01 00 +T 32 0A 00 00 30 05 3E 40 C3 3B 0A +R 00 00 00 00 00 09 00 00 +T 39 0A 00 00 +R 00 00 00 00 +T 39 0A 00 00 3E 07 +R 00 00 00 00 +T 3B 0A 00 00 +R 00 00 00 00 +T 3B 0A 00 00 77 13 6B 62 7D D6 20 7C DE 00 38 DF +R 00 00 00 00 +T 47 0A 00 00 DD E1 E1 F1 F1 E9 +R 00 00 00 00 +T 4D 0A 00 00 +R 00 00 00 00 +T 4D 0A 00 00 DD E5 DD 21 00 00 DD 39 21 F8 FF 39 +R 00 00 00 00 +T 59 0A 00 00 F9 3A 30 10 6F 3E 0B CD D1 00 3E A8 +R 00 00 00 00 00 06 01 00 00 0C 00 00 +T 65 0A 00 00 CD 05 00 21 32 00 CD E5 01 3E 28 CD +R 00 00 00 00 00 05 00 00 00 0B 00 00 +T 71 0A 00 00 1E 00 DD 77 FF 3A 31 10 D6 21 20 1D +R 00 00 00 00 00 04 00 00 00 0A 01 00 +T 7D 0A 00 00 DD 7E FF D6 20 20 16 3E E4 CD 05 00 +R 00 00 00 00 00 0E 00 00 +T 89 0A 00 00 21 64 00 CD E5 01 21 64 02 CD 00 00 +R 00 00 00 00 00 08 00 00 00 0B 00 00 02 0E 0E 00 +T 95 0A 00 00 3E 02 CD 00 00 +R 00 00 00 00 00 07 00 00 +T 9A 0A 00 00 +R 00 00 00 00 +T 9A 0A 00 00 DD 7E FF 32 31 10 3E 2B CD 1E 00 DD +R 00 00 00 00 00 08 01 00 00 0D 00 00 +T A6 0A 00 00 77 FA 3E 2C CD 1E 00 DD 77 FB 3E 02 +R 00 00 00 00 00 09 00 00 +T B2 0A 00 00 F5 33 21 01 00 39 EB 3E 31 CD A5 00 +R 00 00 00 00 00 0E 00 00 +T BE 0A 00 00 3E 2D CD 37 00 DD 73 FC DD 72 FD DD +R 00 00 00 00 00 07 00 00 +T CA 0A 00 00 75 FE DD 74 FF 3A 2F 10 FD 21 2C 10 +R 00 00 00 00 00 0A 01 00 00 0E 01 00 +T D6 0A 00 00 FD B6 02 FD B6 01 FD B6 00 20 0C 3E +R 00 00 00 00 +T E2 0A 00 00 36 CD 37 00 ED 53 2C 10 22 2E 10 +R 00 00 00 00 00 06 00 00 00 0A 01 00 00 0D 01 00 +T ED 0A 00 00 +R 00 00 00 00 +T ED 0A 00 00 DD 7E FA F5 33 21 62 10 CD CE 07 3E +R 00 00 00 00 00 0A 01 00 00 0D 00 00 +T F9 0A 00 00 71 F5 33 21 02 00 E5 21 04 0A E5 11 +R 00 00 00 00 +T 05 0B 00 00 62 10 21 64 02 CD 00 00 DD 7E FB F5 +R 00 00 00 00 00 04 01 00 00 07 00 00 02 0A 0D 00 +T 11 0B 00 00 33 21 62 10 CD CE 07 3E 71 F5 33 21 +R 00 00 00 00 00 06 01 00 00 09 00 00 +T 1D 0B 00 00 02 00 E5 21 04 13 E5 11 62 10 21 +R 00 00 00 00 00 0C 01 00 +T 28 0B 00 00 64 02 CD 00 00 D1 D5 21 64 10 CD +R 00 00 00 00 00 04 00 00 02 07 0D 00 00 0C 01 00 +T 33 0B 00 00 0B 08 3E 71 F5 33 21 03 00 E5 21 +R 00 00 00 00 00 04 00 00 +T 3E 0B 00 00 04 1B E5 11 64 10 21 64 02 CD 00 00 +R 00 00 00 00 00 08 01 00 00 0B 00 00 02 0E 0D 00 +T 4A 0B 00 00 21 00 00 E5 21 44 AC E5 DD 5E FC DD +R 00 00 00 00 +T 56 0B 00 00 56 FD DD 6E FE DD 66 FF CD 00 00 F1 +R 00 00 00 00 02 0D 0A 00 +T 62 0B 00 00 E3 D5 21 67 10 CD 68 08 3E 71 F5 33 +R 00 00 00 00 00 07 01 00 00 0A 00 00 +T 6E 0B 00 00 21 05 00 E5 21 06 07 E5 11 67 10 21 +R 00 00 00 00 00 0D 01 00 +T 7A 0B 00 00 64 02 CD 00 00 21 00 00 E5 21 44 AC +R 00 00 00 00 00 04 00 00 02 07 0D 00 +T 86 0B 00 00 E5 ED 5B 2C 10 2A 2E 10 CD 00 00 F1 +R 00 00 00 00 00 07 01 00 00 0A 01 00 02 0D 0A 00 +T 92 0B 00 00 E3 D5 21 67 10 CD 68 08 3E 71 F5 33 +R 00 00 00 00 00 07 01 00 00 0A 00 00 +T 9E 0B 00 00 21 05 00 E5 21 06 0F E5 11 67 10 21 +R 00 00 00 00 00 0D 01 00 +T AA 0B 00 00 64 02 CD 00 00 2A 2E 10 E5 2A +R 00 00 00 00 00 04 00 00 02 07 0D 00 00 0A 01 00 +T B4 0B 00 00 2C 10 E5 DD 5E FC DD 56 FD DD 6E FE +R 00 00 00 00 00 04 01 00 +T C0 0B 00 00 DD 66 FF CD D7 09 DD F9 DD E1 C9 +R 00 00 00 00 00 08 00 00 +T CB 0B 00 00 +R 00 00 00 00 +T CB 0B 00 00 3B CD 06 06 21 64 02 CD 00 00 CD +R 00 00 00 00 00 06 00 00 00 09 00 00 02 0C 06 00 +T D6 0B 00 00 2B 06 21 84 0C CD 0E 07 3A +R 00 00 00 00 00 04 00 00 00 07 00 00 00 0A 00 00 +T DF 0B 00 00 00 00 3C 20 0D CD 57 02 B7 3E 01 20 +R 00 00 00 00 00 04 02 00 00 0A 00 00 +T EB 0B 00 00 02 3E 02 +R 00 00 00 00 +T EE 0B 00 00 +R 00 00 00 00 +T EE 0B 00 00 32 00 00 +R 00 00 00 00 00 05 02 00 +T F1 0B 00 00 +R 00 00 00 00 +T F1 0B 00 00 3A 00 00 3D 28 07 33 C3 6D 05 C3 +R 00 00 00 00 00 05 02 00 00 0C 00 00 +T FC 0B 00 00 82 0C +R 00 00 00 00 00 04 00 00 +T FE 0B 00 00 +R 00 00 00 00 +T FE 0B 00 00 AF 32 2C 10 32 2D 10 32 2E 10 32 +R 00 00 00 00 00 06 01 00 00 09 01 00 00 0C 01 00 +T 09 0C 00 00 2F 10 CD BE 02 B7 20 12 3A 08 10 D6 +R 00 00 00 00 00 04 01 00 00 07 00 00 00 0D 01 00 +T 15 0C 00 00 99 20 07 33 C3 A0 05 C3 82 0C +R 00 00 00 00 00 09 00 00 00 0C 00 00 +T 1F 0C 00 00 +R 00 00 00 00 +T 1F 0C 00 00 33 C3 D3 05 +R 00 00 00 00 00 06 00 00 +T 23 0C 00 00 +R 00 00 00 00 +T 23 0C 00 00 21 9C 0C CD 0E 07 CD 15 09 21 +R 00 00 00 00 00 05 00 00 00 08 00 00 00 0B 00 00 +T 2D 0C 00 00 31 10 36 21 CD 4D 0A FD 21 00 00 FD +R 00 00 00 00 00 04 01 00 00 09 00 00 +T 39 0C 00 00 39 FD 36 00 00 +R 00 00 00 00 +T 3E 0C 00 00 +R 00 00 00 00 +T 3E 0C 00 00 76 FD 21 00 00 FD 39 FD 34 00 FD 7E +R 00 00 00 00 +T 4A 0C 00 00 00 D6 0A 38 07 FD 36 00 00 CD 4D 0A +R 00 00 00 00 00 0E 00 00 +T 56 0C 00 00 +R 00 00 00 00 +T 56 0C 00 00 CD 00 00 B7 28 05 3E 02 CD 0E 05 +R 00 00 00 00 02 05 0B 00 00 0D 00 00 +T 61 0C 00 00 +R 00 00 00 00 +T 61 0C 00 00 CD 00 00 B7 28 05 3E 04 CD 0E 05 +R 00 00 00 00 02 05 11 00 00 0D 00 00 +T 6C 0C 00 00 +R 00 00 00 00 +T 6C 0C 00 00 CD 00 00 B7 28 04 AF CD 0E 05 +R 00 00 00 00 02 05 10 00 00 0C 00 00 +T 76 0C 00 00 +R 00 00 00 00 +T 76 0C 00 00 CD 00 00 B7 28 C2 CD 3F 05 C3 3E 0C +R 00 00 00 00 02 05 01 00 00 0B 00 00 00 0E 00 00 +T 82 0C 00 00 +R 00 00 00 00 +T 82 0C 00 00 33 C9 +R 00 00 00 00 +T 84 0C 00 00 +R 00 00 00 00 +T 84 0C 00 00 4C 6F 61 64 69 6E 67 2C 20 70 6C 65 +R 00 00 00 00 +T 90 0C 00 00 61 73 65 20 77 61 69 74 2E 2E 2E 00 +R 00 00 00 00 +T 9C 0C 00 00 +R 00 00 00 00 +T 9C 0C 00 00 50 6C 61 79 69 6E 67 00 +R 00 00 00 00 +T A4 0C 00 00 +R 00 00 00 00 +T A4 0C 00 00 ED 73 00 10 32 07 10 ED 43 09 10 08 R 00 00 00 00 00 06 01 00 00 09 01 00 00 0D 01 00 -T E9 0A 00 00 32 06 10 22 02 10 ED 53 04 10 3A +T B0 0C 00 00 32 06 10 22 02 10 ED 53 04 10 3A R 00 00 00 00 00 05 01 00 00 08 01 00 00 0C 01 00 -T F4 0A 00 00 07 10 B7 CA D0 09 3A 07 10 D6 03 CA +T BB 0C 00 00 07 10 B7 CA CB 0B 3A 07 10 D6 03 CA R 00 00 00 00 00 04 01 00 00 08 00 00 00 0B 01 00 -T 00 0B 00 00 76 05 AF C3 00 00 +T C7 0C 00 00 FB 04 AF C3 00 00 R 00 00 00 00 00 04 00 00 00 08 00 00 T 00 00 00 00 R 00 00 07 00 diff --git a/obj/out.sym b/obj/out.sym index a2f8b6c..d144280 100644 --- a/obj/out.sym +++ b/obj/out.sym @@ -63,105 +63,117 @@ Hexadecimal [32-Bits] Symbol Table - 0 ___str_11 000007BA R - 0 ___str_12 000007C4 R - 0 ___str_13 000007CC R - 0 ___str_14 000007D3 R - 0 ___str_15 000007D9 R - 0 ___str_9 00000617 R + 0 ___str_12 000009B4 R + 0 ___str_13 000009BE R + 0 ___str_14 000009C6 R + 0 ___str_15 000009CD R + 0 ___str_16 000009D3 R + 0 ___str_17 00000C84 R + 0 ___str_18 00000C9C R + 0 ___str_4 00000585 R + 0 ___str_5 000005C4 R + 0 ___str_6 000005F7 R + 0 ___str_7 00000677 R + 0 ___str_8 0000067D R + 0 ___str_9 00000685 R __divuchar ******** GX __divuint ******** GX __divulong ******** GX __moduchar ******** GX __moduint ******** GX __modulong ******** GX - __mullong ******** GX - 0 __str_0 00000295 R - 0 __str_1 0000029F R - 0 __str_2 000002A0 R - 0 __str_3 000002B6 R - 0 __str_4 000002D6 R - 0 __str_5 000002F4 R - 0 __str_6 00000309 R - 0 __str_7 00000317 R - 0 __str_8 00000320 R + 0 __str_0 00000288 R + 0 __str_1 000002A2 R + 0 __str_2 000002A3 R + 0 __str_3 000002AC R 7 __xinit__state_esp 00000000 R - 0 _about 00000576 GR - 1 _barbuf 0000103C R + 0 _about 000004FB GR + 1 _bar_attr_ofs 0000108C GR + 1 _barbuf 0000106C R 1 _call_type 00001007 GR - 0 _copy_file_name 000005C8 GR - 1 _decbuf 00001034 R - 0 _draw_progress_bar 000007DD GR - 0 _err_no_esp 0000023B GR - 0 _err_out_of_mem 0000024D GR - 0 _err_playback 0000025F GR - 0 _error_esp 00000589 GR - 0 _error_oom 0000059C GR - 0 _error_playback 000005B2 GR - 0 _esp_cmd 0000000E GR - 0 _esp_create_obj 00000200 GR - 0 _esp_init 0000022E GR - 0 _esp_rd_end 00000194 GR - 0 _esp_rd_reg32 00000040 GR - 0 _esp_rd_reg8 00000027 GR - 0 _esp_rd_regs 000000AE GR - 0 _esp_send_dma 00000130 GR - 0 _esp_wait_busy 000001DE GR - 0 _esp_wait_status 000001A3 GR - 0 _esp_wr_end 00000121 GR - 0 _esp_wr_reg32 000000F1 GR - 0 _esp_wr_reg8 000000DA GR + 0 _copy_file_name 00000606 GR + 1 _decbuf 00001064 R + 0 _draw_progress_bar 000009D7 GR + 0 _error_esp 0000056D GR + 0 _error_oom 000005A0 GR + 0 _error_playback 000005D3 GR + 0 _esp_cmd 00000005 GR + 0 _esp_create_obj 0000022C GR + 0 _esp_init 00000257 GR + 0 _esp_rd_end 00000188 GR + 0 _esp_rd_reg32 00000037 GR + 0 _esp_rd_reg8 0000001E GR + 0 _esp_rd_regs 000000A5 GR + 0 _esp_send_dma 00000127 GR + 0 _esp_wait_busy 000001E5 GR + 0 _esp_wait_status 00000197 GR + 0 _esp_wr_end 00000118 GR + 0 _esp_wr_reg32 000000E8 GR + 0 _esp_wr_reg8 000000D1 GR 1 _file_ext 00001006 GR 1 _file_name 0000100B GR 1 _filesize 00001002 GR 1 _fs_buf 00000000 GR - 1 _hexbuf 00001032 R + 1 _hexbuf 00001062 R 1 _last_esp_status 00001008 GR 1 _last_track_status 00001031 GR + 0 _leave_playing_and_exit 0000053F GR ASxxxx Assembler V05.50.4+NoICE+SDCCmods-WIP-R14 (Zilog Z80 / Hitachi HD64180 / ZX-Next / eZ80 / R800) Page 3 Hexadecimal [32-Bits] Symbol Table - 0 _main 00000ADD GR - 0 _main_start 000009D0 GR + 0 _main 00000CA4 GR + 0 _main_start 00000BCB GR 1 _p_file_name 00001009 GR - 0 _play_xm 00000332 GR - 0 _put_dec3 0000065A GR - 0 _put_hex2 0000061D GR - 0 _put_hex2_hexch_10000_106 00000649 R - 0 _put_time 000006B7 GR + 0 _play_xm 000002BE GR + 0 _put_dec3 0000080B GR + 0 _put_hex2 000007CE GR + 0 _put_hex2_hexch_10000_132 000007FA R + 0 _put_time 00000868 GR 1 _ret_sp 00001000 GR 2 _state_esp 00000000 GR + 1 _status_buf 00001032 R + 1 _status_code_buf 0000104A R + 0 _stop_on_error 00000594 GR _strlen ******** GX - 1 _timebuf 00001037 R + 1 _timebuf 00001067 R 1 _total_samples 0000102C GR - 0 _wait_esc_key 00000565 GR - 0 _wait_frames 0000056D GR + 0 _unload_and_exit 0000050E GR + 0 _wait_esc_key 000004EA GR + 0 _wait_for_manual_exit 00000549 GR + 0 _wait_frames 000004F2 GR 0 _wc_exit 00000000 GR + _wc_gadrw ******** GX _wc_key_esc ******** GX _wc_key_pgdn ******** GX _wc_key_pgup ******** GX + _wc_key_space ******** GX _wc_load512 ******** GX + _wc_prm_pl ******** GX _wc_prsrw ******** GX _wc_prsrw_attr ******** GX _wc_prwow ******** GX _wc_rresb ******** GX - 0 _wc_set_freq_14mhz 00000005 GR - 0 _win_about 00000283 GR - 0 _win_xm 00000271 GR - 0 _xm_draw_static_labels 000005ED GR - 0 _xm_draw_stats_labels 00000764 GR + 0 _win_about 00000276 GR + 0 _win_xm 00000264 GR + 0 _xm_draw_static_labels 0000062B GR + 0 _xm_draw_stats_labels 00000915 GR 1 _xm_handle 00001030 GR - 0 _xm_update_info 00000860 GR + 0 _xm_set_status 0000070E GR + 0 _xm_set_status_attr 000006AA GR + 0 _xm_set_status_code 00000716 GR + 0 _xm_set_status_code_hexch_10000_129 000007BD R + 0 _xm_update_info 00000A4D GR + ASxxxx Assembler V05.50.4+NoICE+SDCCmods-WIP-R14 (Zilog Z80 / Hitachi HD64180 / ZX-Next / eZ80 / R800) Page 4 Hexadecimal [32-Bits] Area Table - 0 _CODE size B06 flags 0 - 1 _DATA size 105E flags 0 + 0 _CODE size CCD flags 0 + 1 _DATA size 108E flags 0 2 _INITIALIZED size 1 flags 0 3 _DABS size 0 flags 8 4 _HOME size 0 flags 0 diff --git a/src/esp32.c b/src/esp32.c index 6b61226..a4cd7b2 100644 --- a/src/esp32.c +++ b/src/esp32.c @@ -13,7 +13,7 @@ #define SPI_ESP_CS_ON 0x13 #define SPI_ESP_CS_OFF 0x03 -u32 esp_wait_busy(u32 timeout); +u8 esp_wait_busy(u16 max_frames); void esp_cmd(u8 cmd) { @@ -117,7 +117,7 @@ void esp_send_dma(u16 a, u8 p, u16 l, u16 n) SPI_CTRL = SPI_ESP_CS_OFF; esp_wr_end(); - esp_wait_busy(60000); + esp_wait_busy(100); // 2s - esp32 consuming one DMA'd chunk should be near-instant } void esp_rd_end() @@ -128,18 +128,38 @@ void esp_rd_end() SPI_CTRL = SPI_ESP_CS_OFF; } -u32 esp_wait_status(u8 status, u32 timeout) +// Both wait against WC's own frame timer (_TMN, 0x6009 - a 16-bit counter +// incremented at 50Hz by WC's interrupt) instead of a raw SPI-poll +// iteration count. An iteration count isn't real time - it depends on the +// current Z80 clock, which xmplay doesn't control (WC's turbo setting +// could be anything when the plugin starts) - and an uncalibrated guess +// already caused one real bug (TRACK_INIT timing out early on heavier +// files, see main.c's esp_wait_ready() history/comment). Returns 1 if the +// awaited condition was seen within max_frames, 0 on timeout. +u8 esp_wait_status(u8 status, u16 max_frames) { - while (--timeout) if (esp_rd_reg8(ESP_REG_STATUS) == status) break; + u16 start = *(u16*)_TMN; - return timeout; + while ((u16)(*(u16*)_TMN - start) < max_frames) + { + if (esp_rd_reg8(ESP_REG_STATUS) == status) + return 1; + } + + return 0; } -u32 esp_wait_busy(u32 timeout) +u8 esp_wait_busy(u16 max_frames) { - while (--timeout) if (esp_rd_reg8(ESP_REG_STATUS) != ESP_ST_BUSY) break; + u16 start = *(u16*)_TMN; - return timeout; + while ((u16)(*(u16*)_TMN - start) < max_frames) + { + if (esp_rd_reg8(ESP_REG_STATUS) != ESP_ST_BUSY) + return 1; + } + + return 0; } int esp_create_obj(u32 size, u8 type) @@ -147,7 +167,7 @@ int esp_create_obj(u32 size, u8 type) esp_wr_reg32(ESP_REG_DATA_SIZE, size); esp_wr_reg8(ESP_REG_OBJ_TYPE, type); esp_cmd(ESP_CMD_MAKE_OBJECT); - esp_wait_busy(20000); + esp_wait_busy(100); // 2s - object allocation should be near-instant // +++ check error return esp_rd_reg8(ESP_REG_OBJ_HANDLE); diff --git a/src/main.c b/src/main.c index 3683805..ed27615 100644 --- a/src/main.c +++ b/src/main.c @@ -61,51 +61,6 @@ enum }; // --- Windows ------------------------------ -const WC_TX_WINDOW err_no_esp = -{ - /* window with header and text */ WC_WIND_HDR_TXT, - /* cursor color mask */ 0, - /* X,Y (position) */ 24, 10, - /* W,H (size) */ 32, 5, - /* paper/ink (window color) */ 0x2F, - /* -reserved- */ 0, - /* window restore buffer address */ 0, - /* separators */ 0, 0, - /* header text */ "\x0E" " Error! ", - /* footer text */ "", - /* window text */ "\x0E\x0C\x01" "No ESP32 detected!", -}; - -const WC_TX_WINDOW err_out_of_mem = -{ - /* window with header and text */ WC_WIND_HDR_TXT, - /* cursor color mask */ 0, - /* X,Y (position) */ 255, 255, - /* W,H (size) */ 32, 5, - /* paper/ink (window color) */ 0x2F, - /* -reserved- */ 0, - /* window restore buffer address */ 0, - /* separators */ 0, 0, - /* header text */ "\x0E" " Error! ", - /* footer text */ "", - /* window text */ "\x0E\x0C\x01" "Out of memory (file too big)", -}; - -const WC_TX_WINDOW err_playback = -{ - /* window with header and text */ WC_WIND_HDR_TXT, - /* cursor color mask */ 0, - /* X,Y (position) */ 255, 255, - /* W,H (size) */ 32, 5, - /* paper/ink (window color) */ 0x2F, - /* -reserved- */ 0, - /* window restore buffer address */ 0, - /* separators */ 0, 0, - /* header text */ "\x0E" " Error! ", - /* footer text */ "", - /* window text */ "\x0E\x0C\x01" "Playback error (bad file?)", -}; - // STEP 1 of the gradual reintroduction: bigger, fixed position (not // auto-center) - no wc_prsrw() calls yet, still just static wnd_txt like // before. This exact size/position was already confirmed stable on its own @@ -115,14 +70,14 @@ const WC_TX_WINDOW win_xm = /* window with header and text + shadow (0x80) */ WC_WIND_HDR_TXT | 0x80, /* cursor color mask */ 0, /* X,Y (position) */ 25, 10, - /* W,H (size) */ 40, 11, - /* paper/ink (window color) */ 0x4F, + /* W,H (size) */ 40, 12, + /* paper/ink (window color) */ 0x70, // white paper, black ink/border - matches VGMPLAY.WMF's CLR_WIN = WC_COLOR(WC_WHITE, WC_BLACK) /* -reserved- */ 0, /* window restore buffer address */ 0, /* separators */ 0, 0, - /* header text */ "\x0E" " XM/XMZ/S3M Player ", + /* header text */ "\x0E" " XM/XMZ/S3M Player v0.1 ", /* footer text */ "", - /* window text */ "\x0E\x0C\x01" "Playing..." + /* window text */ "" // replaced by the dynamic "Status:" line, see xm_set_status() }; const WC_TX_WINDOW win_about = @@ -137,9 +92,12 @@ const WC_TX_WINDOW win_about = /* separators */ 0, 0, /* header text */ "\x0E" " About ", /* footer text */ "", - /* window text */ "\x0E\x0C\x01" "XM Player v1.0" + /* window text */ "\x0E\x0C\x01" "XM Player v0.1" }; +void xm_set_status(const char *msg); // defined below, used by error_*() before that point +void xm_set_status_code(const char *msg, u8 code); // ditto + bool esp_init() { esp_cmd(ESP_CMD_NOP); @@ -156,9 +114,9 @@ bool esp_init() bool play_xm() { esp_cmd(ESP_CMD_TRACK_STOP); - esp_wait_busy(10000); + esp_wait_busy(100); // 2s - both should be near-instant esp_cmd(ESP_CMD_KILL_OBJECTS); - esp_wait_busy(10000); + esp_wait_busy(100); u8 obj_type; switch (file_ext) @@ -186,7 +144,7 @@ bool play_xm() esp_wr_reg32(ESP_REG_DATA_SIZE, s); esp_wr_reg32(ESP_REG_DATA_OFFSET, offs); esp_cmd(ESP_CMD_WRITE_OBJECT); - esp_wait_status(ESP_ST_DATA_M2S, 2000); + esp_wait_status(ESP_ST_DATA_M2S, 100); // 2s - near-instant state transition esp_send_dma((u16)fs_buf, *(u8*)_PAGE2, 512, sec); offs += s; @@ -202,7 +160,7 @@ bool play_xm() esp_wr_reg8(ESP_REG_OBJ_TYPE, OBJ_TYPE_XM); esp_wr_reg32(ESP_REG_DATA_SIZE, filesize); esp_cmd(ESP_CMD_UNZIP); - esp_wait_busy(10000); + esp_wait_busy(250); // 5s - decompression time scales with file size last_esp_status = esp_rd_reg8(ESP_REG_STATUS); if (last_esp_status != ESP_ST_READY) @@ -210,14 +168,12 @@ bool play_xm() } esp_cmd(ESP_CMD_TRACK_INIT); - // TRACK_INIT now blocks on the firmware side while it measures the song's - // total sample count, capped at XM_MEASURE_MAX_US = 5s (tracker.cpp) - so - // this needs to comfortably cover 5s of real time, not the ~150ms the old - // 10000-iteration budget worked out to at 14MHz (each esp_wait_busy() - // iteration is a raw SPI status-register read, not a real-time wait). - // Iteration count isn't hardware-calibrated, so this is padded well past - // the 5s firmware cap - bump further if TRACK_INIT still times out. - esp_wait_busy(1000000); + // 400 frames = 8s, comfortably past the firmware's 5s song-length + // measurement cap (XM_MEASURE_MAX_US in tracker.cpp) - see esp_wait_busy() + // in esp32.c for why this needs to be real-time-based, not an iteration + // count (an uncalibrated guess here previously caused ESP_ERR_INV_XM_HANDLE + // failures on heavier files that legitimately needed close to the full 5s). + esp_wait_busy(400); last_esp_status = esp_rd_reg8(ESP_REG_STATUS); if (last_esp_status != ESP_ST_READY) @@ -229,10 +185,14 @@ bool play_xm() esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); esp_wr_reg8(ESP_REG_TRACK_MAX_LOOP_COUNT, 1); esp_cmd(ESP_CMD_TRACK_SET_PARAMS); - esp_wait_busy(10000); + esp_wait_busy(100); // 2s - both should be near-instant esp_cmd(ESP_CMD_TRACK_PLAY); - esp_wait_busy(10000); + esp_wait_busy(100); + + last_esp_status = esp_rd_reg8(ESP_REG_STATUS); + if (last_esp_status != ESP_ST_READY) + return false; return true; } @@ -269,27 +229,99 @@ void about() wc_exit(WC_EXIT); } +// Shared by the main playback key-poll loop and wait_for_manual_exit() - +// stops the track, kills the esp32 objects, closes the window and hands +// control back to WC with the given signal. +void unload_and_exit(WC_EXIT_SIGNAL sig) +{ + esp_cmd(ESP_CMD_TRACK_STOP); + esp_wait_busy(100); // 2s - both should be near-instant + esp_cmd(ESP_CMD_KILL_OBJECTS); + esp_wait_busy(100); + wc_rresb(&win_xm); + wc_exit(sig); +} + +// Space - just leave, no esp32 commands at all: the track keeps playing on +// its own after the plugin exits, only our window/UI goes away. +void leave_playing_and_exit() +{ + wc_rresb(&win_xm); + wc_exit(WC_EXIT); +} + +// Used after an error when stoponerror=1: keeps responding to the same +// navigation keys as normal playback, but issues no esp32 commands and +// touches nothing on screen on its own - only acts once the user actually +// presses PgDn/PgUp/Esc, so the error stays visible for as long as needed. +void wait_for_manual_exit() +{ + while (1) + { + __asm + halt + __endasm; + + if (wc_key_pgdn()) + unload_and_exit(WC_NEXT_FILE); + + if (wc_key_pgup()) + unload_and_exit(WC_PREV_FILE); + + if (wc_key_esc()) + unload_and_exit(WC_EXIT); + } +} + +// Errors used to open their own separate popup window; now they're just +// another Status value on the already-open win_xm, per user request - one +// less window type to keep track of, and errors show up in the same place +// as everything else instead of a separate modal-looking box. void error_esp() { - wc_prwow(&err_no_esp); + // esp_init() currently always returns true (no real detection logic yet, + // see its "+++ detect" comment), so state_esp is the only thing that can + // land here - shown anyway for when real detection is added. + xm_set_status_code("No ESP32 found", state_esp); wait_esc_key(); - wc_rresb(&err_no_esp); + wc_rresb(&win_xm); wc_exit(WC_EXIT); } +// wc_prm_pl(1) reads the "stoponerror" INI parameter declared in wc_h.c - +// the FIRST (and only) declared parameter, and per WC's own PRM_PL doc +// ("i:A' - номер параметра (от 1 до 8)") that's queried 1-based, not +// 0-based as a third-party reference wrongly suggested (which is why this +// never actually triggered - always asking for a nonexistent parameter 0). +// Option 2 ("1") means stop instead of moving on to the next file; option 1 +// ("0", the default) keeps the old auto-advance behavior. 0xFF (param +// missing from an old/malformed header) is treated the same as the default. +u8 stop_on_error() +{ + return wc_prm_pl(1) == 2; +} + void error_oom() { - wc_prwow(&err_out_of_mem); + xm_set_status_code("File too large", last_esp_status); + + if (stop_on_error()) + wait_for_manual_exit(); + wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance - wc_rresb(&err_out_of_mem); + wc_rresb(&win_xm); wc_exit(WC_NEXT_FILE); } void error_playback() { - wc_prwow(&err_playback); + xm_set_status_code("Playback error", last_esp_status); + + if (stop_on_error()) + wait_for_manual_exit(); + wait_frames(50); // show the error for ~1 second (50Hz), then auto-advance - wc_rresb(&err_playback); + wc_rresb(&win_xm); wc_exit(WC_NEXT_FILE); } @@ -314,21 +346,106 @@ void copy_file_name() // Coloring (PRIAT) via demyanenko-d/VGMPLAY.WMF's wc_prsrw_attr() - our own // three hand-rolled attempts all corrupted esp32 file loading; retesting // with their library now that build.bat pins SDCC 4.6.0 + --sdcccall 1. -#define ROW_FILE 1 -#define ATTR_CAPTION 0x45 // cyan ink - "File:" caption +#define ROW_FILE 2 // row 1 left blank - a gap below the header, was too cramped right against it +// Attribute byte for wc_prsrw_attr() is (paper<<4)|ink, 0=black..7=white +// (confirmed on hardware via the old cyan "File:" caption, 0x45 = paper 4 +// green/ink 5 cyan). White paper (7) throughout to match win_xm's own base +// color (0x70). Static captions ("File:", "Status:", "Pattern:", etc.) just +// use plain wc_prsrw() and inherit the window's own black ink - no override +// needed. ATTR_VALUE (blue) is for anything we actually write/update +// (filename, status text, live stats, progress bar); ATTR_ERROR (red) +// overrides that specifically for error text (see xm_set_status_code()). +#define ATTR_VALUE 0x71 // blue on white +#define ATTR_ERROR 0x72 // red on white + +// Status: replaces the window's old baked-in "Playing..." text with a +// dynamic field - shows "Loading..." while play_xm() streams the file to +// the esp32 (can take a noticeable while for a big file - without this the +// window opens with just "File:" and nothing else visibly changes until +// playback starts, which reads as a hung interface), then whatever state/ +// error is worth surfacing from there on (checked against ESP_REG_STATUS/ +// ESP_REG_TRACK_STATUS as those checks get added). +#define ROW_STATUS 3 +#define STATUS_VALUE_X 9 +#define STATUS_VALUE_WIDTH 24 + +static char status_buf[STATUS_VALUE_WIDTH]; + +#define ROW_HINT 10 // one blank row after it, before the bottom border +#define HINT_TEXT "PgUp/PgDn:Track Esc:Stop Space:Leave" void xm_draw_static_labels() { - wc_prsrw_attr(&win_xm, "File:", ROW_FILE, 1, 5, ATTR_CAPTION); - wc_prsrw(&win_xm, file_name, ROW_FILE, 7, strlen(file_name)); + wc_prsrw(&win_xm, "File:", ROW_FILE, 1, 5); + wc_prsrw_attr(&win_xm, file_name, ROW_FILE, 7, strlen(file_name), ATTR_VALUE); + wc_prsrw(&win_xm, "Status:", ROW_STATUS, 1, 7); + // Centered: 38 usable columns (1..38) minus 36-char HINT_TEXT leaves a + // 1-column margin each side, so it starts at column 2. + wc_prsrw(&win_xm, HINT_TEXT, ROW_HINT, 2, sizeof(HINT_TEXT) - 1); +} + +// msg must be in #8000-#BFFF (a string literal or a global/static buffer, +// same constraint as every other wc_prsrw() text pointer here) - pads with +// spaces to STATUS_VALUE_WIDTH so a shorter message never leaves stray +// characters from a longer previous one. +void xm_set_status_attr(const char *msg, u8 attr) +{ + u8 i = 0; + + while (msg[i] && i < STATUS_VALUE_WIDTH) + { + status_buf[i] = msg[i]; + i++; + } + while (i < STATUS_VALUE_WIDTH) + status_buf[i++] = ' '; + + wc_prsrw_attr(&win_xm, status_buf, ROW_STATUS, STATUS_VALUE_X, STATUS_VALUE_WIDTH, attr); +} + +void xm_set_status(const char *msg) +{ + xm_set_status_attr(msg, ATTR_VALUE); +} + +// Same as xm_set_status(), but appends " (0xXX)" with the raw esp status/ +// error code - for on-screen diagnostics, so a failure doesn't need a +// hardware debugger to tell exactly which ESP_ST_*/ESP_ERR_* value it was. +static char status_code_buf[24]; + +void xm_set_status_code(const char *msg, u8 code) +{ + static const char hexch[] = "0123456789ABCDEF"; + u8 i = 0; + + while (msg[i] && i < sizeof(status_code_buf) - 7) + { + status_code_buf[i] = msg[i]; + i++; + } + + status_code_buf[i++] = ' '; + status_code_buf[i++] = '('; + status_code_buf[i++] = '0'; + status_code_buf[i++] = 'x'; + status_code_buf[i++] = hexch[(code >> 4) & 0xF]; + status_code_buf[i++] = hexch[code & 0xF]; + status_code_buf[i++] = ')'; + status_code_buf[i] = 0; + + xm_set_status_attr(status_code_buf, ATTR_ERROR); } // --- Live status display (STEP 3, no coloring - plain wc_prsrw only) ----- -#define ROW_STATS 3 -#define ROW_TIME 5 -#define ROW_BAR 6 -#define BAR_X 1 -#define BAR_WIDTH 34 +#define ROW_STATS 4 +#define ROW_TIME 6 +#define ROW_BAR 8 // blank rows between each of these for spacing +// Window content is 40 wide with a 1-char border each side (38 usable +// columns, x=1..38) - BAR_X=4/BAR_WIDTH=32 gives a 3-column margin on +// both sides (4-1=3 before, 38-(4+32-1)=3 after). Adjust if the actual +// border turns out different on hardware. +#define BAR_X 4 +#define BAR_WIDTH 32 void put_hex2(char *dst, u8 val) { @@ -356,16 +473,6 @@ void put_time(char *dst, u32 sec) dst[4] = '0' + s % 10; } -void xm_draw_stats_labels() -{ - wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); - wc_prsrw(&win_xm, " Row:#", ROW_STATS, 12, 7); - wc_prsrw(&win_xm, " BPM:", ROW_STATS, 21, 6); - - wc_prsrw(&win_xm, "Time:", ROW_TIME, 1, 5); - wc_prsrw(&win_xm, " / ", ROW_TIME, 12, 3); -} - // wc_prsrw()'s text pointer MUST be in #8000-#BFFF (our own code/data // window) - but this plugin runs on WC's OWN stack, which lives in a // DIFFERENT window (#4000-#7FFF, per plugins/READ_ME.TXT: "стек... РІ Win 1 @@ -380,8 +487,39 @@ static char decbuf[3]; static char timebuf[5]; static char barbuf[BAR_WIDTH]; -#define BAR_FILLED_CH '=' -#define BAR_EMPTY_CH '-' +// Attribute plane offset for a character cell = (char_addr & 0x3FFF) | 0x0080 +// (same convention VGMPLAY.WMF's own progress bar uses on this same TS-Conf +// text hardware) - both planes sit in the #C000-#FFFF window that PRWOW/ +// PRSRW/GADRW etc. all leave mapped in on exit. Computed once in +// xm_draw_stats_labels() (window position is fixed for the plugin's +// lifetime) - draw_progress_bar() only ever writes attribute bytes there, +// recoloring the background to grow a solid bar instead of drawing "="/"-" +// characters. +u16 bar_attr_ofs; + +#define ATTR_BAR_FILLED 0x40 // green paper, black ink - filled portion (matches VGMPLAY.WMF's WC_COLOR(WC_GREEN, WC_BLACK)) +#define ATTR_BAR_EMPTY 0x07 // black paper, white ink - unfilled portion + +void xm_draw_stats_labels() +{ + u8 i; + + wc_prsrw(&win_xm, "Pattern:#", ROW_STATS, 1, 9); + wc_prsrw(&win_xm, " Row:#", ROW_STATS, 12, 7); + wc_prsrw(&win_xm, " BPM:", ROW_STATS, 21, 6); + + wc_prsrw(&win_xm, "Time:", ROW_TIME, 1, 5); + wc_prsrw(&win_xm, " / ", ROW_TIME, 12, 3); + + for (i = 0; i < BAR_WIDTH; i++) + barbuf[i] = ' '; + wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); + + bar_attr_ofs = (wc_gadrw(&win_xm, ROW_BAR, BAR_X) & 0x3FFF) | 0x0080; + + for (i = 0; i < BAR_WIDTH; i++) + *(volatile u8*)(0xC000 + bar_attr_ofs + i) = ATTR_BAR_EMPTY; +} void draw_progress_bar(u32 samples, u32 total) { @@ -397,9 +535,7 @@ void draw_progress_bar(u32 samples, u32 total) filled = 0; // total length unknown (measurement timed out) - show empty for (i = 0; i < BAR_WIDTH; i++) - barbuf[i] = (i < filled) ? BAR_FILLED_CH : BAR_EMPTY_CH; - - wc_prsrw(&win_xm, barbuf, ROW_BAR, BAR_X, BAR_WIDTH); + *(volatile u8*)(0xC000 + bar_attr_ofs + i) = (i < filled) ? ATTR_BAR_FILLED : ATTR_BAR_EMPTY; } void xm_update_info() @@ -410,7 +546,7 @@ void xm_update_info() esp_wr_reg8(ESP_REG_OBJ_HANDLE, xm_handle); esp_cmd(ESP_CMD_TRACK_GET_INFO); - esp_wait_busy(2000); + esp_wait_busy(50); // 1s - a plain info read should be near-instant // TRACK_GET_INFO already writes ESP_REG_TRACK_STATUS (same register // TRACK_GET_STATE reports), so no separate command is needed to catch the @@ -419,7 +555,7 @@ void xm_update_info() if (last_track_status == TRACK_OBJ_ST_PLAYING && status == TRACK_OBJ_ST_STOPPED) { esp_cmd(ESP_CMD_KILL_OBJECTS); - esp_wait_busy(10000); + esp_wait_busy(100); wc_rresb(&win_xm); wc_exit(WC_NEXT_FILE); } @@ -434,19 +570,19 @@ void xm_update_info() total_samples = esp_rd_reg32(ESP_REG_TRACK_TOTAL_SAMPLES); put_hex2(hexbuf, pattern); - wc_prsrw(&win_xm, hexbuf, ROW_STATS, 10, 2); + wc_prsrw_attr(&win_xm, hexbuf, ROW_STATS, 10, 2, ATTR_VALUE); put_hex2(hexbuf, row); - wc_prsrw(&win_xm, hexbuf, ROW_STATS, 19, 2); + wc_prsrw_attr(&win_xm, hexbuf, ROW_STATS, 19, 2, ATTR_VALUE); put_dec3(decbuf, bpm); - wc_prsrw(&win_xm, decbuf, ROW_STATS, 27, 3); + wc_prsrw_attr(&win_xm, decbuf, ROW_STATS, 27, 3, ATTR_VALUE); put_time(timebuf, samples / 44100UL); - wc_prsrw(&win_xm, timebuf, ROW_TIME, 7, 5); + wc_prsrw_attr(&win_xm, timebuf, ROW_TIME, 7, 5, ATTR_VALUE); put_time(timebuf, total_samples / 44100UL); - wc_prsrw(&win_xm, timebuf, ROW_TIME, 15, 5); + wc_prsrw_attr(&win_xm, timebuf, ROW_TIME, 15, 5, ATTR_VALUE); draw_progress_bar(samples, total_samples); @@ -456,14 +592,22 @@ void main_start() { u8 frame_ctr; - // Pin the Z80 clock for the whole plugin lifetime - our esp_wait_busy() - // timeouts are iteration counters, not real time, so leaving WC's turbo - // setting as-is would make esp32 SPI timing margins depend on whatever - // frequency happened to be active before the plugin started. - wc_set_freq_14mhz(); - copy_file_name(); + // Open the window before anything esp32-related runs, including the + // detection check - errors go into "Status:" on this same window (see + // error_esp() etc.) rather than a separate popup, and a big file's + // transfer in play_xm() can take a noticeable while, so nothing on + // screen during either would read as a hung interface. This used to be + // deferred until after play_xm() succeeded, because opening a window + // before esp32 activity used to corrupt the transfer - that was tied to + // our old hand-rolled PRSRW/PRIAT wrappers, not to window timing itself, + // and no longer applies now that we're on the real vgm_wc_api library + // (see project memory). + wc_prwow(&win_xm); + xm_draw_static_labels(); + xm_set_status("Loading, please wait..."); + if (state_esp == 0xFF) state_esp = esp_init() ? 1 : 2; @@ -484,11 +628,7 @@ void main_start() return; } - // Draw the status window only AFTER play_xm() has already finished the - // file transfer and issued TRACK_INIT/TRACK_PLAY - drawing a window - // beforehand previously corrupted the esp32 transfer (see project memory). - wc_prwow(&win_xm); - xm_draw_static_labels(); + xm_set_status("Playing"); xm_draw_stats_labels(); last_track_status = TRACK_OBJ_ST_PLAYING; xm_update_info(); @@ -509,34 +649,16 @@ void main_start() } if (wc_key_pgdn()) // PgDn - unload and go to next file - { - esp_cmd(ESP_CMD_TRACK_STOP); - esp_wait_busy(10000); - esp_cmd(ESP_CMD_KILL_OBJECTS); - esp_wait_busy(10000); - wc_rresb(&win_xm); - wc_exit(WC_NEXT_FILE); - } + unload_and_exit(WC_NEXT_FILE); if (wc_key_pgup()) // PgUp - unload and go to previous file - { - esp_cmd(ESP_CMD_TRACK_STOP); - esp_wait_busy(10000); - esp_cmd(ESP_CMD_KILL_OBJECTS); - esp_wait_busy(10000); - wc_rresb(&win_xm); - wc_exit(WC_PREV_FILE); - } + unload_and_exit(WC_PREV_FILE); if (wc_key_esc()) // Esc - unload and exit - { - esp_cmd(ESP_CMD_TRACK_STOP); - esp_wait_busy(10000); - esp_cmd(ESP_CMD_KILL_OBJECTS); - esp_wait_busy(10000); - wc_rresb(&win_xm); - wc_exit(WC_EXIT); - } + unload_and_exit(WC_EXIT); + + if (wc_key_space()) // Space - leave the track playing, just exit + leave_playing_and_exit(); } } diff --git a/src/wc_api.c b/src/wc_api.c index c0f7eb9..79209a5 100644 --- a/src/wc_api.c +++ b/src/wc_api.c @@ -23,9 +23,22 @@ u8 wc_load512(u16 dest, u8 blocks); u8 wc_key_esc(void); u8 wc_key_pgup(void); u8 wc_key_pgdn(void); +u8 wc_key_space(void); void wc_prsrw(void *win, const u8 *text, u8 y, u8 x, u16 len); void wc_prsrw_attr(void *win, const u8 *text, u8 y, u8 x, u16 len, u8 attr); +// y/x are 1-based; returns the character cell's address (relative to the +// #C000 window GADRW/PRWOW/PRSRW etc. all leave mapped in on exit) - see +// main.c's bar_attr_ofs for how the attribute-plane byte is derived from it. +u16 wc_gadrw(void *win, u8 y, u8 x); + +// param_num is 1-based (matching WC's own PRM_PL doc, "i:A' - номер +// параметра (от 1 до 8)" - NOT 0-based as a third-party reference wrongly +// suggested, see main.c's stop_on_error()); returns the 1-based selected +// option index ("от 1 до 10"), or 0xFF if the plugin header doesn't declare +// that parameter at all. +u8 wc_prm_pl(u8 param_num); + // wc_exit is ours, not theirs - it unwinds our own crt0.s's saved SP // (_ret_sp) to return control to WC, so there's no equivalent in their // library to borrow. Adjusted for sdcccall(1): a single u8 argument now @@ -39,25 +52,3 @@ void wc_exit(u8 rc) __naked ret __endasm; } - -// _TURBOPL (0x0E) is also ours - not wrapped by vgm_wc_api.lib. Our -// esp_wait_busy()/esp_wr_end()/etc. timeouts are plain iteration counters, -// not real-time based, so they implicitly assume a specific Z80 clock; if WC -// was left in turbo mode before the plugin started, the same iteration -// budget covers less real time and could cut SPI exchanges with the esp32 -// short. Pinning a known frequency for the whole plugin lifetime removes -// that as a variable - set once at startup, left as-is on exit (per user -// request, not restored to whatever WC had before). No parameters (avoids -// depending on exactly how two u8 args would be register-assigned under -// --sdcccall 1 - not worth the risk for a fixed value), and IX isn't -// preserved since _WCAPI clobbering it is already tolerated by every other -// call in this file. -void wc_set_freq_14mhz() __naked -{ - __asm - ld b, #0x00 ; type: Z80 frequency - ld c, #0x02 ; %10 = 14 MHz - ld a, #_TURBOPL - jp _WCAPI - __endasm; -} diff --git a/src/wc_h.c b/src/wc_h.c index 3b5b827..3081c66 100644 --- a/src/wc_h.c +++ b/src/wc_h.c @@ -2,11 +2,18 @@ #include #include +// STOPONERROR_PARAM: index passed to wc_prm_pl() to read this back (0-based, +// so this is the 1st and only declared parameter). Its declared options are +// "0" (default, at 1-based option index 1 - keep the old auto-advance +// behavior) and "1" (option index 2 - stop instead of moving to the next +// file after an error). See main.c's error_oom()/error_playback(). +#define STOPONERROR_PARAM 0 + static const WC_HDR hdr = { /* +00 -reserved- */ "", /* +16 Magic string */ {'W', 'i', 'l', 'd', 'C', 'o', 'm', 'm', 'a', 'n', 'd', 'e', 'r', 'M', 'D', 'L'}, - /* +32 Format version */ 7, + /* +32 Format version */ 10, // WC_PLUGIN_VERSION - v1.09+ needed for the INI param list below (PRM_PL) /* +33 -reserved- */ "", /* +34 Number of pages */ 1, /* +35 Page at 0x8000 */ 0, @@ -21,6 +28,15 @@ static const WC_HDR hdr = /* */ }, /* +160 0x00 */ "", /* +161 Max file size */ 0xFFFFFFFF, - /* +165 Plugin name */ "XM Player", - /* +197 Starting condition */ SC_MENU // also run by extension + /* +165 Plugin name */ "XM Player v0.1", + /* +197 Starting condition */ SC_MENU, // also run by extension + /* +198 -reserved- */ "", + /* +260 INI parameters */ { + /* record length (incl. this byte): 1+1+11+1+4 = 18 */ 18, + /* default option (1-based) */ 1, + /* parameter name, no terminator, no CAPS */ 's','t','o','p','o','n','e','r','r','o','r', + /* option count */ 2, + /* "0",0, "1",0 */ '0', 0, '1', 0, + /* end of parameter list */ 0 + /* */ } }; diff --git a/src/wc_h.h b/src/wc_h.h index d32d3dc..d3dd8ce 100644 --- a/src/wc_h.h +++ b/src/wc_h.h @@ -32,5 +32,6 @@ typedef struct u32 file_max_size; /* +161 Max file size */ char name[32]; /* +165 Plugin name */ SCOND cond; /* +197 Starting condition */ - u8 res4[314]; /* +198 -reserved- */ + u8 res4[62]; /* +198 -reserved- */ + u8 ini_params[252]; /* +260 INI parameter list (WC v1.09+, PRM_PL) */ } WC_HDR;