UNIT1 Keywords page 13-14 What is a Robot? A robot is a machine that can do the work of a human. Robots can be automatic, or they can be computer-controlled. Robots are a part of everyday life. Most robots today are used for jobs that repeat the same thing. Activity 2 What can a robot be used for in everyday life? Some robots are used for: fun and entertainment like playing computer games. building things like cars. carrying heavy things from one place to another. They can also be used in the military, in space exploration and for medical applications. Robots can sense things and respond to their senses robot can be programmed to think on its own. In a robot, the sensors are the inputs. For example, a robot can sense light and sound, the way your eyes and ears do. The most important electronic part of the robot is the brain It allows the robot to interact with things around it. It is where all the thinking happens. A robot has three main parts: 1. Sensors (Input) 2. Control System (Brain) 3. Actuator/Output: Sensors (Input): tell the robot about its surroundings. Control System (Brain) :A control system is a device that manages or controls the behavior of other systems. These act as the brain in any robotic system. They come in various shapes, types and sizes.
Actuator/Output: An actuator is the part of the robot that performs a physical action. Here are some examples of different types of effectors:
Edison Robot You will use a set of commands or instructions to teach Edison to understand its input and control its output. (program.) Microcontrollers The microcontroller is the main control unit of any automatic system or device. Edison s microcontroller is shown in the following figure.
Programming Software Robots can be programmed using either a visual programming(edware) or a text-based interface.(edpy). In visual programming, you can o use elements graphically to create programs. o You can also drag and drop program elements, click, use menus, forms, dialogue boxes. o This type of programming helps new users to understand programming easily. Activity 5 +6 Identify what the above program does? The above program is a line tracking program. It starts by tracking a line. Loop Starts If line is found Move Right Forward with speed 2. If line not found Move Left Forward with speed 2. Loop Ends Program Ends Activity 7 How can a robot be a machine? What makes a machine a robot? Machines can precisely repeat predetermined motions. Robots can do that too, but they can do even more. Robots can be programmed (given instructions) to perform many tasks. So, even when the task they have to do changes, we do not have to change the robot. Just by giving the robot different instructions, we can tell it to perform different tasks
End of Unit Assessment List the devices you use each day that plug into electricity. Which ones are important and which ones could you do without? Give your reasons. fans refrigerator computer light Think about the devices you use every day that need batteries for power. Which ones are important to you? o REMOTE CONTROL o TOYS o ALARM CLOCK o Buzzer: alarm systems o Fan: computer cooling system o Motor: robot joints, remote controlled car How many batteries you can fit in Edison? 4 Batteries. The voltage of a battery is written on its side. Find the voltage and size of one of the batteries inside Edison. Write what you see. It is a AAA, 1.5-volt battery If you fill the battery compartment, what is the total voltage, keeping in mind that the batteries are connected in series? 4 x 1.5 volt = 6 volt
What outputs does Edison have? Motors, buzzer, LEDs, In your opinion, what are the advantages and disadvantages of visual and textbased programming languages? The advantages of text-based programming languages: Things can be represented in a small space More complex programs can be made faster The disadvantages of text-based programming languages: They can be hard to learn They can sometimes be hard to understand (if written badly) The advantages of visual programming languages: Easier to learn Easy to see code and control flow The disadvantages of visual programming languages: Restrictive Only really good for scripting and small programs 7. Search for other text-based programming languages. Write some examples below. Java, JavaScript, C++ Edison has many simple machines and mechanisms. Some of them are easy to see, and some are hidden inside the robot. Look at the following pictures of the outside and inside of Edison. List all the simple machines that you can find. 1. Wheels and axles. 2. Screws. 3. The cover of the battery compartment acts as a lever. 4. Gears to increase the motors torque. (grey wheels with teeth inside the robot) UNIT 3: Keywords page 62 Make Decisions Many robots have been developed in recent years such as wall-following, human-following and obstacle-avoiding robots. These robots are extremely important as they are being developed to enter environments that are hazardous to humans; for example, rescuing people from burning buildings or in the case of earthquakes. Also, robots are used in space exploration.
What is Infrared Light? Infrared light is invisible to human eyes. It is a type of radiation which can be detected by an infrared sensor. There are other forms of invisible light, such as radio waves, ultraviolet radiation, X-rays and microwaves. Did you know? Some snakes can see the body heat of their victims. This allows them to catch their prey. Piranha fish live in murky water and use IR to locate their prey. Mosquitoes use infrared to find the blood-rich parts of their prey. Infrared (IR) Sensor An infrared sensor measures infrared (IR) light radiating heat from objects in its field of view. A firefighter uses infrared goggles to find a victim in the thick smoke. Did you know? An infrared (IR) sensor senses its surroundings by emitting and/or detecting infrared radiation. The basic concept of an infrared sensor is that it acts as an obstacle detector. It transmits an infrared signal; the signal bounces off the surface of an object and then returns the signal to the infrared receiver.
The obstacles need to be the same height (3.5 cm/1.5 in), or taller than Edison, for it to see them. Did you know? Edison s obstacle detection system uses the same invisible light that your remote control uses to tell the TV to change the channel. This light is called infrared, or IR, and is invisible to the human eye because it has a longer wavelength. You want Edison to check if there is an obstacle in front of him. If this is true, then you want him to beep. If not, then you do not want him to do anything.
Since Edison has two obstacle sensors, you can choose which sensor you want to use. There are four cases: obstacle ahead obstacle to the left obstacle to the right no obstacle is detected Activity 2 Modify the previous program, so that Edison can detect: obstacle to the left obstacle to the right any obstacle detected
Activity 3 Program your Edison to turn ON both LEDs when an obstacle is detected ahead. If there is no obstacle detected, both LEDs should be OFF. Program your Edison to: turn the right LED ON when there is an obstacle at the right side only. turn the left LED ON when there is an obstacle at the left side only. beep when there is an obstacle in front of the robot. turn OFF both LEDs when no obstacle is detected
Edison will do the following: Drive forward if there is no obstacle. If it detects an obstacle to the right, it should turn left. If it detects an obstacle to the left, it should turn right. In case the obstacle is in front of him, it should go backwards to the right. Did you know? Robot vacuum cleaners use the same IR system as Edison to detect obstacles. The Roomba
End-of-unit Assessment Using the if statement only, program Edison to: Turn the right LED ON when there is an obstacle at the right side. Turn the left LED ON when there is an obstacle at the left side. Beep when there is an obstacle in front of the robot Do you think this is a practical way of checking all the states of the sensors? What is your opinion? This is not a practical way since the compiler will check all the cases. If we are using if-elif-else structure, then if a condition is met, the complier will exit the if without checking the rest of the cases which make our code efficient. Edison has two obstacle sensors. Each sensor may or may not detect an obstacle. How many different possible options do you think there are? Both sensors detect an obstacle. Only the left sensor detects an obstacle. Only the right sensor detects an obstacle. Neither sensor detects an obstacle