Skip to content

DigitalWrite/TurnOffPWM interferes with alternative Timers #75

Open
@bridystone

Description

@bridystone

I have a program that makes heavy use of timers with PWM.
TCA-Split Timer + TCB 0/1 timers
I've changed sometimes the default PORTMUX (i.e. for the TCB timers)

When I now use a PIN with default PWM functionality (i.e. PIN3) it disables the corresponding TCB timer.
first I've changed the PINs, but now it turns out, that I quite use every available PIN on the Nano Every.

I now changed the core library to not turnoff PWM, by changing the const digital_pin_timer.
However would like to have it still in standard mode.

I've also tried to overwrite the const static digital_pin_timer with NOT_ON_TIMER (by pointer usage)
However this didn't work.

SO - do you have an idea how to prevent the timers to be disabled, when using them on different PORTMUX?
Is the only way to additionally check in the DigitalWrite(or TurnOffPWM), if the PORTMUX is the default one?

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