I am unable to view/share my video to the participant. Using Swift

func startMeeting() {
        
        let service = MobileRTC.shared()?.getMeetingService()
        
        let token = requestTokenOrZAK(with: DDProviderVideoVC.MobileRTCSampleTokenType.token)
        let zak = requestTokenOrZAK(with: DDProviderVideoVC.MobileRTCSampleTokenType.zak)
        
        let param:MobileRTCMeetingStartParam
        service?.delegate = self
      
        let user = MobileRTCMeetingStartParam4WithoutLoginUser()
        user.userType = MobileRTCUserType_Unknown
        user.meetingNumber = self.meetingNumber
        user.userName  = "Sourabh Nag"
        user.userToken = token ?? ""
        user.userID = "drparideshmukh@gmail.com"
        user.isAppShare = true
        user.zak = zak ?? ""
        user.noVideo = false
        param = user
        
        DispatchQueue.main.async {
            let ret = service?.startMeeting(with: param ?? MobileRTCMeetingStartParam())
        }

// print(ret)
}

This is how i start the meeting. Sometimes the below delegate method is called sometimes not.

onMeetingStateChange(_ state: MobileRTCMeetingState)

When it is called, there is no zoom UI shown at host end while when the participant joins the video his UI is shown with his video and not host’s video.

  1. Host cannot see zoom UI but it can hear the voice. Blank screen is showing after “sharing…” screen.
  2. Participant can hear host but cannot see his video

Thanks for using Zoom SDK. Can you provide the following info?

  1. Which version of iOS SDK are you having this issue with?
  2. Are you experiencing this with our iOS SDK demo or your own application? If this is your own app, can you try the same code with our demo app and see if the issue is reproducible?
  3. Are you using Zoom UI or custom UI?
  4. Can you provide the steps to reproduce it?
  5. Are you getting any error messages? Can you provide any logs?

Looking forward to hearing from you. Thanks!

I have no idea how to check which version I am using. I am using zoom in my own app. I have already sent you the code to start the meeting without logging in. I have copied the same code as in your sample code but in different language (Swift). I can send you the MobileRTCMeetingServiceDelegate delegate methods flow in which they are being called.

onMeetingStateChange)
State:1

onJBHWaiting
JBHCmd(rawValue: 1)

onJoinMeetingConfirmed

onWaitingRoomStatusChange
false

onMeetingStateChange)
State:2

onMeetingReady

Also there are times when the delegate mthod onMeetingStateChange() does not get called on starting the meeting. Please provide me support ASAP.

This is the page that appears when host starts the meeting at host end. And then it disappears to nothing.

This page appears at participant’s end when it joins that meeting. As you can see, this page shows participant video and not host’s video.

Hi,

Thanks for the detail. To check the version that you are using, after you download our iOS SDK, you will see the following file structure:

├── CHANGELOG.md
├── LICENSE.md
├── MobileRTCSample
├── README.md
├── lib
└── version.txt <- Version number is inside

I will work with the engineer to investigate the issue you are facing. I will get back to you as soon as possible. Thanks!

v4.3.1.47201.0322 is the version am using

Hi,
Thank you for all you details. It seems like you are encountering with multiple issues.

  1. In the code you starts the meeting, you pass “true” to the isAppShare, if you set this to be true, when you start the meeting, you will first see the shared contents instead of the meeting UI. Set isAppShare to be false will show the meeting UI.
user.isAppShare = false

If you would like to do screen sharing, here is the doc: https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/mastering-zoom-sdk/in-meeting-function/customized-in-meeting-ui/share
2. Based on your description, it seems like the camera of the host is not successfully activated, can you double check whether Zoom SDK has the permission to access the camera? You can refer to the doc for the required permission: https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/getting-started/integration#4-required-permissions
3. Based on the call flow you posted, the state:2 means you are in the meeting, which means the meeting is on and everything looks good.

Hope this helps. Thanks!

I tried all the steps suggested by you. Nothing seemed to work. Now it’s blank screen on both the sides after waiting loader. Could you help with the working swift code? that would be great!

Hi,

  1. Unfortunately, we do not have a Swift example. Due to the interoperability between Objective-C and Swift, the way of implementation is the same for Objective-C and Swift. You can refer to our demo app to help your implementation with our Zoom SDK.
  2. As I have mentioned in my previous reply. You are encountered with multiple issues. As you have mentioned: “nothing seems to work”, can you elaborate with the following questions?
    • Does changing the isAppShare = false bring you to the meeting UI?
    • Does checking the camera permission results in that the permission has been granted to our SDK?
    • Are you getting any errors?
  3. We really appreciate all the details and info you provided, but unfortunately, we are not able to identify the root cause based on the info and the observation that you provided. Can you follow the doc here (https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/mastering-zoom-sdk/sdk-initialization#2-log-feature) to enable the log feature, and send us the log when you encounter with these issues?

Thanks.

Hello, I made the project again and it seems to work now. However, there are few issues I want you to help me with like:

  1. I get the error MobileRTCMeetError(rawValue: 150)) sometimes when I start the meeting without login.

  2. How to know when the participant has left or end the call? Please give the solution for both.

  3. When the call ends the navigationBar disappears. I tried both the lines of code below to prevent this, but nothing worked:

    MobileRTC.shared()?.mobileRTCRootController()?.setNavigationBarHidden(false, animated: true)
      _

Hi,

  1. Error code: 150 means invalid arguments(https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/resource/error-codes#14-meeting-error-codes). Please double check whether you pass the correct information as the parameter to start the meeting. Please ensure you have the correct: keys & secrets, display name, meeting number.
  2. https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/mastering-zoom-sdk/in-meeting-function/zoom-meeting-ui/meeting-status#4-user-service-status
  3. Which navigation bar are you referring to? Can you provide a screenshot? If you end the meeting, then the Zoom SDK lifecycle is done. Changing the UI component in the Zoom SDK will not have any effect.
        var param = MobileRTCMeetingStartParam()
        let user = MobileRTCMeetingStartParam4WithoutLoginUser()
        user.userType = MobileRTCUserType_APIUser;
        user.meetingNumber = kSDKMeetNumber;
        user.userName = "Blah";
        user.userToken = token;
        user.userID = "Any id";
        user.isAppShare = false;
        user.zak = zak
        param = user
        let startResponse = service?.startMeeting(with: param)

These are my parameters. Let me know what’s wrong with them.
Thanks for the user’s info delegate methods. But I also wanted to know how to use them? How to set its delegate?

It is just a blank screen when call is ended. That is the screen on which I am showing Zoom UI, but now it’s without navigation bar.

  1. Since you mentioned that the error happens sometimes, not every time, so I just purposed some possibilities that could cause this error. There are 2 more assumptions that could cause this error:
  • Please make sure the userId is associated with the userToken and the zak that you pass through
  • It could also be possible that the userToken and the zak has expired and is sent to start the meeting.

Hope this info can help you find the issue and resolve it.

  1. The doc has the implementation of the expected methods (https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/mastering-zoom-sdk/in-meeting-function/zoom-meeting-ui/meeting-status#4-user-service-status), you can also find the full implementation in our working demo: https://github.com/zoom/zoom-sdk-ios/blob/0da49375fdc8bebf412e07413d6d1264281ade54/MobileRTCSample/MobileRTCSample/SDKPresenters/how_to_use_inmeeting_function/meeting_callback/SDKStartJoinMeetingPresenter%2BUserServiceDelegate.m#L16

  2. Regarding the navigation bar:

  • Do you end the meeting successfully? After successfully ending the meeting, the view will return the view that you defined. If the navigation bar in your own view has disappeared, then it is out of our SDK’s control.

  • If you stuck between sending the “end meeting” request and go back to your view, then it could be an issue, if this is the case: are you getting any error? Can you provide the SDK log regarding this?
    I tried to use our demo app to test the following scenarios:

    • Start an instant meeting and then end the meeting
    • Start a meeting, start sharing the screen, and then end the meeting
    • Join a meeting, and then leave the meeting

and I could not find the navigation bar disappearing issue.

I am generating zak and token using the below API, every time the user starts the call. So I don’t think it gets expired.
https://api.zoom.us/v2/usersTTTtokentype=token&access_token=TOKEN

Please find me a solution for MobileRTCMeetError(rawValue: 150)) problem.

Also it would great if you could tell me how you let the participant know that the video call is received. Through VoIP or any other thing in your iOS App.

The API you have mentioned is incorrect. The correct API to retrieve Zoom token and ZAK is:https://marketplace.zoom.us/docs/api-reference/zoom-api/users/usertoken. You can follow the instruction in the doc: https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/mastering-zoom-sdk/start-join-meeting/api-user/authentication.

If the error still exist occasionally, please attach or provide your log so that we can further help you. Without log, there is not too much things that we can do.

Hello,

I have followed your instructions to generate the tokens.
Zak:
https://api.zoom.us/v2/users/abc@gmail.com/token?type=zak&access_token=jwt

and Token:

https://api.zoom.us/v2/users/abc@gmail.com/token?type=token&access_token=jwt

There is nothing wrong with generating tokens from this url.

Thanks for the reply.

Can you follow the doc here (https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/mastering-zoom-sdk/sdk-initialization#2-log-feature) to enable the log feature, and send us the log when you encounter with these issues? Without a log, there are not too many things that we can do to help you.

Thanks!

Hello,

I am sorry but I don’t know how it working fine now. But I have another issue now, the video call is ended after sometime. Ongoing call is cancelled. Find below the logs

 [2210:771:06-12/19:39:33.276:INFO:CmmConfAgent.cpp(472)] CmmConfAgent::IsCMRInConnecting cmr status 0 Sever status0 
    [2210:771:06-12/19:39:33.276:INFO:CmmConfAgent.cpp(472)] CmmConfAgent::IsCMRInConnecting cmr status 0 Sever status0 
    2019-06-12 19:39:35.071415+0530 DoctorDash[2210:1415474] InitAudioUnit use hardware aec = 1
    2019-06-12 19:39:35.088179+0530 DoctorDash[2210:1415474] [aurioc] 1029: failed: '!pri' (enable 3, outf< 1 ch,  48000 Hz, Int16> inf< 1 ch,  48000 Hz, Int16>)
    [2210:68867:06-12/19:39:35.088:INFO:CmmConfAgent.cpp(7139)] [CmmConfAgent::DoWriteMonitorLog] ZoomConferenceClient,,[IOS].Error in AudioUnitInitialize(_audioUnit) return irp! 
    [2210:771:06-12/19:39:35.602:INFO:CmmLogging.h(965)] Function [CmmVideoSessionMgr::on_user_status] started ================>>> 
    [2210:771:06-12/19:39:35.602:INFO:CmmVideoSessionMgr.cpp(3636)] [CmmVideoSessionMgr::on_user_status] user_status: 10 len_of_list: 1 
    [2210:771:06-12/19:39:35.602:INFO:CmmVideoSessionMgr.cpp(6233)] [CmmVideoSessionMgr::SaveBWLevel] nameSonal KemNode ID16781313Quality2 
    [2210:771:06-12/19:39:35.602:INFO:CmmVideoSessionMgr.cpp(3580)] [CmmVideoSessionMgr::HandleuplinkStatusChanged] user: Sonal Kem, network level:3 
    [2210:771:06-12/19:39:35.602:INFO:CmmVideoSessionMgr.cpp(3597)] [CmmVideoSessionMgr::HandleuplinkStatusChanged] user: Sonal Kem, network level:3, My download level:3 
    [2210:771:06-12/19:39:35.603:INFO:CmmLogging.h(969)] <<<==================Function [CmmVideoSessionMgr::on_user_status] Ended. 
    [2210:771:06-12/19:39:36.202:INFO:CmmLogging.h(965)] Function [CmmVideoSessionMgr::on_user_status] started ================>>> 
    [2210:771:06-12/19:39:36.203:INFO:CmmVideoSessionMgr.cpp(3636)] [CmmVideoSessionMgr::on_user_status] user_status: 11 len_of_list: 1 
    [2210:771:06-12/19:39:36.203:INFO:CmmVideoSessionMgr.cpp(3441)] [CmmVideoSessionMgr::HandleDownLinkStatusChanged] Receiver16782337level4 
    [2210:771:06-12/19:39:36.203:INFO:CmmVideoSessionMgr.cpp(3474)] [CmmVideoSessionMgr::HandleDownLinkStatusChanged] Sender: Sonal Kem, up level:3, my downlink:4 
    [2210:771:06-12/19:39:36.203:INFO:CmmLogging.h(969)] <<<==================Function [CmmVideoSessionMgr::on_user_status] Ended. 
    [2210:771:06-12/19:39:36.203:INFO:CmmVideoSessionMgr.cpp(3700)] [CmmVideoSessionMgr::on_session_event] session_event: 1 
    [2210:771:06-12/19:39:37.866:INFO:CmmConfMgr.cpp(5231)] [ CmmConfMgr::NoOneisSendingVdeo()] start scan user, total 2 
    [2210:771:06-12/19:39:38.276:INFO:CmmConfAgent.cpp(472)] CmmConfAgent::IsCMRInConnecting cmr status 0 Sever status0 
    [2210:771:06-12/19:39:38.276:INFO:CmmConfAgent.cpp(472)] CmmConfAgent::IsCMRInConnecting cmr status 0 Sever status0 
    [2210:771:06-12/19:39:38.302:INFO:CmmLogging.h(965)] Function [CmmAudioSessionMgr::on_user_status] started ================>>> 
    [2210:771:06-12/19:39:38.302:INFO:CmmAudioSessionMgr.cpp(4613)] [CmmAudioSessionMgr::on_user_status] status:2 len:3 
    [2210:771:06-12/19:39:38.302:INFO:CmmAudioSessionMgr.cpp(5036)] [CmmAudioSessionMgr:: HandleActiveSpeakers] userid: 16781314 status is  1 
    [2210:771:06-12/19:39:38.302:INFO:SBConfUI.mm(176)] [CSBConfUI::OnUserStatusChanged] cmd:12 userId:0
    [2210:771:06-12/19:39:38.303:INFO:CmmLogging.h(969)] <<<==================Function [CmmAudioSessionMgr::on_user_status] Ended. 
    2019-06-12 19:39:38.523823+0530 DoctorDash[2210:1414764] [Application] -[UIApplication endIgnoringInteractionEvents] called without matching -beginIgnoringInteractionEvents. Ignoring.
    2019-06-12 19:39:39.333778+0530 DoctorDash[2210:1415474] InitAudioUnit use hardware aec = 1
    [2210:771:06-12/19:39:39.990:INFO:CmmConfMgr.cpp(5231)] [ CmmConfMgr::NoOneisSendingVdeo()] start scan user, total 2 
    [2210:771:06-12/19:39:39.999:INFO:CmmConfMgr.cpp(5231)] [ CmmConfMgr::NoOneisSendingVdeo()] start scan user, total 2 
    [2210:771:06-12/19:39:40.552:INFO:CmmLogging.h(965)] Function [CmmAudioSessionMgr::on_user_status] started ================>>> 
    [2210:771:06-12/19:39:40.552:INFO:CmmAudioSessionMgr.cpp(4613)] [CmmAudioSessionMgr::on_user_status] status:2 len:3 
    [2210:771:06-12/19:39:40.552:INFO:SBConfUI.mm(176)] [CSBConfUI::OnUserStatusChanged] cmd:12 userId:0
    [2210:771:06-12/19:39:40.552:INFO:CmmLogging.h(969)] <<<==================Function [CmmAudioSessionMgr::on_user_status] Ended. 
    [2210:771:06-12/19:39:41.152:INFO:CmmVideoSessionMgr.cpp(3700)] [CmmVideoSessionMgr::on_session_event] session_event: 1 
    [2210:771:06-12/19:39:41.304:INFO:CmmLogging.h(965)] Function [CmmAudioSessionMgr::on_user_status] started ================>>> 
    [2210:771:06-12/19:39:41.304:INFO:CmmAudioSessionMgr.cpp(4613)] [CmmAudioSessionMgr::on_user_status] status:2 len:3 
    [2210:771:06-12/19:39:41.304:INFO:CmmAudioSessionMgr.cpp(5036)] [CmmAudioSessionMgr:: HandleActiveSpeakers] userid: 16781314 status is  1 
    [2210:771:06-12/19:39:41.304:INFO:SBConfUI.mm(176)] [CSBConfUI::OnUserStatusChanged] cmd:12 userId:0
    [2210:771:06-12/19:39:41.305:INFO:CmmLogging.h(969)] <<<==================Function [CmmAudioSessionMgr::on_user_status] Ended. 
    [2210:771:06-12/19:39:42.502:INFO:CmmLogging.h(965)] Function [CmmAudioSessionMgr::on_user_status] started ================>>> 
    [2210:771:06-12/19:39:42.503:INFO:CmmAudioSessionMgr.cpp(4613)] [CmmAudioSessionMgr::on_user_status] status:2 len:3 
    [2210:771:06-12/19:39:42.503:INFO:SBConfUI.mm(176)] [CSBConfUI::OnUserStatusChanged] cmd:12 userId:0
    [2210:771:06-12/19:39:42.503:INFO:CmmLogging.h(969)] <<<==================Function [CmmAudioSessionMgr::on_user_status] Ended.

Note: Sonal Kem is the user calling this user i.e the caller. And this is the logs of callee.

Hi,
Thanks for the info. Do you mean that the meeting is ended by itself without pressing the leave meeting key? Please note that if you are not active for 40mins, the meeting will end by itself. Based on the log you provided, everything looks good and running, did not see any issues that will cause meeting ends in the log.

Thanks!

Yes it ends itself. Or you can say that the Zoom UI is dismissed after like 2-3 minutes. What do you mean by not active? The video call has been running and it ends in the middle.

Hi,
Thanks for the info. Regarding the meeting time out, you can refer to this help page: https://support.zoom.us/hc/en-us/articles/202460676-Will-My-Meeting-Time-Out-

However, it seems like this is not the case that you are facing. Do you have any other logs or info that you could provide regarding this issue? Based on the log you provided, everything looks good.

Would appreciate for any info.Thanks!