🤖

ROS2(windows11) の初手

に公開

ROS2 に手を出してみる。

19時間前に Kilted Kaiju がリリースされていました。

結論から言うと下記に書いてある通りにすればよい。

https://docs.ros.org/en/kilted/Installation/Windows-Install-Binary.html

探索

よくわからんが ros2 run demo_nodes_cpp talker が動くところまでやろう。

c:/ros2-windows に展開して local_setup.ps1 して ros2 run demo_nodes_cpp talker
すると

failed to create process

によると python のシェバングがよろしくない?

たしかに #!C:\pixi_ws\.pixi\envs\default\python.exe というパスになっている。
試行錯誤したところ最新版は pixi なるツールで python を導入しているぽいことがわかってくる。

c:/pixi_ws を作って中に ros2-windows を移動する。

pixi init すると python-3.13 になってなんかバージョンがあっていない。

https://docs.ros.org/en/kilted/Installation/Windows-Install-Binary.html

本家のインストールページで pixi の設定をダウンロードしているのを発見。

https://raw.githubusercontent.com/ros2/ros2/refs/heads/kilted/pixi.toml

なるほど。

手順

  • pixi インストール
  • ros2-kilted-20250523-windows-release-amd64.zip ダウンロード C:/pixi_ws/ros2-windows に解凍
  • C:/pixi_ws/pixi.toml from https://raw.githubusercontent.com/ros2/ros2/refs/heads/kilted/pixi.toml
> cd C:/pixi_ws
C:/pixi_ws> pixi shell
C:/pixi_ws> cd ros2-windows
C:/pixi_ws/ros2-windows> ./local_setup.ps1
C:/pixi_ws/ros2-windows> ros2 run demo_nodes_cpp talker
[INFO] [1748091421.214221500] [talker]: Publishing: 'Hello World: 1'

Discussion