If the virtual machine you mentioned is an Android emulator, you can use Google Maps API. Make sure that the system image of your emulator contains Google APIs. Please refer to the picture below to see if the emulator is running with an image that says Android X.X (with Google APIs).
If you are using Jenny Motion, please refer to the following link.
© 2024 OneMinuteCode. All rights reserved.