Czech-Taiwan-Germany Robotics Workshop 2024

Robotics

  • Mechanics + Electronics + Perception (Sensing) + Control + AI + … = Robotics
  • AI may be used to
    • plan robot actions,
    • prioritize tasks,
    • detect or distinguish data,
    • learn, self-improve,
    • cooperate,
    • react,
    • decide, … etc.
  • A robot consists of
    • actuators (motors, servomotors, valves, optics, …),
    • sensors (accelerometers, cameras, pressure, laser scanners, …),
    • brains (Raspberry PI, Intel NUC, Arduino, …),
    • energy source (batteries, external supply, solar panels, …),
    • body (LEGO, 3D Printing, …).

cras-robots.jpg

  • A robot state description may be abstracted into its position and orientation described by coordinates in a reference frame.
    • We shall use 2D coordinates, i.e., X, Y and the angle measured from positive direction of the X axis.
    • Thus, having a suitable controller, a generalized velocity command may be used to control any robot.
      • Such a command comprises the desired linear and angular velocity.
    • In our case, we have a 6-legged robot with 3 actuators per leg, thus in fact the controller needs to produce 18 control signals based on the two values in the velocity command.
The controller itself may be implemented by various aproaches, e.g., by the Central Pattern Generator (CPG). The controller computes desired joint angles such that the leg is raised, moved forward, lowered and then moved backward. The CPG produces such movements for all 6 legs, synchronizing the phases to keep always three legs on the ground. This makes the 6-legged (or hexapod) robot stable as the center of mass is supported at least by a triangular support polygon.

Simulation

  • The computers in the classroom run Ubuntu OS with all the required software installed.
  • Please, log in via the credentials provided on the paper strip.
  • We shall use the CoppeliaSim app.
    • The simulator can be downloaded and run at home as well.
  • Open a terminal by Actr+Alt+T.
  • Run the simulator by issuing /opt/CoppeliaSim_Edu_V4_3_0_Ubuntu20_04/coppeliaSim.sh command.
  • Download the simulation resource pack: aed23_resource_pack.zip.
    • The resource pack contains robot model, scene and driving scripts in Python.
    • Unzip the resource pack.
    • Load the scene from the resource pack. (FilesOpen scene…~/Downloads/aed23_resource_pack/scenes/aed23.ttt.)
  • Robot is driven by a set of jazyce Python scripts.
    • Open another terminal instance (Ctrl+Alt+T).
    • Run cd ~/Downloads/aed23_resource_pack; ./main.py.
    • Robot should now tread in place.

Blind locomotion

  • We want the robot to navigate towards two waypoints , depicted as green spheres in the simulator.
  • Robot knows its current pose and its current goal waypoint from which it needs to compute the velocity command.
  • Edit the script which controls the robot.
    • /opt/VSCode-linux-x64/code ~/Downloads/aed23_resource_pack/hexapod_robot/HexapodController.py
  • First, delete the return result_command statement on line 28.
  • Robot needs to turn towards the target. Implement the desired heading as
    • desired_heading_radian = math.atan2(dy,dx)

Obstacle avoidance

  • Open the main.py and switch the controller to goto_reactive.
Vehicle 2a Vehicle 2b Vehicle 3a Vehicle 3b
breitenberg_2a.jpg breitenberg_2b.jpg breitenberg_3a.jpg breitenberg_3b.jpg
Spojení excitation excitation inhibition inhibition
Chování fear aggression love explore
Vlastnosti Avoids object. Assaults object. Stops facing the object. Stops facing away.
  • We use the LiDAR as the source of the stimulus.
    • We measure laser beams to the both sides of the robot centerline and use them to virtually repel the robot the closer it gets to an obstacle.

Extra Tasks

courses/crl-courses/ctg24.txt · Last modified: 2024/05/02 17:49 by zoulamar