The set_pwm_freq() method needs updating to check for variant (SAMD vs ATtiny) and change the first byte of cmd appropriately. See analog_write() for an example where this is already done.
As is, the first byte will be incorrect for ATtiny variants. It should be Arduino pin number.
The
set_pwm_freq()
method needs updating to check for variant (SAMD vs ATtiny) and change the first byte ofcmd
appropriately. Seeanalog_write()
for an example where this is already done.As is, the first byte will be incorrect for ATtiny variants. It should be Arduino pin number.