Changes between Version 75 and Version 76 of UserGuideGit


Ignore:
Timestamp:
Nov 22, 2017, 11:19:15 AM (8 years ago)
Author:
fma
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • UserGuideGit

    v75 v76  
    167167[[Image(design_remote-control.png, 300px)]]
    168168
    169 As you can see on the UML diagram, a {{{RemoteControl}}} object is build with {{{Components}}}; a {{{Component}}} can be a {{{Button}}}, a {{{Analog}}} axis, or a {{{Joystick}}}, which is several {{{Analog}}} axes bound together.
     169As you can see on the UML diagram, a {{{RemoteControl}}} object is build with {{{Components}}}; a {{{Component}}} can be a {{{Button}}}, a {{{Switch}}} an {{{Analog}}} axis, or a {{{Joystick}}}, which is several {{{Analog}}} axes bound together.
    170170
    171171=== Using Mappers ===
     
    175175For example, to control the robot walk, we can create a '''Joystick''' component with 3 axes: X, Y, RZ.
    176176
    177 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]].
     177But 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]].
    178178
    179179See [[https://framagit.org/fma38/Py4bot/blob/master/py4bot/inputs/mappers/mapper.py|py4bot/inputs/mappers/mapper.py]] to see how this mapper is defined.