system
September 2, 2013, 1:16pm
1
I'm trying to make a ir transmitter with a attiny 84.
I use the irtinytx library.
Do I have to change something in the irtinytx library so it works for attiny84?
The library is default set to transmit on PB1, which is not a pwm output on the attiny84.
Chagrin
September 2, 2013, 6:22pm
2
You want the library from: GitHub - Arduino-IRremote/Arduino-IRremote: Infrared remote library for Arduino: send and receive infrared signals with multiple protocols . Your link appears to be specific to the ATTiny85; this link should work for anything except the '85, notably the ATTiny84.
The IR libraries do not use PWM; they use a timer interrupt to set the frequency. In either library, in the file IRremoteInt.h you'll see a number of #defines like:
#elif defined(__AVR_ATmega644P__) || defined(__AVR_ATmega644__)
#elif defined(__AVR_ATmega8P__) || defined(__AVR_ATmega8__)
#elif defined( __AVR_ATtinyX4__ )
That's your reference for what chips the library has been configured for.
system
September 4, 2013, 2:31pm
3
If pwm is not being used, why enable / disable them?
From IRremote.cpp
TIMER_ENABLE_PWM; // Enable pin 3 PWM output
From IRTinyTX.cpp
TCCR0A |= _BV(COM0B1); // Enable pin 6 (PB1) PWM output