This week I worked on the code for this project and created the graphics for the top of the object. I am also planning the object's design, as I have decided to 3D print it.
I think I have settled on the size and style of the object, which is a simple circular container with a lid. What I am still stuck on for the object is how to incorporate a button. I kind of want to have an oversized spring-loaded button, but I'm not sure how to incorporate that into the object. It could either be in the centre of the object, or it could be below the neopixels on the lid.
Sketches for box size and style:
The code for the light circling the object is working. I now need to figure out to get it working with a button. Based on what I have been reading it might be best for the button to change the 'state' of the neopixel, but I don't totally understand how to incorporate that with my current code. The reason I need the state to change is I want the colour of the circling light to change to match the stages of the graphic (see above). What complicates this is I also need the button to pause the light where it is first, then change states on a second push.
Here is a video of the light 'circling' the neopixel:
Here is the code I have right now, I have figured out that the for statement I was trying to make for the button isn't going to work. I was looking at this example from adafruit for a way to potentially do what I need to do.
Comments
Post a Comment