Skip to content

THB6128: Mixed decay "forced fast decay" mode has some incorrect edge cases #29

@rcarlyle

Description

@rcarlyle

When the THB6128 is in mixed decay and the on-phase blanking time is entirely above the target current for its entire duration, the driver switches to fast decay for the entire remainder of that PWM cycle. This primarily comes into play during falling-current microsteps to let the driver hit the target faster.

The way the sheet captures this behavior is to check if the tick is in a blanking period, and if so, check if the initial current in that tick is above the target current. This works ok, but some edge cases cause it to not work properly:

  1. If the current rises above the target during a blanking period, and a new tick is created after that, so the last tick within the blanking period only "sees" the portion that is above the target.
  2. If extremely high back-emf causes the current to drop from above the target to below the target during the blanking period. (Super unlikely)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions