Question about pins for driving a DotStar strip

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
JeffMThomas
 
Posts: 2
Joined: Sun Sep 19, 2021 1:44 pm

Question about pins for driving a DotStar strip

Post by JeffMThomas »

I'm running a strip of 77 DotStars with a Trinket M0 and really want to use pin 2 for the clock and pin 0 for data but it doesn't seem to work. Using pin 2 for clock and pin 4 for data works great but switching data to pin 0 does not. I know pin 1 won't work for PWM, but 0 should work according to the docs. I'm initializing the strip with

Adafruit_DotStar strip2 = Adafruit_DotStar(NUMSTRIP, 0, 2, DOTSTAR_BGR);

but the strip stays dark, then goes white. If I use 4 instead of 0 it works fine. Any insight would be helpful. I know pin 0 on this board works because if I use it as a touch trigger it works fine.

Thanks!

User avatar
JeffMThomas
 
Posts: 2
Joined: Sun Sep 19, 2021 1:44 pm

Re: Question about pins for driving a DotStar strip

Post by JeffMThomas »

Ok, so apparently pin 1 does work for driving the DotStars but 0 does not. Maybe the documentation was wrong?

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

Re: Question about pins for driving a DotStar strip

Post by adafruit_support_carter »

Could be something else. I just connected a Dotstar strip to a Trinket M0 and this example worked:

Code: Select all

#include <Adafruit_DotStar.h>

#define NUMPIXELS 3
#define DATAPIN    0
#define CLOCKPIN   2

Adafruit_DotStar strip(NUMPIXELS, DATAPIN, CLOCKPIN, DOTSTAR_BRG);

void setup() {
  strip.begin();
  strip.fill(0xADAF00);
  strip.show();
}

void loop() {
}
Try running that and see if you can at least get the first 3 pixels to light up.

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

Return to “Trinket ATTiny, Trinket M0”