Skip to content

overclock question #51

@negativeExponent

Description

@negativeExponent

the overclock logic is incorrect.

NST_SINGLE_CALL void Apu::Dmc::WriteReg2(const uint data)
{
regs.address = 0xC000 | (data << 6);
if (regs.address != 0)
{
overclockingIsSafe = true;
}
}

overclockingIsSafe will always be true because regs.address is guaranteed to be at least have a value of 0xC000

NST_SINGLE_CALL void Apu::Dmc::WriteReg3(const uint data)
{
regs.lengthCounter = (data << 4) + 1;
if (regs.lengthCounter != 0)
{
overclockingIsSafe = true;
}
}

same here. regs.lengthCounter will always be at least 1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions