The Pixhawk runs the NuttX real-time operating system which includes the NuttX Shell terminal “NSH”. This allows running some Unix style commands including “top” and “ls”.
NSH is very useful for diagnosing low level issues. Some of the things you can do with it include:
perf
commandThis topic explains how to connect and send NSH commands from MAVProxy via remote and serial connections.
To use the NSH while Copter or Plane is running you can connect using Serial 4/5. To do this you will need anFTDI 3.3V cable and then modify a DF13 6 Position cable so that it can be connected to the FTDI cable.
You should then be able to plug the FTDI cable into your computer and connect with any Serial program including the Mission Planner’s Terminal screen. Ensure to select the FTDI cable’s COM port and set the Baud rate to 57600. You will need to press return for the “nsh>” prompt to appear.
ArduPilot also includes support to run nsh commands remotely via MAVLink over a USB, telemetry or WiFi link (this is an extension of the SERIAL_CONTROL protocol used for controlling a GPS or radio UART over MAVLink).
sudo pip install mavproxy
module load nsh
nsh start
TERRAIN_ENABLE=0
).
You can only start a shell when the system is disarmed. Once the shell is started you can arm if you like.
This also works over a 3DR Radio link, although it is of course slower in output than when on a USB connection.
Questions, issues, and suggestions about this page can be raised on the APM Forum. Issues and suggestions may be posted on the forums or the Github Issue Tracker.