Open uzgit opened 9 months ago
Agent comment from Leon in Zendesk ticket #101636:
Dear Developer,
Hello, thank you for contacting DJI.
This is supported by M350. May I ask if you are using a BULK link? Currently only BULK links are supported to obtain this image.
Thank you for your support of DJI products.
Best Regards,
DJI Dajiang innovation SDK technical support
°°°
I am using a network link, so I suppose that explains why it does not work. I will try to set up a USB bulk device instead. Is the Liveview of payload video feeds available over the USB bulk device as well?
Agent comment from Leon in Zendesk ticket #101636:
Dear Developer,
Hello, thank you for contacting DJI.
The acquisition of payload video source is supported whether it is a NETWORK link or a BULK link.
Thank you for your support of DJI products.
Best Regards,
DJI Dajiang innovation SDK technical support
°°°
So I have set up the BULK link now, and I am able to run the Liveview sample successfully. However, when I try to run the stereo image sample, I get the following error:
[23.398][linker]-[Warn]-[DjiCommand_SendAsyncHandle:894) Command async send retry: index = 0, retryTimes = 3, cmdSet = 36, cmdId = 50
[23.699][linker]-[Warn]-[DjiCommand_SendAsyncHandle:894) Command async send retry: index = 0, retryTimes = 2, cmdSet = 36, cmdId = 50
[24.000][linker]-[Warn]-[DjiCommand_SendAsyncHandle:894) Command async send retry: index = 0, retryTimes = 1, cmdSet = 36, cmdId = 50
[24.301][linker]-[Error]-[DjiCommand_SendAsyncHandle:906) Command async send error 0
[24.301][linker]-[Error]-[DjiCommand_SendSync:489) sendSync callback timeout
[24.301][perception]-[Error]-[DjiPerception_TriggerStereoCamParamsPushing:766) Trigger perception parameters pushing error.
[24.301][perception]-[Error]-[DjiPerception_GetStereoCameraParameters:406) Trigger stereo camera parameters push failed, error code: 353968.
[24.301][user]-[Error]-[DjiUser_RunStereoVisionViewSample:131) Get camera parameters failed, return code:0x000000E1
Could you please let me know anything about this error?
Also, what is the necessary BULK configuration? In hal_usb_bulk.h
it is implied that there have to be two separate BULK connections, but I currently only have one, based on the script described at the following link: here. If I try to create multiple bulk link then the startup_bulk
executable fails. It is the script for the Matrice 30 so that may be why. Please provide a script for the Matrice 300/350 if you have it.
I have now made two bulk devices using the following code snippet:
mkdir -p /dev/usb-ffs
echo "Starting bulk1..."
cfg_str="${cfg_str}+BULK1"
func=functions/ffs.bulk1
mkdir -p "${func}"
mkdir -p /dev/usb-ffs/bulk1
ln -sf "${func}" configs/c.1/
mount -o mode=0777 -o uid=2000 -o gid=2000 -t functionfs bulk1 /dev/usb-ffs/bulk1
/home/joshua/setup/startup_bulk/startup_bulk /dev/usb-ffs/bulk1 &
sleep 3
echo "Started bulk1..."
mkdir -p "${cfg}/strings/0x409"
echo "${cfg_str:1} " > "${cfg}/strings/0x409/configuration"
echo "Starting bulk2..."
cfg_str="${cfg_str}+BULK2"
func=functions/ffs.bulk2
mkdir -p "${func}"
mkdir -p /dev/usb-ffs/bulk2
ln -sf "${func}" configs/c.1/
mount -o mode=0777 -o uid=2000 -o gid=2000 -t functionfs bulk2 /dev/usb-ffs/bulk2
/home/joshua/setup/startup_bulk/startup_bulk /dev/usb-ffs/bulk2 &
sleep 3
echo "Started bulk2..."
mkdir -p "${cfg}/strings/0x409"
echo "${cfg_str:1} " > "${cfg}/strings/0x409/configuration"
So this gives /dev/usb-ffs/ ├── bulk1 │ ├── ep0 │ ├── ep1 │ └── ep2 └── bulk2 ├── ep0 ├── ep1 └── ep2
The Liveview sample still works, but the stereo view sample gives the same error as before.
Agent comment from Leon in Zendesk ticket #101636:
Dear Developer,
Hello, thank you for contacting DJI.
Are you referring to the fact that this error is still reported?
[23.398][linker]-[Warn]-[DjiCommand_SendAsyncHandle:894) Command async send retry: index = 0, retryTimes = 3, cmdSet = 36, cmdId = 50 [23.699][linker]-[Warn]-[DjiCommand_SendAsyncHandle:894) Command async send retry: index = 0, retryTimes = 2, cmdSet = 36, cmdId = 50 [24.000][linker]-[Warn]-[DjiCommand_SendAsyncHandle:894) Command async send retry: index = 0, retryTimes = 1, cmdSet = 36, cmdId = 50 [24.301][linker]-[Error]-[DjiCommand_SendAsyncHandle:906) Command async send error 0 [24.301][linker]-[Error]-[DjiCommand_SendSync:489) sendSync callback timeout [24.301][perception]-[Error]-[DjiPerception_TriggerStereoCamParamsPushing:766) Trigger perception parameters pushing error. [24.301][perception]-[Error]-[DjiPerception_GetStereoCameraParameters:406) Trigger stereo camera parameters push failed, error code: 353968. [24.301][user]-[Error]-[DjiUser_RunStereoVisionViewSample:131) Get camera parameters failed, return code:0x000000E1
This error indicates that there is still a problem with the data transmission and reception of your BULK link. You can test your BULK link according to the test procedure at the end of this article to ensure that the data is passed. https://sdk-forum.dji.net/hc/zh-cn/articles/10232604141465-%E6%A0%91%E8%8E%93%E6%B4%BE4B%E9%85%8D%E7%BD%AEUSB-device-RNDIS-%E5%92%8C-BULK
Thank you for your support of DJI products.
Best Regards,
DJI Dajiang innovation SDK technical support
°°°
I made this installation script for setting up the PSDK with the Raspberry Pi 5 with the Matrice 350 via the E-port with USB bulk, and I am able to see the liveview and stereo images now. Hopefully it can help someone.
Agent comment from Leon in Zendesk ticket #101636:
Dear uzgit,
Greetings. We appreciate your contact with DJI - Da-Jiang Innovations.
Thank you for sharing. We will recommend it to all developers applicable to this platform. We believe that your script can help many developers shorten the development time of PSDK and save them the time needed to set up the environment.
Thank you for your support of DJI products! Wishing you all the best!
Best Regards,
DJI - Da-Jiang Innovations SDK Technical Supportq
°°°
Hello, I am trying to access the stereo images on my PSDK device over the E-port on my Matrice 350 RTK. However, the stereo vision sample does not work. The liveview sample works fine. See below.
Is is possible to view the stereo images on this setup? If not, is it possible to view them over the PSDK port?