PaulStoffregen / TimerOne

TimerOne Library with optimization and expanded hardware support
http://www.pjrc.com/teensy/td_libs_TimerOne.html
470 stars 209 forks source link

Lacking support for pwm pins 0 and 1 on ATTiny85 #45

Open The-Unnamed-Engineer opened 4 years ago

The-Unnamed-Engineer commented 4 years ago

Description

I've been working on a project using TimerOne's pwm functionality on an Arduino Uno. Now that the prototype code is working we'd like to downsize our ptototype to an ATTiny85. However, TimerOne lacks support for the PWM function on an ATTiny85.

I may make an attempt to add this functionality myself at a later date if nobody else figures out how. Today was my first day working with an Arduino(or C for that matter) in three years so I'm a bit out of practice.

Steps To Reproduce Problem

Attempt to call Timer1.pwm() when programming an ATTiny85

Hardware & Software

Board ATTiny85-20PU Shields / modules used None Arduino IDE version 1.8.13 Version info & package name (from Tools > Boards > Board Manager) Operating system & version Ubuntu 18.04 Budgie Any other software or hardware? Using Arduino Uno as ISP

Arduino Sketch

NOTE: Sketch will be added once I receive the new set of ATTiny85s

// Change the code below by your sketch (please try to give the smallest code which demonstrates the problem)
#include <Arduino.h>

// libraries: give links/details so anyone can compile your code for the same result

void setup() {
}

void loop() {
}

Errors or Incorrect Output

If you see any errors or incorrect output, please show it here. Please use copy & paste to give an exact copy of the message. Details matter, so please show (not merely describe) the actual message or error exactly as it appears.