【ROS-Stage】Stage機器人仿真實驗(三)

參考資料: Modules

本文大概翻譯了Stage提供的幾種模型的介紹,有些模型只翻譯了簡介,機器人底座、執(zhí)行器和激光傳感器翻譯的比較詳細(xì)。在最后給出了ROS中Stage的消息類型。

執(zhí)行器模型(actuator model)

ULM

執(zhí)行器模型模仿了簡單的執(zhí)行器,可以在單個維度上移位,或者繞Z軸旋轉(zhuǎn)。
(The actuator model simulates a simple actuator, where child objects can be displaced in a single dimension, or rotated about the Z axis.)

API: Stg::ModelActuator

World文件屬性

總結(jié)和默認(rèn)值

  # actuator properties
  type ""
  axis [x y z]

  min_position
  max_position
  max_speed
)

有“線性”和“旋轉(zhuǎn)”兩種類型。
(

  • type "linear" or "rotational"
    the style of actuator. Rotational actuators may only rotate about the z axis (i.e. 'yaw')
  • axis if a linear actuator the axis that the actuator will move along
    )

閃爍燈光模型(Blinkenlight model)

模擬閃爍的燈光。鏈接

Blobfinder model

blobfinder模型模擬了一種色塊尋找視覺設(shè)備,如CMUCAM2或ACTS圖像處理軟件。 它可以跟蹤模擬2D圖像中的顏色區(qū)域,給出顏色“斑點”的位置和大小。 可以一次跟蹤多種顏色; 它們被分成通道,例如 所有紅色對象都被跟蹤為通道1,通道2中的藍(lán)色對象等。與每個通道關(guān)聯(lián)的顏色是可配置的。鏈接

相機模型(Camera model)

相機的模型
鏈接:Camera model

Fiducial detector model

The fiducial model simulates a fiducial-detecting device.
鏈接: Fiducial detector model

fiducial
(
  # fiducial properties
  range_min 0.0
  range_max 8.0
  range_max_id 5.0
  fov 3.14159
  ignore_zloc 0

  # model properties
  size [ 0.1 0.1 0.1 ]
)

抓手模型(Gripper model)

模擬了一個簡單的二指抓手。鏈接: Gripper model

機器人底盤模型(Position model)

UML

模擬機器人底盤,有兩種模式:差速輪式(differential)和全向輪式(omnidirectional)。差速輪式可以前后移動和左右轉(zhuǎn)向,全向輪式可以前后移動、左右移動和轉(zhuǎn)向。

API: Stg::ModelPosition

world文件屬性

position
    (
    # position properties
    drive "diff"

    velocity [ 0.0 0.0 0.0 0.0 ]

    localization "gps"
    localization_origin [ <defaults to model's start pose> ]

    # odometry error model parameters, 
    # only used if localization is set to "odom"
    odom_error [0.03 0.03 0.00 0.05]

    # only used if drive is set to "car"
    wheelbase 1.0

    # [ xmin xmax ymin ymax zmin zmax amin amax ]               
    velocity_bounds [-1 1 -1 1 -1 1 -90 90 ]                    
    acceleration_bounds [-1 1 -1 1 -1 1 -90 90]

    # model properties

    )

注意:從 Stage-1.6.5開始,odom屬性被移除了。(Stage will generate a warning if odom is defined in your worldfile. See localization_origin instead.)

  • acceleration_bounds [ xmin xmax ymin ymax zmin zmax amin amax ]
    加速度取值范圍。x,y,z 的單位是米每秒的平方, a 是角度每秒的平方。

  • drive "diff", "omni" or "car"
    diff 差速輪式(比如Pioneer);omni全向輪式(比如麥克納姆輪底座);car 速度和轉(zhuǎn)向角控制。

  • velocity
    定義模型的初始速度。
    注意:如果模型撞到了障礙物,則速度變成0.

  • localization "gps" or "odom"
    定位方式。
    “gps”定位模型的位置是絕對精準(zhǔn)的。
    “odom”是一個簡單的里程計模型,隨著時間的推移,會產(chǎn)生漂移。里程計模型的參數(shù)在 odom_error 屬性中設(shè)定。

  • localization_origin [x y z theta]
    在參考坐標(biāo)系下設(shè)置定位的坐標(biāo)原點。默認(rèn)值是初始位置,因此機器人報告的它的位置都是相對于初始位置的。(Tip: If localization_origin is set to [0 0 0 0] and localization is "gps", the model will return its true global position. This is unrealistic, but useful if you want to abstract away the details of localization. Be prepared to justify the use of this mode in your research!)

  • odom_error [x y z theta]
    指定定位“odom”時使用的里程計誤差模型的參數(shù)。 每個值x,y,z,theta是最大的積分誤差的比例對于每個軸,如果此處指定的值為E,則在啟動時選擇實際比例,范圍為-E / 2到+ E / 2。 請注意,由于舍入錯誤,將這些值設(shè)置為零并不能為您提供完美的本地化 - 因此您需要選擇本地化“gps”。
    ( parameters for the odometry error model used when specifying localization "odom". Each value is the maximum proportion of error in intergrating x, y, and theta velocities to compute odometric position estimate. For each axis, if the the value specified here is E, the actual proportion is chosen at startup at random in the range -E/2 to +E/2. Note that due to rounding errors, setting these values to zero does NOT give you perfect localization - for that you need to choose localization "gps".)

  • velocity [ x:<float> y:<float> z:<float> heading:<float>
    速度范圍 。x,y,z 的單位是米每秒, a 是度每秒。(wheelbase <float,meters> The wheelbase used for the car steering model. Only used if drive is set to "car". Defaults to 1.0m)

激光傳感器模型(Ranger model)

UML

模型模擬一系列聲納或紅外(IR)范圍傳感器。

API: Stg::ModelRanger

world文件屬性

   ranger
   (
   # ranger-specific properties

   sensor (
   pose [ x y z a ]
   size [  x y z ]
   fov a
   range [min max]
   )

   # generic model properties with non-default values
   watts 2.0
   color_rgba [ 0 1 0 0.15 ]
   )

Range模型允許單獨配置每個傳感器的位姿、大小和視野參數(shù)(使用spose [index],ssize [index]和sview [index])。 但是,大多數(shù)用戶將使用默認(rèn)的大小和視野(使用ssize和sview),只指定各個傳感器位姿。

  • pose[<transducer index>] [ x:<float> y:<float> theta:<float> ]
    傳感器相對于本體的位姿。
  • ssize [float float]
    [x y]
    單位i是米. Has no effect on the data, but controls how the sensor looks in the Stage window.
  • size[<transducer index>] [float float]
    每個傳感器的 ssize 設(shè)置.
  • sview [float float float]
    [range_min range_max fov]
    徑深范圍最小和最大設(shè)置(單位是米),視野范圍單位是角度。(Currently fov has no effect on the sensor model, other than being shown in the confgiuration graphic for the ranger device.)

Wifi model

鏈接:Wifi model

ROS中Stage的消息類型(轉(zhuǎn))

stage_ros程序包訂閱/發(fā)布話題具體情況

注:上述話題是單個機器人發(fā)布的話題;若存在多個機器人,則按命名空間的方式進(jìn)行區(qū)分,例如robot_0/odom,robot_0/cmd_vel ,robot_0/base_scan,robot_1/odom ,robot_1/cmd_vel ,robot_1/base_scan等等。

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容