Pixhawk 4 Mini (FMUv5) not receiving encoded Mavlink message to perform off-board control

Hello All,

I have been using Mavlink to communicate with px4 mini (1.9v firmware) to send motion capture coordinates to perform indoor operation without GPS using offboard and positional hold flight modes. My architecture has an onboard rspi-3 connected to pixhawk via usb(rspi-3) <-> (to) micro usb(debug port on px4) mounted onto /tty/ACM0 serial port. I am encoding Mocap data from raspi-3 by using att_pos_mocap_encode Mavlink API and sending it out via send_mavlink interface. The vehicle gets armed and then I set target via set_position_target_local_ned_encode and switch to offboard or positional hold it does not takeoff to desired set point. The mocap data is fed at 60 HZ frequency.

Not sure if the Pixhawk is receiving encoded messages via Mavlink? but if it was an issue with Mavlink I believe it would have not allowed me arm via through the script using mavproxy. So ruling that out I also checked through Mavlink Inspector to see if local_NED value read the mocap but it does not. And also got the Ulog data parsed to check if att_mocap .csv file is creates but that is too not created.

I have followed all the setup specified at https://dev.px4.io/en/ros/external_position_estimation.html but no helped yet. Please if any one has any suggestion do let us know. I would really appreciate your quick help/response here.

pixhawk parameter configured:
MAV_0_CONFIG,101
MAV_0_FORWARD,1
MAV_0_MODE,0
MAV_0_RATE,1200
MAV_1_CONFIG,104
MAV_1_FORWARD,1
MAV_1_MODE,2
MAV_1_RATE,921600
MAV_2_CONFIG,0
EKF2_AID_MASK,24
SER_TEL1_BAUD,57600
SER_TEL4_BAUD,921600
EKF2_HGT_MODE,3

MAV_0_Config is connected to telemetry, so using mav_1_config parameter to communicate over rspi-3 to Pixhawk. Please do correct me if any of the above procedure are incorrect.

below API used to encode mocap data and set position via Mavlink:
vehicle.message_factory.att_pos_mocap_encode
_vehicle.message_factory.set_position_target_local_ned_encode

I’m doubting if the Pixhawk read the sent Mavlink encoded message? Is there any ways to check, apart from above mentioned method please do let us know.

Thanks,
scalnoor.