Simulator: how to config the sensor and vehicle

Created on 17 Oct 2018  路  10Comments  路  Source: lgsvl/simulator

As the title says, how can I set a different vehicle with different sensors in your simulator? LIke I want to design a car/bus with lidars and cameras at different positions.
Thanks!

Most helpful comment

See following screenshot.

image

  1. open Menu scene (double-click)
  2. select RosRobots game object (single-click)
  3. edit RosRobot properties in inspector - add new entry and drag in your prefab from Project window (where you selected scene)

All 10 comments

@gogojjh do you plan to use it with Apollo ? you can try to modify existing car, look at Prefabs/RobotCandidates/XE_Rigged-apollo.prefab
Note: using multiple high-beam Lidars might affect performance

Yes, based on Apollo. I find a problem with the lidar data, Like the below figure, there exists a distortion of the point cloud when the car is moving. How I fix this problem? Increase the frequency of lidar?
Thanks!
screenshot from 2018-10-18 23-20-15

in general our point cloud is perfectly compensated for the motion of the car, i.e. points are exactly where they are in the real world, and this is what Apollo is doing in a special subnode in the Lidar driver (see "compensated" topic vs raw point cloud).

"sector" distortions you see are happening because points are collected in batches between the frames and these are visible on the high speeds when objects move faster between the frames.
We are trying to improve our Lidar model in future releases to be more "smooth", meanwhile you also can try to play with Lidar parameters like resolution, number of rays of frequency. Disabling other sensors and decreasing resolution (to increase FPS) could also help.

Sorry that I have another question. You mentioned that we can modify the current car/sensor setup in "Prefabs/RobotCandidates/XE_Rigged-apollo.prefab". Here I tried to modify the number of rays and frequency, but it did not change in the simulation. So there are any other steps I should take?
screenshot from 2018-10-19 09-50-31

Thanks!
Sorry again that I have too many problems TAT

You should not modify this file directly in text editor. Instead you should edit the object properties in Unity Editor. To change lidar properties for "XE_Rigged-apollo" car you should do following:

1) Open SanFraccisco scene from project window in Unity Editor.

2) Find XE_Rigged game object in scene window, click on it.

3) In inspector change properties - "Number Of Lasers", "Rotation Speed Hz", etc.. Do not change ApolloTopicName string. This string is set up to same ROS topic name as Apollo expects. Unless you want different topic name.

4) Either press run, to directly run in SF scene. Or press Apply at the top, to save properties back to prefab so you can launch everything from main menu.

I just follow these steps and create a new prefab in the "RobotCandidates" fold. But when I run the simulator again, I still can not load the new robot. What can I do next?
Thanks!

By "can not load" you mean it does not appear in combobox? The combobox in main menu is populated from RosRobot object. Open MainMenu scene, select RosRobots game object, and in inspector extend "Robot Candidates" array.

My problem is this:

  1. I created a robot based on the "XE_Rigged-autoware" like this:
    screenshot from 2018-10-22 15-04-17
  2. I saved this robot model in the "Assets/Prefabs/RobotCandidates" fold
    prefab
  3. I opened the simulator, SanFrancisco scene, the robot I created cannot be loaded (the model "XE_Rigged-jjiao_stareo_lidar" doesn't appear).
    screenshot from 2018-10-22 15-05-40

You mentioned "MainMenu scene" and "RosRobots game object", where can I find them?
Thanks!

See following screenshot.

image

  1. open Menu scene (double-click)
  2. select RosRobots game object (single-click)
  3. edit RosRobot properties in inspector - add new entry and drag in your prefab from Project window (where you selected scene)

It can work, thanks a lot!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bage131 picture bage131  路  5Comments

jonghl9 picture jonghl9  路  4Comments

AlexandrZabolotny picture AlexandrZabolotny  路  4Comments

kmitri-dxc picture kmitri-dxc  路  5Comments

fgrzeszc picture fgrzeszc  路  4Comments