When I heard the secret ingredient this week, I had a BIG idea! I wanted to take my previous build, add a photoresistor AND a motor to it. I wanted the lights to dance to the music and the motor to turn a Christmas figurine. Of course, the song had to be a Christmas song. I chose to keep Santa Claus is Coming to Town because it reminds me of my mom and Childhood Christmases. I really felt like I was on the right track, but although I learned a lot and have more understanding of the coding than I did last week, I could not get my project to do what I wanted it to do.
I started off with my two-button project from last week, but reduced it to one button and added more lights. In the beginning, I could not figure out how to make the lights dance as I had wanted them to, so I posted to the board for advice.
I didn't quite understand the few responses I got, so I reached out to my friend, Rich. I sent him the code I had and told him what I wanted my project to do - the first step. He was able to give me some notes and I succeeded with my first goal! Woohoo!
I understand more about the setup and the loop. I learned the setup is a collection of the different routines we want the Arduino to run, and the loop is where we tell the Arduino the order of the routines we would like it to run. This is probably a very basic explanation, but it helped me to have this AHA moment. From reading Rich's notes, I realized there was even more flexibility and approaches to writing code than I previously thought. Each coder has their own techniques to help them recall the different components of their commands. I still have a lot to learn, but I'm proud of the dendrites I've built during this course. One of the reasons I continue learning is in an attempt to ward off Alzheimer's since my mom was diagnosed at 59 1/2. I do believe I have learned new things and kept my brain active this week. 😉
I learned some new things even though it didn't work. |
No comments:
Post a Comment