End of Week 3 12/6/24
Another week down. Time flies, huh? Well, we finished up our first iteration of the “Line Follower.” And just for future reference, when I say “we” I mean “my dad and I.” He is a software engineer turned teacher. Not really, but he’s been the one showing me the ropes. I am getting better at grasping the concepts, using git, and coding in general. He has been a huge help in all of those things. Anyway, the rudementary “line follower” code block was a fun challenge. We had a black line made of electrical tape, and a color sensing robot on treads. We wanted it to follow the line as accurately as possible. It was a fun combo of software “engineering” as my dad calls it (the process of writing concise and well organized code which is easy to read and manipulate) and using critical thinking skills to work around the big elephant in the room: we had one color sensor. As one with basic coding knowledge would surely understand, the presence of multiple color sensors would allow for an easy solution. Something along the lines of, “if they both detect black, bingo! If not, well, rotate until they both detect black!” Not that the real process was much more complex, but yours truly is very new to robotics. Thankfully, I was able to put together some functional code and get it rolling.
Big Takeaways
-When I set to work to try to figure out the problem on my own, I discovered that a “range” function existed. This allows for a variable to be set to multiple numbers in a range, which made the color sensor much easier to use. You see, to set a target light intensity for the sensor to follow, I had to test the light intensity of the tape. The brace holding the sensor being less than perfect, it would be closer and farther away from the tape on a day to day basis. This of course changed the value of the intensity each time I tested it. With the range, I did not have to change the target intensity every time I ran the program. Convienent!
-Software engineering is cool. The process of consolidating code is very satisfying. I defined various functions and set the values of the rotation angle, speed, etc. I would do this for each of the motors, which accounted for several unecessary lines of code. My dad showed me that I could simply make one function with rotation angle, speed, etc. passed as variables inside it. This would contain instructions to run the motors that could be called in the functions for left motor and right motor. Simply changing the values for speed, rotation angle, etc. gives you a concise way of doing the same thing. I just did a very poor job of explaining this process, but these descriptions are usually from memory and all part of the learning process for me. Dad and I usually go over my mistakes later on. Who knows, you may even get my edited version and think me a prodigy!
The Week
I don’t have a quote, but there is something to discuss. The Wall. The invisible barrier which separates us from our deepest vulnerabilities. Not to get too personal on this blog about robots, but it is very relevant in my life. Anything and everything which may have affected me negatively in my past, no matter the degree, added support to this barrier. It built up significantly overtime. When I felt like falling, I knew the solid surface would give me something to lean on. I fell into a lapse, a pattern. It is a dangerous, unfulfilling comfort. Instead of looking my shortcomings and potential in the eye and facing up to them, I pretending I couldn’t see them through the thick wall. The trick is, the wall is transparent. I’ve always known that, too. Now, I am not going to preach about how to take the sledgehammer and break it down, because if I knew how to do that I wouldn’t bother to write any of this. But I think it is something to be aware of. Something to sand down. Now how does this relate to tech? I don’t know, specifically. I would assume, though, that many of us avoid reaching our full potential because it lies just beyond the Wall.