| | 178 | For example, to control the robot walk, we can create a '''Joystick''' component with 3 axes: X, Y, RZ. |
| | 179 | |
| | 180 | But the '''!GaitSequencer''' '''walk()''' method expects '''speed''', '''direction''', '''length''' and '''angle''' params. Using the '''!MapperWalk''' mapper, you can compute all these params from X/Y/RZ axes, and send them to the '''walk()''' method. That's what we did in the [[Tutorials|tutorials]]. |
| | 181 | |
| | 182 | See [source:/py4bot/inputs/mappers/mapper.py] to see how this mapper is defined. |
| | 183 | |
| | 184 | Of course, you can define your own '''Mappers'''. |