Problems Connecting Android Devices to Delphi – Tokyo

I recently ran into head winds making use of my newly acquired Mobile Development environment on Tokyo. In this article I explain some of these issues and how they were finally resolved in the hope it might help others.

While I have been playing with Firemonkey since its inception I have had to collaborate with colleagues to test my stuff on Mobile devices. I have a Galaxy Pocket Neo (GT-S5310B) running Android 4.1.2 which until Tokyo served as a test platform for non 3D applications. 3D does not work on this device so I acquired a Galaxy J1 mini Model No SM-J105Y running Android 5.1.1 with a broken screen for proof of concept on 3D applications.

I already had Tokyo 10.2.2 loaded before getting the (free) Mobile add on code. Before uninstalling Delphi and Installing Tokyo Patch 3 (10.2.3) I ran the license manager (Help>License Manager from Delphi), added and then registered my upgrade code. I was then offered all platform options when installing 10.2.3.

There were different instruction on how to get mobile stuff if 10.2.3 was already loaded.

The mobile platforms now appeared in new projects and could be added to old projects and I can build Android applications.

My real problems started when I later came to try to test software on an actual Android device. I needed to connect my Samsung Android devices to Delphi.  The Tokyo help instructions showed an XE6 start menu to access the SDK Manager and load USB Drivers.

This link did not appear on my Start Menu so finding the SDK manager was a problem. I therefore initially downloaded the Google Zip file as suggested on that page.

The google drivers do not play with plug and play at least they did not resolve the driver install errors.

I then managed to find the SDK manager. Tokyo installed it on my machine in  C:\Users\Public\Documents\Embarcadero\Studio\19.0\CatalogRepository\AndroidSDK-2433_19.0.29899.2631. I used this to “install” the Google drivers but still had CRC and ADB drivers missing on both phones.

Downloading OEM drivers (Samsung) was the other solution suggested on and that resulted in all Windows driver problems being resolved but only one phone was found as a “Target” in Delphi and while Delphi remote debugging works with that phone and Jellybean is claimed as still being supported in Tokyo it raises exceptions with even the most basic Firemonkey form.

Solving The Android 5.1.1 Target Issue.

Finally Hacking Delphi to Let Older Phones Work with Tokyo.

Leave a Reply

Your email address will not be published. Required fields are marked *