Troubleshooting Running Out of File Descriptor Issues
File descriptor running out warning or error messages (for example,
[load_mon] <pthread> low on FDs! (1 FDs left)) in the PX4
Console might cause undesirable behaviors.
File descriptors are used to open and store uORB message handles, device driver
handles and so on. By default, the number of File descriptors is limited to
12. PX4 runs out of file descriptors when large number of
uORB Read / Write blocks or any other device driver blocks are added.
When PX4 runs out of File descriptors, the serial port opening is also handled using a file descriptor, thus Monitor and Tune simulation (external mode) connection might also fail.
Increase number of File Descriptors by performing these steps.
For the CMake config you are using, go to the corresponding
nuttx config folder. For example, for
fmu-v5 go to
Modify the property
CONFIG_NFILE_DESCRIPTORSto the desired number (for example, 20).
Build the whole PX4 Firmware using
Try building and deploying / running Monitor and Tune Simulation ( external mode) from Simulink.