Hello, I'm trying to power up a Flora and a 16 led Neopixel ring, with a lipo battery, 3.7v 1000 mAh.
When i touch the copper plate it supposed to turn the ring on with red, and then turn off when no touching anything. It works just fine when the ring and the flora are powered with an usb (one for each) but when I change the flora to be powered with the battery, and touch the copper, the ring goes crazy, flickers in every color and it's a mess. If I power the ring with the battery and the flora via usb, the ring just doesn't light. If I try to power both with the battery it just does nothing, lol. I tried putting a step up between the battery and the flora or ring but it's the same. Help.
Problem powering Flora and Neopixel Ring
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- Vulkan52
- Posts: 13
- Joined: Thu May 05, 2022 1:01 pm
Problem powering Flora and Neopixel Ring
- Attachments
-
- Untitled-1.jpg (750.88 KiB) Viewed 124 times
- dastels
- Posts: 15608
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Problem powering Flora and Neopixel Ring
I assume you want this wearable and battery powered. It would help if you posted your code. Without seeing it, all that comes to mind is that I'd try powering the ring with the 3.3v output from the Flora. The catch is that that can only provide 250mA (less what the flora needs). 16 NeoPixels set yo full brightness red needs 320mA. So if you drop the brightness it will use less. Half brightness would be good. That's usually not a big problem as NeoPixels are really bright.
Dave
Dave
- Vulkan52
- Posts: 13
- Joined: Thu May 05, 2022 1:01 pm
Re: Problem powering Flora and Neopixel Ring
This is my horrible code(?)
As I said, it works very well when both are powered from usb cables...
Code: Select all
#include <Adafruit_NeoPixel.h>
#include <CapacitiveSensor.h>
#ifdef __AVR__
#include <avr/power.h> // Required for 16 MHz Adafruit Trinket
#endif
#define PIN 6
#define NUMPIXELS 16
CapacitiveSensor cs_9_10 = CapacitiveSensor(9,10); // 10M
Adafruit_NeoPixel strip(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800);
void setup() {
strip.begin();
strip.show(); // Initialize all pixels to 'off'
cs_9_10.set_CS_AutocaL_Millis(0xFFFFFFFF); // turn off autocalibrate on channel 1 - just as an example
Serial.begin(9600);
}
void loop() {
long start = millis();
long total1 = cs_9_10.capacitiveSensor(30);
if (total1 > 4000){
strip.setPixelColor(0, 255, 0, 0);
strip.setPixelColor(1, 255, 0, 0);
strip.setPixelColor(2, 255, 0, 0);
strip.setPixelColor(3, 255, 0, 0);
strip.setPixelColor(4, 255, 0, 0);
strip.setPixelColor(5, 255, 0, 0);
strip.setPixelColor(6, 255, 0, 0);
strip.setPixelColor(7, 255, 0, 0);
strip.setPixelColor(8, 255, 0, 0);
strip.setPixelColor(9, 255, 0, 0);
strip.setPixelColor(10, 255, 0, 0);
strip.setPixelColor(11, 255, 0, 0);
strip.setPixelColor(12, 255, 0, 0);
strip.setPixelColor(13, 255, 0, 0);
strip.setPixelColor(14, 255, 0, 0);
strip.setPixelColor(15, 255, 0, 0);
strip.show();
}
else {
strip.clear();
strip.show();
}
}
- dastels
- Posts: 15608
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Problem powering Flora and Neopixel Ring
A couple things.
You can use but you should try a lower brightness of red, e.g.
I would also add a capacitor as described in the NeoPixel guide: https://learn.adafruit.com/adafruit-neopixel-uberguide, specifically
You can use
Code: Select all
strip.fill(strip.Color(255, 0, 0))
Code: Select all
strip.fill(strip.Color(128, 0, 0))
DaveBefore connecting NeoPixels to any large power source (DC “wall wart” or even a large battery), add a capacitor (500–1000 µF at 6.3V or higher) across the + and – terminals as shown above. The capacitor buffers sudden changes in the current drawn by the strip.
- Vulkan52
- Posts: 13
- Joined: Thu May 05, 2022 1:01 pm
Re: Problem powering Flora and Neopixel Ring
Well, now it works, but... instead of lighting up when touching the copper plate, it work when i touch the battery... ???? USB keeps working fine with both plugged on usb...
- dastels
- Posts: 15608
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Problem powering Flora and Neopixel Ring
Huh. Maybe try a long wire to the sensor so your hand isn;'t too near the Flora.
Dave
Dave
- Vulkan52
- Posts: 13
- Joined: Thu May 05, 2022 1:01 pm
Re: Problem powering Flora and Neopixel Ring
Its a 1 meter wire lol and yes, it's weird whats happening...
- dastels
- Posts: 15608
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Problem powering Flora and Neopixel Ring
Is it shielded/twisted pair. You want the pad to act as the antenna, not the entire length of the wire.
Dave
Dave
- Vulkan52
- Posts: 13
- Joined: Thu May 05, 2022 1:01 pm
Re: Problem powering Flora and Neopixel Ring
It's not shielded, but I don't think it matters cuz it works fine when using usb as power source :S ??
- dastels
- Posts: 15608
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Problem powering Flora and Neopixel Ring
Hmm. As a work around, would powering from a USB powerbank work?
Dave
Dave
- Vulkan52
- Posts: 13
- Joined: Thu May 05, 2022 1:01 pm
Re: Problem powering Flora and Neopixel Ring
mmm I don't have one, I would ask a friend is they have one and see what's up.
Please be positive and constructive with your questions and comments.