mavros icon indicating copy to clipboard operation
mavros copied to clipboard

MAVROS FTP read from PX4 1.14.1 always return 0 length data.

Open oldshuren opened this issue 1 year ago • 0 comments

This is only bug and feature tracker, please use it to report bugs or request features.


Issue details

mavros ftp READ always read 0 length

MAVROS version and platform

Mavros: latest ROS: noetic Ubuntu: 20.4

Autopilot type and version

[ ] ArduPilot [ X ] PX4

Version: 1.14.1

Node logs


Diagnostics

In mavros/src/plugins/ftp.cpp send_read_command() it has,
req.header()->size = 0 /* FTPRequest::DATA_MAXSZ */;

But the px4 mavlink_ftp.cpp changed from

int bytes_read = ::read(_session_info.fd, &payload->data[0], kMaxDataLength);

to

int bytes_read = ::read(_session_info.fd, &payload->data[0], payload->size);

So FTP read always return 0 length on px4 1.14.1

Check ID

oldshuren avatar Jan 07 '24 03:01 oldshuren