Closed GoogleCodeExporter closed 8 years ago
> Mapping of pins for Attiny84 in core_pins.h and pins_arduino.c is incorrect.
Explain why.
Provide a test case.
Original comment by arduino....@gmail.com
on 11 Dec 2014 at 9:14
That is somehow difficult. The result is that the code working well while built
with Arduino 1.0.5 and ATtiny master.zip from Dave Mellis.
See pin layout from master.zip below.
// ATMEL ATTINY84 / ARDUINO
//
// +-\/-+
// VCC 1| |14 GND
// (D 10) PB0 2| |13 AREF (D 0)
// (D 9) PB1 3| |12 PA1 (D 1)
// PB3 4| |11 PA2 (D 2)
// PWM INT0 (D 8) PB2 5| |10 PA3 (D 3)
// PWM (D 7) PA7 6| |9 PA4 (D 4)
// PWM (D 6) PA6 7| |8 PA5 (D 5) PWM
// +----+
This is according the original description as shown in the Atmel Data sheet for
the Attiny84 on page 2 (PIN layout)
LED led[3] ={ LED(PA6), LED(PA7), LED(PA5)};
LED is my own class and LEDs are connected to PA6, PA7 and PA5.
According the Arduino concept I can use 6,7 and 5, too.
Compiling the same code using an unmodified attiny core 1.5 only
LED connected to PA5 is working. I have to reconnect teh LEDs to PA3 and PA4.
In tiny core the mapping P -> D has changed. For what reason?
See below. So to be compiant with software developped using 1.0.5 I have to
modify attiny core.
// ATMEL ATTINY84 / ARDUINO
//
// +-\/-+
// VCC 1| |14 GND
// (D 0) PB0 2| |13 AREF (D 10)
// (D 1) PB1 3| |12 PA1 (D 9)
// PB3 4| |11 PA2 (D 8)
// PWM INT0 (D 2) PB2 5| |10 PA3 (D 7)
// PWM (D 3) PA7 6| |9 PA4 (D 6)
// PWM (D 4) PA6 7| |8 PA5 (D 5) PWM
// +----+
Original comment by f41...@googlemail.com
on 11 Dec 2014 at 9:47
> In tiny core the mapping P -> D has changed. For what reason?
Your question is misplaced. The pin mapping with this core has never changed.
This core was published long before David Mellis' version.
If you don't like the pin mapping then change it. You have the source code.
Or, complain to David Mellis.
Or, provide a mapping / translation in your code.
But a difference in pin mapping is not a bug.
Original comment by arduino....@gmail.com
on 11 Dec 2014 at 10:16
Original issue reported on code.google.com by
f41...@googlemail.com
on 11 Dec 2014 at 7:54Attachments: