Poppy not walking in V-REP

Dear all,

I am trying to make Poppy walk in the VREP simulator.

To do so, I followed the tutorial

I installed the VREP branch of Pypot library.
I launched the poppy generator tool to create a poppy config file (.json).
Note that I don’t have the poppy robot connected to my computer when I did create the config file, the python script created a default config file.

I installed the poppytools using this tutorial

Then I launch the program for making poppy walk :smile:

import json
scene_path = '/Users/sribas/Documents/workspace/vrep poppy file/poppy-standing2.ttt'
from pypot.vrep import from_vrep

poppy_config_file = '/Users/sribas/Documents/workspace/poppy-software/poppytools/configuration/poppy_config.json'

with open(poppy_config_file) as f:
    poppy_config = json.load(f)
    poppy = from_vrep(poppy_config, '127.0.0.1', 19997, scene_path)
    poppy.start_sync()


import os
import poppytools

from poppytools.primitive.walking import WalkingGaitFromMat

cpg_filename = os.path.join(os.path.dirname(poppytools.__file__), 'behavior', 'IROS_Normal_Gait.mat')
#walk = WalkingGaitFromMat(poppy, cpg_filename)
poppy.attach_primitive(WalkingGaitFromMat(poppy, cpg_filename, compliant_motion=True), 'walk')
import time
time.sleep(5)
poppy.walk.start() 

V-REP loads correctly the poppy.ttt file, the poppy robot appears in the simulator but nothing happens.

Poppy doesnot walk !

Is it due to the way I create my poppy config file ?
any other hint?
Cheers!

I’ve tried the code you copy/paste on my machine and the poppy humanoid is walking…

So I can see few possible issues with your setup:

  • Your installation of pypot or v-rep is not up to date or broken (I don’t think this is the case as the scene is correctly loading).
  • You launch the code you show as a script. Thus the program leaves just after sending the start signal so the walk doesn’t have “time” to really start. When closing the communication with v-rep the control is also stopped. An easy way to test this is to add another time.sleep(5) after the poppy.walk.start() line

Let me know if it helps!

It works now that I added the sleep() instructions :smile:
Thanks!

I tested the code for simulation but don’t know why the poppy alway fall down when starting. any recommendation? Thanks

1 Like

Me too. He always fall down when starting. It’s the same code…What can I do?

Actually, Poppy can’t walk and for the walk behaviour you tested, this is what is “expected”. Poppy still need a balance behavior. Walking is a complex behavior with static and dynamic balance.
First, Poppy needs to understand what is falling down ( using an IMU or foot sensor or calculation of the center of gravity which have to stay in the polygon of lift…) and after Poppy needs algorythm to correct the movement… I think before to develop walking behavior it could be easier to test with more simple balance behavior like poppy on one foot for example.
So, if you want to try you are welcome :wink: