Skip to content

Commit

Permalink
Basic function for MT-32 Character display message, not working yet
Browse files Browse the repository at this point in the history
  • Loading branch information
viti95 committed Dec 9, 2024
1 parent dcc6405 commit 865c983
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions FASTDOOM/dmx.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,24 @@ int MUS_ChecksumRoland(unsigned char* bytes, int length) {
return (0x80 - checkSum) % 0x80;
}

unsigned char TextMT32[28] = {0x41,0x10,0x16,0x12,0x20,0x00,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF};

void MUS_TextMT32(unsigned char* text) {
int i;
unsigned char *mt32ptr = TextMT32 + 7;

for (i=0; i<20; i++)
{
*(mt32ptr) = *(text);
mt32ptr++;
text++;
}

*(mt32ptr) = MUS_ChecksumRoland(text, 20);

// TODO: Send SysEx
}

char mt32file[13] = "MT32GM.MID";

int MUS_LoadMT32(void)
Expand Down

0 comments on commit 865c983

Please sign in to comment.