# MAVLink Shell

The MAVLink Shell is an NSH console that can be accessed via MAVLink over serial (USB/Telemetry) or WiFi (UDP/TCP) links (in particular, on NuttX-based systems like: Pixhawk, Pixracer, etc.).

它可用于启动系统指令与模块,并得到输出信息。 While the shell cannot directly display the output of modules that it does not start, it can do so indirectly using the dmesg command (dmesg -f & can be used to display the output of other modules and tasks running on the work queue).


The QGroundControl MAVLink Console is the easiest way to access the console. If the system does not start properly you should instead use the System Console.

# 启用 Shell

The easiest way to access shell is to use the QGroundControl MAVLink Console (opens new window) (see Analyze View > Mavlink Console).

执行 mavlink_shell.py -h 获取所有可用参数的描述。

  1. Shut down QGroundControl.

  2. 安装依赖项

    pip3 install --user pymavlink pyserial
  3. Open terminal (in PX4-Autopilot directory) and start the shell:

    # 通过串口
    ./Tools/mavlink_shell.py /dev/ttyACM0
    # 通过 WiFi 连接

详情见:PX4 控制台/Shells > 使用控制台/Shells

For information see: PX4 Consoles/Shells > Using Consoles/Shells.