Skip to content

to prevent N163's DC drifting error - #423

Closed
Nemo55aa wants to merge 4 commits into
Dn-Programming-Core-Management:mainfrom
Nemo55aa:N163_DCerror
Closed

to prevent N163's DC drifting error#423
Nemo55aa wants to merge 4 commits into
Dn-Programming-Core-Management:mainfrom
Nemo55aa:N163_DCerror

Conversation

@Nemo55aa

@Nemo55aa Nemo55aa commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

This pull request aims to fix :N163 loses volume during playback and goes silent (by DC drift).

  • Before this change:
    N163 loses volume during playback and goes silent.
    Even if any volume column or note-stop placed.
    Sample module :
    samples_#423.zip
    Main reason is N163's blip_buffer update.
    Since Blip_buffer is buffer of delta (not a buffer of each sample of amplitude), Those should telescopes with zero error.

  • After this change :
    Blip_buffer has rounding error feedback.
    This bounds the accumulated error to below 1 LSB forever.

  • Hardening fo DC offset :
    For hardening, i added dc cutoff to N163 channel. With this, even if without this feedback N163 cuts off DC drift.


Changes:

Comment thread Source/APU/N163.cpp

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I personally am against this change, as DC offsets must be preserved until the final global filter.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay! Should we consider just rounding errors ?
Is this N163 instrument waveform is count as just way-rare case ?
if even the DC offset is part of emulation, somewhere somehow dn-fami detects DC offsets and let user know that might be helpful.

@Nemo55aa Nemo55aa closed this Aug 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants