Today’s class will be the last with the Boe-Bot . Last class we made our Boe-Bot navigate with the whiskers on and today we were assigned a project that will mark us for our understanding in this interesting and joy able journey 🙂 :). Mrs.Thompson gave us a list of ideas that and from there onward we can up with an idea of what kind of program we want to write. For example: we can write a program that will make our Boe-Bot perform a dead reckoning around the class, we can do a maze and make our Boe-Bot navigate through it….etc. There were many ideas on the list that were all fun and exciting to do. I couldn’t make up my mind, so I went to YouTube and researched some videos maybe that would give an idea. In the end I chose to create my own maze with the help of the program (Subroutines). That was just the main plan and I am usually known for my exceeding perfection and I might spice things up concerning my program. By perfection, I mean I would make my boe-bot go in a neat and precise pattern. Since the idea was set on …..I started to draw the maze that I wanted my Boe-Bot to navigate through. At first I decided to make a big maze but then I changed my mind and worked on a small instead. The reason behind this huge change in plan was because I have already kept the distance measurements that I would like my Boe-Bot to move and they were big, so that meant building a maze which was more than 5 meters long. After I have designed the maze, I wrote up a program using subroutines based on the distance in the maze and the ones that I would use to make my Boe-Bot move. Writing the program was easy because I used subroutine which is the simplest program, it’s less complicated than EEPROM. Here is what the program looks like:
‘ Robotics with the Boe-Bot – MovementsWithSubroutines.bs2
‘ Make forward, left, right, and backward movements in reusable subroutines.
‘ {$STAMP BS2}
‘ {$PBASIC 2.5}
DEBUG “Program Running!”
counter VAR Word
FREQOUT 4, 2000, 3000 ‘ Signal program start/reset.
GOSUB Forward_a
GOSUB Right
GOSUB Forward_q
GOSUB Left
GOSUB Forward_w
GOSUB Left_s
GOSUB Forward_b
GOSUB Left_s
GOSUB Forward_b
GOSUB Right_b
GOSUB Forward_w
GOSUB Left
GOSUB Forward_w
GOSUB Right
GOSUB Forward_b
GOSUB Right_c
GOSUB Forward_d
GOSUB Forward_e
GOSUB Circle_n
END
Forward_a:
FOR counter = 1 TO 97
PULSOUT 13, 850
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Forward_q:
FOR counter = 1 TO 106
PULSOUT 13, 850
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Forward_w:
FOR counter = 1 TO 111
PULSOUT 13, 850
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Forward_b:
FOR counter = 1 TO 48
PULSOUT 13, 850
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Forward_d:
FOR counter = 1 TO 121
PULSOUT 13, 850
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Forward_e:
FOR counter = 1 TO 73
PULSOUT 13, 850
PULSOUT 12, 850
PAUSE 20
NEXT
PAUSE 200
RETURN
Left:
FOR counter = 1 TO 17
PULSOUT 13, 650
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Left_s:
FOR counter = 1 TO 17
PULSOUT 13, 650
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Left_z:
FOR counter = 1 TO 19
PULSOUT 13, 650
PULSOUT 12, 650
PAUSE 20
NEXT
PAUSE 200
RETURN
Right:
FOR counter = 1 TO 16
PULSOUT 13, 850
PULSOUT 12, 850
PAUSE 20
NEXT
PAUSE 200
RETURN
Right_b:
FOR counter = 1 TO 17
PULSOUT 13, 850
PULSOUT 12, 850
PAUSE 20
NEXT
PAUSE 200
RETURN
Right_c:
FOR counter = 1 TO 18
PULSOUT 13, 850
PULSOUT 12, 850
PAUSE 20
NEXT
PAUSE 200
RETURN
Circle_n:
‘ —–[ Main Routine ]————————————————
Main:
DO
PULSOUT 13, 850 ‘ Veer right
PULSOUT 12, 750
PAUSE 20
LOOP
END
After I have written down the program …..It was time to buildup the maze. After I have finished building up the maze, it is the crunch time to see whether all that hard work and long night staying up was worth it. The Boe-Bot went through the maze just perfectly; the only problem that I faced was the turns. They were not exactly 90 degrees, so I just went back to the problem and applied some of my magic. Later on Mrs.Thompson came in and she was eager to see our progress. I told her that it was ready and set it out in the maze and BAMMM!!!!! It went through it just fine but then there was a left turn where my Boe-Bot would just come in contact with the wall and it would cause it walk on the wall and then turn upside down. I keep asking myself where the problem was because before Mrs. Thompson came it worked fine and then I realized that the position you kept in at the start point of the maze would affect it if it was not straight. I think we tried like 5 times more and then finally I took my time and placed the Boe-Bot in a straight position. I ran the program and then it finally worked. And when it reached the end of the maze it celebrated its victory with a circular dance. I have another theory for what might have caused the boe-bot to hit the wall, because when I first tried it I kept my cell phone with music on, so that it can give a special effect. The time it actually did work, my cell phone wasn’t there and maybe the cell phone has increased some weight on the Boe-bot making it hard for her to turn. Well I was jumping when it went through that maze. It felt I have accomplished something big. This was the first time that I actually on such projects. I have to admit it was frustrating when it didn’t turn exactly 90 degrees and at one point I even cried but my happiness covered up these too unpleasant memories. Our last mission in this wonderful journey was dissembling the Boe-Bot. I felt so bad when I was disassembling it, because I worked so hard to build up. Well that was Mrs. Thompson wish and we just went on with the verdict. It was an experience of a life time. Now I can go and brag in front of people that I built a robot and that I created a program and made my Boe-Bot work based on it. I really enjoyed it and if they asked me to do it again ….I would certainly agree too but that does not mean I would be more patient with it but I try to be more understanding. Anyways that was my “EPIC BOE-BOT JOUNEY” and now its time to say goodbye to my baby boe-bot. (I LOVE YOU) 🙂 🙂 🙂 ❤