Browse Source
Merge pull request #143 from electrified/dev
Tune: Add printing of song name and artist for PT2 and PT3s
pull/144/head
Wayne Warthen
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
25 additions and
2 deletions
-
Source/Apps/Tune/Tune.asm
-
Source/Apps/Tune/printing.inc
|
|
|
@ -295,7 +295,27 @@ GOPT3 LD A,0 ; SETUP value to PT3 sound files |
|
|
|
LD DE,185 ; Avg TS / quark = 7400, so 185 delay loops |
|
|
|
JR GOPTX ; Play PTx file |
|
|
|
|
|
|
|
GOPTX LD HL,(QDLY) ; Get basic quark delay |
|
|
|
GOPTX |
|
|
|
CALL CRLF2 |
|
|
|
LD DE, MSGSONGNAME ; Print song name message |
|
|
|
CALL PRTSTR |
|
|
|
LD DE, MDLADDR + $1E ; Print 32 character long song name from module |
|
|
|
LD B, $20 |
|
|
|
GOPTX1 LD A,(DE) |
|
|
|
CALL PRTCHR |
|
|
|
INC DE |
|
|
|
DJNZ GOPTX1 |
|
|
|
CALL CRLF |
|
|
|
LD DE, MSGARTIST ; Print "by" message |
|
|
|
CALL PRTSTR |
|
|
|
LD DE, MDLADDR + $42 ; Print 32 character long composer/artist from module |
|
|
|
LD B, $20 |
|
|
|
GOPTX2 LD A,(DE) |
|
|
|
CALL PRTCHR |
|
|
|
INC DE |
|
|
|
DJNZ GOPTX2 |
|
|
|
CALL CRLF |
|
|
|
LD HL,(QDLY) ; Get basic quark delay |
|
|
|
OR A ; Clear carry |
|
|
|
SBC HL,DE ; Adjust for file type |
|
|
|
LD (QDLY),HL ; Save updated quark delay factor |
|
|
|
@ -609,6 +629,9 @@ HWSTR_RCEB .DB "RC2014 Sound Module (EB)",0 |
|
|
|
HWSTR_RCMF .DB "RC2014 Sound Module (MF)",0 |
|
|
|
|
|
|
|
MSGUNSUP .db "MYM FILES NOT SUPPORTED YET\r\n", 0 |
|
|
|
|
|
|
|
MSGSONGNAME .DB "Song name: ", 0 |
|
|
|
MSGARTIST .DB "by: ", 0 |
|
|
|
; |
|
|
|
;=============================================================================== |
|
|
|
; PTx Player Routines |
|
|
|
|
|
|
|
@ -24,7 +24,7 @@ PRTDOT: |
|
|
|
; |
|
|
|
PRTCR: |
|
|
|
; |
|
|
|
; shortcut to print a dot preserving all regs |
|
|
|
; shortcut to print a carriage return preserving all regs |
|
|
|
PUSH AF ; save af |
|
|
|
LD A,13 ; load CR value |
|
|
|
CALL PRTCHR ; print it |
|
|
|
|