ConnectSDK / Connect-SDK-Android-Core

Core source code for the Android Connect SDK project
Apache License 2.0
117 stars 83 forks source link

Failed to connect to Google Cast device (Chromcast) #135

Open Mehrankhan92 opened 2 years ago

Mehrankhan92 commented 2 years ago

Hi,

I am developing a TV Remote control application. I am only discovering CastService and DLNAService devices. After getting the devices list. I select a device and try to connect it with the below code.

` deviceModel.connectableDevice.addListener(connectableDeviceListener) deviceModel.connectableDevice.setPairingType(DeviceService.PairingType.MIXED) deviceModel.connectableDevice.connect()

`

After a few seconds, I only receive a callback in onDeviceDisconnected() method. nothing else is happening. After some deep debugging, I found that the error states that Failed to connect to Google Cast Device.

I have no idea about what is going wrong here. Am I missing something ?

Also, What should I set in .setPairingType(PairingType) as I have tried all the PairingTypes but of no use.

najam-amfnrh9 commented 1 year ago

Hye, Have you fixed with your issue? I need help in an issue like above.