Alternate Push Button Input

Adafruit's tiny microcontroller platform. Please tell us which board you are using.
For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
HeliconEnt
 
Posts: 6
Joined: Thu Oct 14, 2021 12:03 pm

Alternate Push Button Input

Post by HeliconEnt »

Greetings all,

I am trying to determine if there are any alternate pins on the Trinket M0 that can be used for a push button input. The usual pins 0 and 2 in my project are needed for I2C output (SDA/SCL) to an LED Driver IC. I was hoping to be able to integrate a push-button trigger to be able to toggle through lighting sequences. Can I use pin 7 or 8 for that purpose?


Muscle Nerd Jerry

User avatar
adafruit_support_carter
 
Posts: 29473
Joined: Tue Nov 29, 2016 2:45 pm

Re: Alternate Push Button Input

Post by adafruit_support_carter »

Do you mean physical pins 7 and 8? The ones labeled 4 and 3 on the Trinket?

Yes. They can be used. There are 5 total GPIO pins available on the Trinket M0:
https://learn.adafruit.com/adafruit-tri ... no/pinouts
The I2C pins SDA and SCL only use two of them: 0 and 2. So the other 3 are available for whatever.

User avatar
michaelmeissner
 
Posts: 1830
Joined: Wed Aug 29, 2012 12:40 am

Re: Alternate Push Button Input

Post by michaelmeissner »

Sure you should be able to use pins 7 or 8 (labeled 3 and 4) for a push button input. Both of these pins are also capable of touch input.

Alternatively, if you are using pins 0 and 1 for I2C, you could put an I2C device on your I2C bus to provide push buttons, such as: For I2C, you would have to make sure that any other I2C devices don't have the same address as the boards above.

User avatar
HeliconEnt
 
Posts: 6
Joined: Thu Oct 14, 2021 12:03 pm

Re: Alternate Push Button Input

Post by HeliconEnt »

Thanks gang! That's a big load off my mind!

Jerry

Locked
Please be positive and constructive with your questions and comments.

Return to “Trinket ATTiny, Trinket M0”