On Saturday, August 13, 2022 we will be working on the Adafruit Customer Support Forums. If you visit over the weekend and things are not complete yet, please check back later, https://adafruit.com/forumupdates
0

Does this schematic work?
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Does this schematic work?

by djanim8 on Sat May 14, 2022 8:23 am

I found these instructions on printable.com and wanted to create this lightsaber for my nephew. The instructions have all the parts from Adafruit needed to build the LED light saber part. https://drive.google.com/file/d/18VLbrH3jCZeQhoFcfHirJoO91-aC4By4/view

In the instructions, it has this schematic drawing: https://learn.adafruit.com/assets/41583. The battery used in the instructions links to a 3.7v battery connected to the LiPoly backpack and the Trinket M0.

My question is, the LEDs say they require 5v, but this schematic uses 3.7v for everything. Will this work?

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by adafruit_support_bill on Sat May 14, 2022 8:35 am

Yes, WS2812 and SK6812 LEDs work just fine at 3.7v. Most of our portable and wearable projects using these LEDs are designed around 3.7v LiPo power.

adafruit_support_bill
 
Posts: 84381
Joined: Sat Feb 07, 2009 10:11 am

Re: Does this schematic work?

by djanim8 on Sat May 14, 2022 8:45 am

Great thank you! Can't wait to get the parts in!

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by djanim8 on Thu May 19, 2022 7:40 pm

This isn't working for me. I can't get the LEDs to turn on at all.

I've triple-checked the wiring and it's all connected the same as the diagram. I used my voltmeter and the output for power for the LEDs is 3.75 as it should be. I'm not sure what the digital line from #4 should be, but it reads 0.003 to 0.009 while it's connected. I assumed the switch would cut the power to the LEDs in one position, but it's always showing 3.75 volts no matter where the switch is.

What could be wrong? I tried a different backpack board to see if it was that, but I'm getting the same thing.

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by adafruit_support_bill on Thu May 19, 2022 8:31 pm

If you post some photos showing all your soldering and connections we can take a look.

adafruit_support_bill
 
Posts: 84381
Joined: Sat Feb 07, 2009 10:11 am

Re: Does this schematic work?

by djanim8 on Thu May 19, 2022 8:52 pm

There are 2 yellow wires, one to the USB output on the M0 and one to the switch. I've ensured they are in the right connections.

The wires to the LED strip aren't soldered, but I do have them connected properly. The black cable to ground, power to red and data from #4 to white.

20220519_202930.jpg
20220519_202930.jpg (531.46 KiB) Viewed 102 times

20220519_203031.jpg
20220519_203031.jpg (569.32 KiB) Viewed 102 times

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by djanim8 on Thu May 19, 2022 8:56 pm

This is the code in the main.py file on the M0 board. For now it's set to 60, but will change when I add the second meter and cut them down. I was trying to test this with the 60 LED single strip first.

Code: Select all | TOGGLE FULL SIZE
# Lightsaber Script
import board
import neopixel
import time

pixel_pin = board.D4
pixel_count = 60
pixel_num = 60
diff_pixels = 60

pixels = neopixel.NeoPixel(pixel_pin, pixel_count, brightness=1, auto_write=False,)

RED = (255, 0, 0)
GREEN = (0, 255, 0)
BLUE = (0, 0, 255)
YELLOW = (255, 255, 0)
CYAN = (0, 255, 255)
WHITE = (255, 255, 255)

for i in range(0, diff_pixels):
pixels[i] = CYAN
#pixels[pixel_num-i] = CYAN
pixels.write()
time.sleep(0.01)

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by adafruit_support_bill on Thu May 19, 2022 9:02 pm

I assumed the switch would cut the power to the LEDs in one position, but it's always showing 3.75 volts no matter where the switch is.

The power switch won't do anything unless you cut the trace as described in the guide: https://learn.adafruit.com/adafruit-pro ... -1942369-6

The wires to the LED strip aren't soldered

That would be a good place to start. Un-soldered connections do not make reliable electrical contact and are a common cause of non-working neopixels.

adafruit_support_bill
 
Posts: 84381
Joined: Sat Feb 07, 2009 10:11 am

Re: Does this schematic work?

by djanim8 on Thu May 19, 2022 9:06 pm

Ahh OK about the switch, I didn't know that from the instructions I got.

As for the LED strip, I didn't solder them this time because this didn't work before and I thought the LED strip was bad. I tested them on an arduino uno board too and couldn't get them to light, so I ordered another strip. This one I didn't want to cut up until I knew they worked.

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by djanim8 on Thu May 19, 2022 9:27 pm

OK, I cut the connection for the switch and that works. I soldered the wires to the LED strip and they still don't light up. I checked to make sure they are getting voltage, and yes, they are still getting 3.7v to the power and 0.003 to the input from #4 (not sure how much that should be, but it's not 0). Tried to take a photo of the whole circuit. The LED on the M0 board lights up. The red LED on the backpack board is lit but dim. LEDs shut off when I flip the switch.

20220519_211023.jpg
20220519_211023.jpg (151.92 KiB) Viewed 99 times

20220519_211149.jpg
20220519_211149.jpg (417.9 KiB) Viewed 99 times

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by djanim8 on Thu May 19, 2022 9:44 pm

Could it be something with the code? I can read and understand what's there, but I've never written python before. Is there some test code I could try out maybe?

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by adafruit_support_bill on Fri May 20, 2022 5:39 am

Python is not my language either, but what you have there looks pretty straightforward.

You can try the example code from the guide: https://learn.adafruit.com/adafruit-neo ... 3005651-22

adafruit_support_bill
 
Posts: 84381
Joined: Sat Feb 07, 2009 10:11 am

Re: Does this schematic work?

by djanim8 on Fri May 20, 2022 8:37 am

Nope, that's not working either.

I even tried swapping out the Trinket M0 board and doing straight wires from that to the LED strip, just to make sure the connector I was using wasn't the issue. And I'm still getting no LED lights.

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by djanim8 on Fri May 20, 2022 8:43 am

the code just goes into the code.py file and is copied to the root of the board right? it doesn't have to be compiled or anything?

djanim8
 
Posts: 17
Joined: Sat May 14, 2022 8:17 am

Re: Does this schematic work?

by adafruit_support_bill on Fri May 20, 2022 8:53 am

You shouldn't need to compile the Python script. If you want to try the Arduino version, the 'strandtest' example sketch is my 'goto' test code for neopixels.

adafruit_support_bill
 
Posts: 84381
Joined: Sat Feb 07, 2009 10:11 am

Please be positive and constructive with your questions and comments.