(Ignition) Run the track example

asked 2022-03-02 22:40:43 -0600

fonawork gravatar image

updated 2022-03-04 02:24:19 -0600

I'm searching Ignition Gazebo's models which have tracked wheels like a tank, etc. and I could find some example sdf files with classes to enable its track, but it doesn't work in my test.

[class]
https://ignitionrobotics.org/api/gaze...

https://ignitionrobotics.org/api/gaze...

[example1]
conveyor.sdf
cmd : ign topic -t "/model/conveyor/link/base_link/track_cmd_vel" -m ignition.msgs.Double -p "data: 10.0" C:\fakepath\conveyor.sdf

[example2]
tracked_vehicle_simple.sdf
cmd : ign topic -t "/model/simple_tracked/cmd_vel" -m ignition.msgs.Twist -p "linear: {x: 1.0}, angular: {z: 0.0}"
C:\fakepath\tracked_vehicle_simple.sdf

[other cloud model]
https://app.ignitionrobotics.org/Open...

edit retag flag offensive close merge delete

Comments

Hey! This looks fun project!!

So, I have few questions before I start to work with you on this one. I can't seem to be able to read the sdf ( conveyor.sdf and tracked_vehicle_simple.sdf )

Do you mind to give us link to those sdf files?

kakcalu13 gravatar imagekakcalu13 ( 2022-03-03 07:16:21 -0600 )edit

It seems hard to find in github, so I will upload sdf files to my question. If you can not download these sdf files, please let me know, I will upload it to question content itself.

fonawork gravatar imagefonawork ( 2022-03-03 19:43:48 -0600 )edit

For some reason, gazebo answers does not notify me.

I see files now! I will try those files tonight after work.

kakcalu13 gravatar imagekakcalu13 ( 2022-03-04 11:22:46 -0600 )edit

I'm still checking my methods, but not yet mistakes.

fonawork gravatar imagefonawork ( 2022-03-08 03:46:15 -0600 )edit

Hey there! Sorry for the delay!

So, I got confused with your sdf file. You posted the command which is for diff_driver plugin. I checked and there is no diff_sensor, just parts like this:

        <plugin filename="libignition-gazebo-triggered-publisher-system.so"
                name="ignition::gazebo::systems::TriggeredPublisher">
            <input type="ignition.msgs.Int32" topic="/keyboard/keypress">
                <match field="data">69</match>
            </input>
kakcalu13 gravatar imagekakcalu13 ( 2022-03-08 07:40:18 -0600 )edit

Char limit reached anyway

that's for keyboard to control the model. What you want is

<plugin
    filename="libignition-gazebo-diff-drive-system.so"
    name="ignition::gazebo::systems::DiffDrive">
    <left_joint>left_wheel_joint</left_joint>
    <right_joint>right_wheel_joint</right_joint>
    <wheel_separation>1.2</wheel_separation>
    <wheel_radius>0.4</wheel_radius>
    <odom_publish_frequency>1</odom_publish_frequency>
    <topic>cmd_vel</topic>
</plugin>

but you wanted track

kakcalu13 gravatar imagekakcalu13 ( 2022-03-08 07:43:05 -0600 )edit

Ah, garden! I have not try that one out, just fortress or citadel. Sorry! Ill check it out later this week

kakcalu13 gravatar imagekakcalu13 ( 2022-03-08 07:50:07 -0600 )edit

Thank you! I was able to control above three models just adding plugin named 'diff-drive' with command, but my intention is moving wheels with track like a tank.

fonawork gravatar imagefonawork ( 2022-03-09 18:42:42 -0600 )edit

It seems that track model has to use TrackedVehicle or TrackController.

fonawork gravatar imagefonawork ( 2022-03-09 18:44:24 -0600 )edit

Question, did you create those sdf out of air or were you following some example on site?

kakcalu13 gravatar imagekakcalu13 ( 2022-03-10 15:03:48 -0600 )edit