|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#6
|
|||
|
|||
|
Re: Help with Andymark LED strip
Sorry for the very late response but here is the code i am using:
#include "FastLED.h" #define NUM_LEDS 5 #define DATA_PIN 6 #define CLOCK_PIN 13 CRGB leds[NUM_LEDS]; void setup() { FastLED.addLeds<WS2801, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS); } void loop() { // First slide the led in one direction for(int i = 0; i < NUM_LEDS; i++) { // Set the i'th led to red leds[i] = CRGB::Red; // Show the leds FastLED.show(); // now that we've shown the leds, reset the i'th led to black leds[i] = CRGB::Black; // Wait a little bit before we loop around and do it again delay(30); } // Now go in the other direction. for(int i = NUM_LEDS-1; i >= 0; i--) { // Set the i'th led to red leds[i] = CRGB::Red; // Show the leds FastLED.show(); // now that we've shown the leds, reset the i'th led to black leds[i] = CRGB::Black; // Wait a little bit before we loop around and do it again delay(30); } } We are using the andymark micro-controller and have arduino Ethernet selected on the program. The five files attached are photos of our setup disconnected from the robot. Just imagine the wago connector piece is connected to the robot. The black block has all of the negative connections on it having them go back through the wago to the robot, the equivalent of the terminal block in the original schematic. The blue clock wire is connected to the 13th pin and the green data wire is connected to 6. The led strip was shortened to 5 leds to see if length was a problem (it didn't help ). The dc-dc converter is has the red + wire connected to the wago and in turn the robot, both black - wires are connected to the block, and the yellow + wire is going to the strip whose black - wire is connected to the block as well. All wires are connected to pins, wago connectors, or wrapped in a wire nut and electrical tape. We have tested with another arduino and have recieved the same results. The full model number of the chip is WS280ISOXW140110. We have also sent an email to AndyMark for help but they have not responded. |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|