The Profiler can't find my device

MorganTouverey-QuillingMorganTouverey-Quilling FRMember ✭✭
edited February 3 in Profiler

Hello,

When clicking Analyze > Xamarin Profiler, the project builds, the APK is copied to the device and the Profiler starts. However, it stops there, nothing happens next, and the debugging session does not starts.

Build + Deployment log is OK:

Starting deploy Android_Emulator ...
Deploying Android_Emulator ...
Project "SomeApp.Droid.csproj" (Install target(s)):
Project "SomeApp.csproj" (GetTargetFrameworks target(s)):
Done building project "SomeApp.csproj".
Project "SomeApp.csproj" (GetTargetPath target(s)):
Done building project "SomeApp.csproj".
Project "SomeApp.csproj" (GetNativeManifest target(s)):
Done building project "SomeApp.csproj".
Project "SomeApp.csproj" (GetCopyToOutputDirectoryItems target(s)):
Done building project "SomeApp.csproj".
Done building project "SomeApp.Droid.csproj".
Deploy successfully on Android_Emulator

But it stops after "Deploy successfully".

The Profiler journal shows an error though:

XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.6121] ##########################################
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.6141] # Xamarin Profiler version -  1.6.0.27
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.6141] #  * Arch x86_64
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.6141] ##########################################
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.7753] initializing android platform
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.7753] initializing ios platform
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.7768] initializing mlpd platform
XamarinProfiler.Core.Profiler Information: 0 : [2018-02-03 22:35:56.8320] processing command line = C:\Program Files (x86)\Xamarin\Profiler\XamarinProfiler.exe --type=android --target=com.someapp|md5d4bff389b14a00bc1e2d61b483408394.MainActivity --device=Android_Emulator --options=name:Android_Emulator
XamarinProfiler.Windows.Core.WindowsRunFactory Information: 0 : [2018-02-03 22:36:00.4633] Creating android run for com.someapp|md5d4bff389b14a00bc1e2d61b483408394.MainActivity target on device Android_Emulator
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Information: 0 : [2018-02-03 22:36:00.4824] Initialisation du profilage...
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Information: 0 : [2018-02-03 22:36:00.5295] En attente de connexion de l'appareil Android_Emulator
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Error: 0 : [2018-02-03 22:36:00.5325] Nous sommes désolés, un problème s'est produit lors d'une tentative d'exécution de com.someapp : Appareil Android_Emulator introuvable
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Error: 0 : [2018-02-03 22:36:00.5325] Nous sommes désolés, un problème s'est produit lors d'une tentative d'exécution de com.someapp : Appareil Android_Emulator introuvable
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Information: 0 : [2018-02-03 22:36:00.5325] Nous sommes désolés, un problème s'est produit lors d'une tentative d'exécution de com.someapp : Appareil Android_Emulator introuvable
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Information: 0 : [2018-02-03 22:36:00.5355] Arrêt de la session. Veuillez patienter...
XamarinProfiler.Windows.ViewModels.ProgressReport.ReportViewModel Information: 0 : [2018-02-03 22:36:00.5441] Arrêté
XamarinProfiler.Windows.MainWindow Error: 0 : [2018-02-03 22:36:00.5446] Error occured on run com.someapp: Appareil Android_Emulator introuvable
XamarinProfiler.Windows.MainWindow Error: 0 : [2018-02-03 22:36:00.5446] Error occured on run com.someapp: Appareil Android_Emulator introuvable
XamarinProfiler.Windows.MainWindow Information: 0 : [2018-02-03 22:36:00.5451] StartRecording for com.someapp
XamarinProfiler.Windows.MainWindow Information: 0 : [2018-02-03 22:36:00.8159] CurrentRun.Finished for com.someapp

"Appareil Android_Emulator introuvable" is the french for something like "Device Android_Emulator cannot be find". Seems to be the only key message here, the rest says nothing special (ie. starting/ending session, please wait, sorry for the error, etc).

Nothing in the "Console" tab of the profiler, since the app doesn't starts at all.

I can confirm that I can launch normal debugging sessions. This is only a Profiler problem.

I have the latest versions of e-ve-ry-thing. I even reinstalled the entire Visual Studio + Xamarin + Android toolchain from scratch. Including downloading the latest Profiler installer from the website in the case the one provided with VS would be outdated. But no, I won't go as far as reinstalling Windows ;)

Thanks in advance.

Posts

  • RodrigoMoyaRodrigoMoya ESXamarin Team Xamurai

    Reinstalling Windows should not be needed, so please don't do it :smile:

    So, what Android API is that project targeting? And also, what does adb devices show when you hit the problem (that is, when the device is attached to your system and profiler can't find it).

    Note that adb command might not be in the path, so look, in VS->Tools->Options->Xamarin->Android if there is a path there, and just append look for the adb command there.

  • RodrigoMoyaRodrigoMoya ESXamarin Team Xamurai

    Ok, seems there is an incompatibility for users who use the old Google tools for managing SDK/AVDs. They should use our new SDKManager / Device Manager tooling or the CLI equivalents as Google deprecated these old tools back in last March.

    A possible solution to the problem is to upgrade SDK tools to > 25.2.5, and re-create your emulators using Xamarin's SDK manager (Tools->SDK Manager) to download a proper image and the AVD manager

  • MorganTouverey-QuillingMorganTouverey-Quilling FRMember ✭✭
    edited February 13

    Thanks for your answer. I'm using Google's tools indeed, so this might be the problem.

    I'm not using Xamarin's one as the downloaded Android system images weren't recognized by Google's AVD, therefore I couldn't create new/edit AVDs as the system images list was empty (and the Google SDK manager showed images downloaded by Xamarin as "broken").

    I will try again using Xamarin's tools "end to end" and post here again then.

Sign In or Register to comment.