• Need a robot name? Why not Zoidberg?
• Zoidberg is the classiest robot ever. He wears a top hat and has a fancy moustache. He is considering getting a monocle. Zoidberg is known as a rich doctor who attends fancy parties, but he is actually a spy. It's all a disguise. His moustache is not even real!
• Zoidberg is also an artist. He drew circles.
• Zoidberg Sensor Information:
• Nicky-Roberto
• Roberto Sensor Information:
• Winston-Robodexo2000
• Robodexo2000 Sensor Information:
• line sensors: <0,0>
• light sensors: <65158,65156,65089>
• IR sensors: <1,1>
• fluke sensors: <2560,2560,2560>
• battery: 7.14922
• Andrew-Brick
• Brick Sensor Information:
• line sensors: <0,0>
• light sensors: <65022,64912,64873>
• IR sensors: <1,1>
• fluke sensors: <6400,6400,6400>
• battery: 7.48285
• Lab 3
• I wrote the "paranoid" behavior, which makes the robot move forward if there is light, and rotate if dark. If dark, it will continue to rotate until it senses light. Once it finds light, it will continue to move forward.
• Paranoid code:
• Paranoid
• Partners:
• Andrew-Brick Winston-Robodexo2000 David-Furiosity
• Homework 2: Robot Games
• Prelab Quesitons:
• 1.The program first checks if there is enough battery to run (over 6.0). If there is, the robot will begin the user input cycle. There will be two control schemes: both use WASD for movement, E to switch between the two, F to trigger the fight song, and Q to quit. The first control scheme moves the robot a little bit forward with W (unless the robot senses that its front is blocked with the obstacle sensor), turns a little bit left or right with A and D respectively, and turns approximately 180 degrees with S. The second moves the robot continuously forward with W (unless the robot senses that its front is blocked with the obstacle sensor), turns continuously left or right with A and D respectively, and stops all movement with S or when a non-movement command is triggered.
• 2.For this portion, the fluke faces the rear of the robot. The robot checks its line sensors: if both read that the robot is following the line, the robot will move forwards; if one reads that the robot is on the line and the other reads that the robot is off, the robot will turn and move simultaneously in the direction of the one still on the line; if both read that the robot is off the line, the robot will turn and move simultaneously in the direction that it last turned. If the robot reads that it is off the line 7 times consecutively, it will end the program.
• 3.The robot will move forward until it senses an obstacle in front using its obstacle sensors. Then, it will turn right 90 degrees, and check if there is an obstacle. If there is nothing in the way, the robot will move forward again. Otherwise, the robot will turn around (180 degrees) and move forward again. This will continue until a bright light is shined into the middle light sensor (manual stop).
• 4.The robot will draw a stage 3 Sierpinsky Triangle. The program uses a function that has two double parameters. The function makes the robot move forward for a time equal to the first parameter and makes it turn 1 second (60 degrees) in the direction indicated by the second parameter. The main function executes this function multiple times, with varying parameters.
• 5.The program will take in user input to determine which portion of the project will be run. Once one section is finished, the program will automatically return to the input for the next section.
• Robot Games code
• Partners:
• Andrew-Brick Winston-Robodexo2000 David-Furiosity
• Homework 3: USAR
• Prelab Questions:
• 1. Each of our robots will have its own designated quarter of the room to search. The algorithm is prompt user for linear movement and rotation, the robot moves and rotates accordingly, robot uses sensors, and, if anything is sensed, the robot takes a picture and shows it. These steps are repeated as many times as necessary. We use the IR, Obstacle, and Light sensors to navigate.
• 2. The user inputs how much linear distance the robot travels (in feet) and how much it rotates (in degrees). All of the same sensors are used to make sure that there is nothing in the robot's way.
• 3. It will locate the robots with the camera. If it sees one, we will make the robot move toward it.
• 4. Every time the robot moves or turns, it will keep track of how much it has moved and which direction it is facing. Trigonometric calculations will be used to determine the exact position of the robot.
• USAR code
• Partners:
• David-Furiosity Nicky-Roberto Ken-NOS4A2
• Homework 4: Mars Rover
• Prelab Questions:
• 1. The program is supposed to search every pixel and find the pixels at which there is a change from the alien greenish color to anything else and vice versa. These are the pixels that essentially make the outline of the alien. It stores all of the x values of these pixels into one array and all of the y values in another array. It then searches this array for the minimum and maximum x and y coordinates. The location is (minimum x, minimum y), the width is maximum x - minimum x, and the height is maximum y - minimum y. In case there are more aliens, the program searches for vertical lines from maximum x to minimum x that do not contain any alien-colored pixels. If there are any such vertical lines, it finds the least x value of these lines and the greatest x value. It then considers the width of one alien to be the difference between the minimum x value of these lines and the initial minimum x value found. It also isolates this alien and finds its height in a similar way to finding the height initially. Then, it repeats this but ignores the location of the first alien and the empty vertical lines past it up to the next alien. 2. It has the properties height, width, x-coordinate, y-coordinate, and name. 4. Mars2 because it had two aliens. Since my method is recursive, I thought testing with two would be enough. 5. It uses bubble sort. For n number of times, n being the number of aliens, it compares every element to its adjacent element and switches them if they are not in ascending order. 7. It is n.