Mobile-SDK-iOS icon indicating copy to clipboard operation
Mobile-SDK-iOS copied to clipboard

M300 RTK not receiving video(swift)

Open ynaka01-max opened this issue 5 years ago • 11 comments

I tried swift sample code(https://github.com/dji-sdk/Mobile-SDK-iOS). However, M300 RTK has not receive video feed, but matrice 210 v2, mavic2zoom and phantom4 received video feed. Why? I read https://github.com/dji-sdk/Mobile-SDK-Android/issues/621 . However, I could not understand how to change or where to change the code. Please teach me specifically where to insert and what to insert?

I inserted code

airLync?.ocuSyncLink?.assignSource(toPrimaryChannel: DJIVideoFeedPhysicalSource.fpvCamera, secondaryChannel: DJIVideoFeedPhysicalSource.fpvCamera, withCompletion: { (error) in
if (error != nil) {
DispatchQueue.main.async {
self.printMessage(text: "airLync Failed: \(error.debugDescription)")
}
}
})

before DJIVideoPreviewer.instance()?.start()

However, nothing happens. Please teach me how to get video feed from M300 RTK.

ynaka01-max avatar Dec 15 '20 04:12 ynaka01-max

We have the same issue.

nab0y4enko avatar Dec 15 '20 17:12 nab0y4enko

Agent comment from Luce Luo in Zendesk ticket #42095:

Dear Customer,

Thank you for contacting DJI. I have attached a sample code, please replace it with the official sample and test it again. https://github.com/dji-sdk/Mobile-SDK-iOS/tree/master/Sample%20Code/SwiftSampleCode/DJISDKSwiftDemo/Camera/fpv

Thanks,

Luce Luo DJI Developer Support
CameraFPVViewController.swift

dji-dev avatar Dec 16 '20 03:12 dji-dev

Hi, I just solved this issue. Please compare and replace with my code in viewDidLoad() P/S: Please also add DecodeImageCalibrateLogic.swift in your project if you don't run on DJISample. M300_FPV

Matheus193dn avatar Dec 16 '20 04:12 Matheus193dn

Thank you. I will try.

ynaka01-max avatar Dec 21 '20 17:12 ynaka01-max

@dji-dev Hey! I'm having this same issue. I being trying to make FPV feed to work on the M300 with no luck. Also tried with the sample project by adapting it to use OcuSync. The assignSource(toPrimaryChannel:secondaryChannel:withCompletion) always completes with the same error: “There was an error executing the command.(code:-1008)“. Do you know why this could be happening? Is there another way to solve this? I need to solve it as soon as possible. Thank you!

federiconicoli avatar Mar 19 '21 14:03 federiconicoli

@federiconicoli hey, did you attached any camera? (such as H20 series or XT series)

Matheus193dn avatar Mar 19 '21 14:03 Matheus193dn

Hi @Matheus193dn, I didn't attach a camera. That might be a problem?

federiconicoli avatar Mar 19 '21 15:03 federiconicoli

@federiconicoli yup, plz attach a camera. I didn't try this case yet.

Matheus193dn avatar Mar 19 '21 15:03 Matheus193dn

It should work without a camera attached, right? I'll try to get a camera asap and I'll let you know. Thank you!

federiconicoli avatar Mar 19 '21 16:03 federiconicoli

It works with a camera attached!

federiconicoli avatar Apr 26 '21 23:04 federiconicoli

Did anyone figure out how to get the fpv feed from the M300 RTK to work when there is no camera connected?

brien-crean avatar Jul 07 '21 23:07 brien-crean