ffffiiiiixxxx #47

This commit is contained in:
tildearrow 2022-01-21 04:35:25 -05:00
parent bc32809ecb
commit 4cffcc01e5

View file

@ -47,6 +47,7 @@ void DivPlatformSMS::tick() {
for (int i=0; i<3; i++) {
if (chan[i].freqChanged) {
chan[i].freq=parent->calcFreq(chan[i].baseFreq,chan[i].pitch,true);
if (chan[i].freq>1023) chan[i].freq=1023;
if (chan[i].note>0x5d) chan[i].freq=0x01;
rWrite(0x80|i<<5|(chan[i].freq&15));
rWrite(chan[i].freq>>4);
@ -57,6 +58,7 @@ void DivPlatformSMS::tick() {
updateSNMode=false;
// seems arbitrary huh?
chan[3].freq=parent->calcFreq(chan[3].baseFreq,chan[3].pitch-1,true);
if (chan[3].freq>1023) chan[3].freq=1023;
if (chan[3].note>0x5d) chan[3].freq=0x01;
chan[3].freqChanged=false;
if (snNoiseMode&2) { // take period from channel 3