Jump to content
Ultimaker Community of 3D Printing Experts
callum-burns

Neopixels

Recommended Posts

I am looking at adding neopixels to my ultimaker. They will be used for status LEDS, general ooh ah kind of things and work lighting. I am trying to get how to go about adding this kind of thing to Marlin! IMO is just a mess of code and cant get my head about how it all works!

 

Share this post


Link to post
Share on other sites

I'm not sure what pins are available, but there are a couple of considerations:

1. the Neopixel libraries use assembly, and disable interrupts. It would probably be ok if nothing else is going on, but could cause problems during printing.

2. an alternative would be to use a separate processor (teensy, arduino micro, etc.) to drive it.

 

Share this post


Link to post
Share on other sites

2. an alternative would be to use a separate processor (teensy, arduino micro, etc.) to drive it.

 

I would do this. Updating these kinds of LEDs costs significant amount of CPU power from the Arduino, which will block the printing process.

 

Share this post


Link to post
Share on other sites

I've added Neopixels to Marlin successfully.The interrupt blocking is a concern. I updated only 4 of them and no more than 4x / second. It's possible there were timing hiccups but I didn't notice any print quality issues.

An alternative is the BlinkM modules (which I've also integrated into Marlin). A single super-bright RGB LED with an I2C interface. It's a "smart" LED in that it will blink, fade, etc. on it's own....you can download scripts for it. Which makes it easy to have it flash color sequences or pulse without having the AVR update it constantly.

 

Share this post


Link to post
Share on other sites

As others have pointed out, this would probably interfere with the interrupts. How I would do it would be to set up a Trinket to run the neopixels, and also set up the Trinket as an I2C slave device, come up with an ad hoc protocol, and send commands over I2C.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

[[Template core/front/global/_customFooter does not exist. This theme may be out of date. Run the support tool in the AdminCP to restore the default theme.]]
×

Important Information

Welcome to the Ultimaker Community of 3D printing experts. Visit the following links to read more about our Terms of Use or our Privacy Policy. Thank you!