SpenceKonde / megaTinyCore

Arduino core for the tinyAVR 0/1/2-series - Ones's digit 2,4,5,7 (pincount, 8,14,20,24), tens digit 0, 1, or 2 (featureset), preceded by flash in kb. Library maintainers: porting help available!
Other
542 stars 140 forks source link

EVSYS gen1 not declared? #1060

Closed FactoryOptic closed 3 months ago

FactoryOptic commented 4 months ago

ATtiny3227

#include <Event.h>
#include <Logic.h>

void setup() {
    // EVSYS.ASYNCCH0 = EVSYS_ASYNCCH0_PORTA_PIN6_gc; /* Asynchronous Event from Pin PA6 */
    Event0.set_generator( gen0::pin_pa6 ); // Set pin Pa6 as event generator, Event0

    // EVSYS.ASYNCCH1 = EVSYS_ASYNCCH1_PORTB_PIN6_gc; /* Asynchronous Event from Pin PB6 */
    Event1.set_generator( gen1::pin_pb6 ); // Set pin PB6 as event generator, Event1
}

void loop() {
}

Getting:

Using library Event at version 1.3.0 in folder: /Users/someone/Library/Arduino15/packages/megaTinyCore/hardware/megaavr/2.6.10/libraries/Event 
Using library Logic at version 1.3.1 in folder: /Users/someone/Library/Arduino15/packages/megaTinyCore/hardware/megaavr/2.6.10/libraries/Logic 
exit status 1

Compilation error: 'gen1' has not been declared
SpenceKonde commented 3 months ago

Improper tests were carried out to see whether that namespace should exist, and if so, make it available.

SpenceKonde commented 3 months ago

Fixed by dc86020