• ACTIVITY DESCRIPTION

    This activity will create a level crossing of a train using the mBot.


    The activity consist of two part:


    1. Communication between robots.

    2. Using servomotor.

    The task is building the model of rail with passage for cars. The train drives the trucks. First robot uses the ultrasonic sensor to detect the train. When the train is in front of the sensor the robot send the massage to second robot. The second robot after it received the message puts the barrier down. After passing the train the barrier goes up.





    Communication between robots


    Robot - transmitter sends the massage using IR. The message is sending after pressing the key on PC keyboard. Later we can change the situation: the message is sending when sensor give us specified value.


    Robot - receiver after received the message moves or turns the light on (set leds on board).




    Servomotor instalation


    Students install servomotor to mBot. They can used the instruction included by producer or make their own project. Student write simple program to check the servo and learn how to control it. It is important to note the number of port, the slot and angle value. The angle value depends of construction of robot. It is the number between 0 and 180.


    Robot transmitter after observing the train give the signal "stop”.


    Robot receiver change the position of barrier and set the led to red colour - it stops the car.


    Robot transmitter should have the leds off, because the light of leds interferes with the signal.


    The barrier is down, when the train is passing.


    The example of mounting the servo with barrier.




    PRESENTATIONACTIVITY RESOURCES