Me and my team are trying to put LEDs on our robot this year and I can’t seem to get them to work the brain however I can get then to work with an Adriano uno just fine which i know isn’t legal
These are the lights I’m using
BTF-LIGHTING WS2812B RGB 5050SMD Individual Addressable 3.3FT 60(2x30) Pixels/m Flexible Black PCB Full Color LED Pixel Strip Dream Color IP30 Non-Waterproof for Bedroom,DIY Project Only DC5V https://a.co/d/eabutce
That’s how I Hooked up the lights to the Arduino and figured i would try it on the brain but i have tried both with the resister and without and the same result nothing turns on. I have seen that post however I am using the same lights that Sylvie did and that post and he said he had no issues without a buffer inline.
ok, then assuming no connection issue (as far as I can see wire colors are correct)
is V5 updated to vexos 1.1.2 ?
Are you using VEX VSCode extension or PROS ? post the code you are using.
After changing this the lights flashed red after a couple of minutes on the program but only for a split second, I’m going to get a 74AHCT125 and hook them up to that and see if that makes any difference.
ok, I had a buffer inline when I tested this morning.
Also, Leds.update() I don’t think is needed after set_all(), and also try another 3wire port, they all behave slightly differently due to component tolerance.
Hey do you mind checking the wiring on this and possibly showing me how you have your lights hooked up
and this is my code and my team’s expansion mech just for fun https://www.youtube.com/shorts/2yPgugBHDEU
void opcontrol() {
// Create an addrled object
auto addrled = sylib::Addrled(5,5,64);
auto addrledP = sylib::Addrled(2,2,64);
// Set the LED strip to a gradient in HSV color space
// that displays a full range of hues
addrled.gradient(0xFF0000, 0xFF0005, 0, 0, false, true);
addrledP.turn_on();
// Cycle the colors at speed 10
addrled.cycle(*addrled, 10);
// Store the time at the start of the loop
std::uint32_t clock = sylib::millis();
while (true) {
// 10ms delay to allow other tasks to run
sylib::delay_until(&clock, 10);
}
Is something not working here? What’s the problem?
Also reposting your code to be legible
void initialize() {
pros::lcd::initialize();
pros::lcd::set_text(1, “Hello PROS User!”);
pros::lcd::register_btn1_cb(on_center_button);
sylib::initialize();
}
void opcontrol() {
// Create an addrled object
auto addrled = sylib::Addrled(5,5,64);
auto addrledP = sylib::Addrled(2,2,64);
// Set the LED strip to a gradient in HSV color space
// that displays a full range of hues
addrled.gradient(0xFF0000, 0xFF0005, 0, 0, false, true);
addrledP.turn_on();
// Cycle the colors at speed 10
addrled.cycle(*addrled, 10);
// Store the time at the start of the loop
std::uint32_t clock = sylib::millis();
while (true) {
// 10ms delay to allow other tasks to run
sylib::delay_until(&clock, 10);
}
}
You’re defining the lights as being on port E on an ADI expander on smart port 5, and port B on an ADI expander on port 2 respectively.
You seem to have one light plugged into port E on the built-in ADI, and two supplemental power/ground lines (completely unneeded btw) plugged into port A.