Hey guys....
I am working on a Christmas light display project using Arduino, and I'm running into some timing issues that I could really use some help with. My setup involves using an Arduino to control a series of relays connected to the Christmas lights. I've written a basic sketch to turn the lights on and off in a sequence, but the timing is not as accurate as I'd like.
Specifically, the lights sometimes turn on or off a little earlier or later than expected, which disrupts the synchronization with the music. I'm using the delay() function for timing, but I suspect that this might be causing some issues. I've read that using millis() for timing can be more reliable for this kind of application, but I'm not sure how to implement it effectively.
I also check this: https://www.doityourselfchristmas.com/forum/index.php?threads/rgb-leds-now-consumer-grade-hackabllooker But I have not found any solution. Could anyone guide me about this? Has anyone here faced similar issues or have experience with precise timing for light shows? Any advice on how to improve the accuracy of the timing or suggestions for alternative approaches would be greatly appreciated. Additionally, if there are any libraries or examples that could help streamline this process, I'd love to hear about those as well.
Thanks in advance for your help!
I am working on a Christmas light display project using Arduino, and I'm running into some timing issues that I could really use some help with. My setup involves using an Arduino to control a series of relays connected to the Christmas lights. I've written a basic sketch to turn the lights on and off in a sequence, but the timing is not as accurate as I'd like.
Specifically, the lights sometimes turn on or off a little earlier or later than expected, which disrupts the synchronization with the music. I'm using the delay() function for timing, but I suspect that this might be causing some issues. I've read that using millis() for timing can be more reliable for this kind of application, but I'm not sure how to implement it effectively.
I also check this: https://www.doityourselfchristmas.com/forum/index.php?threads/rgb-leds-now-consumer-grade-hackabllooker But I have not found any solution. Could anyone guide me about this? Has anyone here faced similar issues or have experience with precise timing for light shows? Any advice on how to improve the accuracy of the timing or suggestions for alternative approaches would be greatly appreciated. Additionally, if there are any libraries or examples that could help streamline this process, I'd love to hear about those as well.
Thanks in advance for your help!