Wow, already the last week! These past 10 weeks really flew by and our group accomplished a lot. In my last week I worked a bit more on the simulation for the demo. I created an end point and made the sim throw a notification when that goal was reached. I also tried to work on making the sim throw an error if the robot bumps into an obstacle and then resets the robot to its begin point. This is still a work in progress and I really hope I’ll be able to finish it by the end of the week.
For the demo we were creating we originally only had one map. But since we got more map files we decided to incorporate those in the simulator as well. In order to use all the different maps I had to generalize the map-drawing function in the frontend. Because we only had one map at first, there were some hard coded elements in the code which had to be generalized. This did not take too long and since I had to wait on the backend code to check my line-drawing function I decided to make another function for the simulator, a reset button. I created a button in the frontend which, if clicked, put the robot back in its begin position. This reset function can also later be used if the robot bumps into an obstacle for example. We were running into some issues while creating the backend code for the reset button, so the reset function for the simulator is still a work in progress.
This Wednesday we had another education meeting. The day before I worked on making a draft for the curriculum of the ROB102 course by looking at other similar intro courses. I also made a list of computational objectives that the students will need to cover in order to be able to start coding and learning about algorithms. In the education meeting we also discussed the need to make both courses as inclusive as possible. POC and women in STEM are often times scared away more easily than (white) men. The course needs to be inclusive to all those people, including all students who have never coded before in their life. We need to make sure that these students get engaged in the course and not scared away, because if students get scared and afraid they won’t be able to successfully complete the course they are not likely to pursue a major in the field.
On Wednesday we had another education meeting. We established that two courses would be created, ROB102 and ROB103. ROB102 will focus more on pathfinding and learning the principles of coding and 103 will be more hardware oriented. The plan is that these courses will be taken at the same time so that the concepts will complement each other and they can work on assignments with concepts learned in the other course.
Now that we had web sockets set up for both the map and the robot it was time to combine the two so that we could have the robot actually move around in the map. We used two separate web sockets for this which we had running at the same time. To make this work in the frontend I had to create a function which would distinguish what message was sent from the backend, either a map or a velocity command, and execute that command. I created two socket.onmessage methods which both called a handleMessage function. That handleMessage function then distinguished what message was sent trough the WebSocket with an if-statement and the right commands were executed. I also worked on a software diagram which showed how the backend and frontend were interacting together. We will be making changes and additions to this diagram as we continue adding more functions to the robot. We are also discussing using LCM instead of multiple websockets, since that would make it easier to combine multiple functions in the same simulation.
Last week we got our robot moving around on the canvas using a websocket. The next step in creating our simulator was to make a colored map for the robot to move around in. The backend will send a map file through the websocket and I will display that map using frontend code. The map code was essentially an array of arrays that we had to loop through and make visible using color. Visualizing the map took a lot of researching the different components needed to draw the map. I needed all the information of the map file (the amount of cells, the height and width of each cell and how much meters each cell was) and I had to convert all of that to pixels to fit the canvas I created in the frontend. Once I had everything converted it was time to color the map to show the obstacles that were in the map file. I used the probability of the numbers in the map to give them a color ranging from white to blue. Blue meaning there was almost certainly an obstacle in that place and white meaning there was almost certainly no obstacle in that cell. After everything was fine-tuned and the code was debugged with the help of some of my peers the map was up and running!
In the fourth week of my research our group met with Professor Mark Guzdial again to talk about the pedagogy begind computer science classes. This meeting was very inshightful and told us a lot about things we never even concidered about teaching a class to first years. We mainly discussed what it was exactly that we wanted to teach the students and what the ultimate goal of the course would be. We thought about the different objectives for the ocurse. One of the biggest (and possibly end goal) of the course would be for students to understand and implement the A-Star algorithm. We also talked about ways to keep the students interested in the course and we talked about the importance of engaging activities and projects to keep the first years learning new things while also emjoying the class and having hands-on interaction with robots. During the Meeting Professor Guzdial also had some questions about my code diary. He wanted me to clarify certain points I wrote down in order for him to better understand exactly what the difficulties were so that we can later on fix or alter those things for the first years.
The Third week of research constisted of finishing up the A-Star Algorith, writing a code diary, and getting myself familiar with an HTML canvas. Since our research project is about creating a course for first year students, we met with Professor Mark Guzdial who talked to us about the pedagogy behind computer science and what things we should keep in mind when creating the course. Professor Guzdial joined our weekly meeting and gave us some handy tips and pointed out things to start thinking about when coming up with a structure for the class. Professor Guzdial thought it would be a good idea to keep a diary on the code we were writing for the minheap and A-Star algorithms. We had to write down all the problems we ran into while writing the code because the first years would most likely also run into those same issues. I looked back on my notes about the minheap code and the beginning of the A-star code to see what issues I had and wrote those down. I also kept updating my diary while working on my A-Star algorithm.
During the second week of my research internship I did more research on different algorithms. I watched videos and looked on several websites for more clarification. After my research I started on my first task: implementing a heap sort algorithm in a stencil provided by Professor Jenkins. The code I had to write had to sort randomly generated numbers from smallest to largest number. I started by looking up websites which showed and explained code where they implemented minheaps. By looking at the code they used I got an idea of what I had to do to get started. There was one website in particular which explained the minheap sort very well and I was able to use parts of that code with the right alterations. Some of the math parts I had to implement for the minheap took some time to fully understand. The minheap had two main functions: the minheap_insert and the minheap_extract function. The insert function was pretty straightforward except from the math part, but the extract part turned out to be a bit more of a challenge. For the extract function I had to add code add code to make the function extract the right to have the lowest number extracted first. This involved math and the math I found in the code online was hard to understand at first. After I familiarized myself with the math I had to shuffle some code around and after that my sort algorithm worked! It was very exciting to see something you coded actually work and do what you want it to do.
During my first week of doing research we mainly talked about what this summer would entail and what exactly we would be doing. The project would be divided into two teams; the platform team and the pathfinding team. Everyone gave their preferences and told the group what previous engineering and/or coding experience they had. I mainly have experience with software and I was very interested in how to teach incoming robotics students this matter. Especially since I worked as a Teaching Assistant for Computer Science 1 my junior year I was excited to share my ideas on how to best teach first year students new concepts. The next meeting we were assinged our teams and I was assigned to the path finding team. I would be working on the algorithms and code for the robot and look into ways on how to properly transfer this knowledge to the first year students. In order to prepair for my role I had to do some research on path planning and graph-search algorithms. I looked at a lecture Professor Jenkins sent, and did research on different planning and graph-search algorithms such as Depth-First Search, Breadth-First Search, Dijkstra’s Algorithm and the A-Star Algorithm. I also refreshed my knowledge on binary search. Since A-Star would be an important search algoithm in our research project, I put more time into looking into that algorithm in order to fully understand it.