Everyone.
I get a lot of questions about how I make my emulator so fast for Android
and how I keep it on top of the screen and just normal settings that I use.
So today I want to break it down.
So tonight.
Hey everyone.
I'm James Monson Magno.
I'm a program manager over at Microsoft and I've been a Xamarin developer, an
Android developer for over 10 years.
I love everything about Android and iOS of course too.
But one of the things that always has upset me is the Android emulator.
And it's gotten so much better in the most recent years, but there's a lot of tips
and tricks that I've just developed over the years of using the Android emulator.
So if you're brand new, I want to give you a walkthrough.
Of how to get set up.
But then of course, some of the settings I use such as keeping on top of the screen
and some other things like playing around with the sensors, so let's check it out.
Now Android emulators are complicated.
Okay.
They just are.
Um, in fact, if we look at the Xamarin documentation or just
general Android documentation, there are sort of different flavors of
how to run the Android emulator.
There's sort of three.
Okay.
First is to run it on Intel hacks some.
So if you have an Intel processor and you have the ability to do
the hardware acceleration part of it, you can use Intel hacks.
I mean, that's what I use on my machine.
Now the problem with Intel hacks on a PC is that if you need to use hyper V.
And you run into a conflict.
This was a big problem early in the days.
If you need to do Docker development that use hyper V nowadays, you have WSL too,
so there's no longer really a conflict.
So you can go back and use Intel, um, hacks them if you're there.
Now, beyond that though, if you have an AMD processor, well, you're going
to have sort of a problem because you don't have Intel processors there.
So that means that you're going to have to use hyper V and those
Android emulators are super quick.
I have another video that I made.
It's like one minute long and how to set that up, but a link to this documentation.
So you can decide what you want to do.
If you want to use hyper V.
But the hypervisor habit hypervisor framework.
So that's pretty good here.
Okay.
Um, and we'll probably even update this to make sure that you kind of know
that you can use WSL too there too.
Now over on Mac though.
Um, you're good.
You just use Intel hacks on and you're fine.
Nope, no problem there at all.
So you're good.
And of course, Linux, same thing.
You should be just fine.
Now I am of course coming from the Xamarin world.
So we have over here, we have the Android device manager and they put
this in the center of the screen.
This enables you to create new Android emulators.
It's very similar to the one in Android studio.
You can customize anything.
I pay for some reason, I've just always stuck with.
Android nine.
I don't know why necessarily, but I always have for some reason, but you
can create any different version here.
Um, some people like to use the Google APIs and put Google play store on it.
I find it to be a little bit slower.
If you don't need Google API APIs like maps or anything like that,
or need access to Google play store, you can uncheck those.
I think it just makes it faster in general, less things
to update on your device.
Let's go ahead and start this up here.
This is just a normal Android nine.
No Google-y stuff on it at all.
And it's just going to boot up over here.
All right.
Oh, I was playing with Don and Maui earlier.
Let's go ahead and flip this away.
There we go.
Cool.
I'm going to zoom out and just going to put this right in
the center of the screen here.
And the first thing that you'll note is that my Android emulator
stays right on top of the screen.
Okay.
So see how it's moving around.
If I actually bring up the font here again.
It's right on top.
If I click away nothing, nothing, nothing.
Right?
So that is a setting.
And actually is inside of this triple dot.
This triple dot area is one of the most important parts of the Android
emulator, because it gives you access to all sorts of things that you can
emulate on the emulator if you will.
Yeah.
Cause it's not a simulators and emulators.
So basically it gives you the ability to have more of a physical device.
Even though this is an emulator, so we can see here, here's a location.
So it's set by default to Palo Alto.
You could import GPX or KML files right here, or set a
location super important there.
If you're looking at test cellular and you don't want to kind of swipe down from the
bottom and put it in airplane mode, you can come in and you can toggle what type
of network it is, what the strength is.
You can test all of those different settings and it will do that for you.
Battery.
What do you know?
It adjusts the battery.
Like you can see it right there.
It's adjusting it.
You know what I mean?
A camera, same thing you can add, uh, uh, different virtual
scenes, which are nice here.
Um, I don't really use that too much.
I can emulate a phone call.
You can emulate the directional pad, a microphone here, fingerprint reader.
So you can have different touch sensors, virtual sensors.
These are cool.
If you want to actually test different sensors on the device over here, you can
actually pan it as well left and right.
And so if you're doing a game that's super duper important there.
Um, you can even send a bug report while it was pretty cool.
Now, what I will say before we get to these other settings down
here is this setting screen.
This is really important.
You can set your light theme or your dark theme, which is really
important to know, uh, over here you can enable clipboard sharing.
So if you want to share between your desktop and your, um, your Android
device, you want to have that enabled.
Over here you can enable or disable mouse wheel.
So if you're scrolling on your mouse to scroll up and down, you
can disable that and you can see it's kind of moving around there.
If I scroll up and down, you can disable that there there's other things
like if you want a frame on top of it, you can disable the device frame.
Sometimes the device frame causes some issue for people
and it's just extra clutter.
So if you don't want that, it's there.
But most importantly, look at this one right here.
Boom, emulator, always on top.
This is the toggle.
This is the jam.
So now.
It goes back and forth, but toggle it on.
It's always on top.
Super important.
It can be annoying if you're using the settings screen though, but
it's one setting that I super like and really appreciate that's there.
Now some of the other things, if you're using HTTP proxies, you
can go in, you can turn this on.
I've never used these, but this is just a ability.
If you're doing advanced networking that you need to do that, there's
just some advanced stuff for open GL.
Again, if you're doing games you might want to automatically, um,
toggle between some of the different open G L E S modes that are there.
I will bring one more point over here.
Um, this is actually really nice to record in playback.
So if you start a recording, you can go ahead and, um, you know, play around on
the emulator and then hit stop recording.
And then you can save this as a web and P uh, web M or a GIF, which is nice too.
So you can save it and do whatever you want, which is kind of cool.
Let's see, we've got a little warning here.
Oh, cool.
Nothing.
Uh, shots is another fascinating one.
Um, I don't know if I love or hate snapshots.
Um, I feel like on Intel hacks on these things are pretty good
and you can actually create snapshots that you can boot into.
It's going to obviously, you know, keeps more memory on desserts, keeping
an entire snapshot of your device.
If for some reason your emulator won't boot up, you can turn this off.
Okay.
Um, you can also just have it automatically delete
invalid, uh, snapshots, too.
Um, so for some reason, your emulator just be in slow, or it's
not starting up correctly, simply turn this off and you're good to go.
I feel with hyper V the snapshots, um, seem to sometimes cause
some issues on some devices.
It's always hard to tell Android on windows, always a little bit tricky.
So you're gonna have to like turn that off there.
Um, you know, but here this one seemed to work and we can see the last boot that
I had here, which is kind of cool too.
And you can always take a snapshot if you need to.
The other things I'll point off is that you have more, um, uh, the
ability over here to simply change a lot of settings, um, from this
little, I guess, quick option thing.
So you have obviously volume up over here, museum out.
Cause it gets a little crazy.
If I zoom in volume up volume down, you're able to rotate the
device, which is super nice too.
Um, you can take a screenshot.
Let me go on rotate this again.
There we go.
That screenshot is going to be over on our desktops and
we can see it's always on top.
So here's the desktop that I have here.
So we have the two different screenshots that I took earlier.
You can also zoom in.
So this is like a zoom mode.
If you want to zoom in and actually magnify as well, your device.
And then of course you have the back arrows over here.
So for some reason, those aren't on your screen, you can
always get access to them there.
But one thing that always sometimes confuses developers
is this, this power button.
This one here.
See that you tap on that.
It turns off the device.
Okay.
Now, if you then close the device, it takes a snapshot.
And then if I launch it again, we're going to resume our Android
emulator, but it's going to be off.
Because I toggled it off.
Remember you gotta toggle it back on.
So that's one thing I always try.
That would be my final tip of triggers.
If it's just a black screen, just to have that power button, you can't
really get access to it any other way, besides tapping that power button
or some of these other buttons down here to actually flip it back on.
So if you're like, whoa, why is this off?
It looks like a power button, but it's a power button for the phone
Saturday, if you just toggled your, your side button as well.
So it's all right there for you.
Um, so that, that's how you do it anyways.
I hope that you found this video, uh, of helpful, just kind of walking
through the Android emulator, um, showing you how to set it.
So it's always on top and of course, how to set it up base.
If you have an Intel machine or an AMD machine, or if you
need to use hyper V or not.
Like I said, I'm using the Intel hack someone here.
I also use the Hyperview one on my other work machines, like my
surface book, uh, which also seems to work really, really great.
So no matter where you're developing, you should be good to go, but if you
have any questions about any things that I've been customizing in my
Android emulator, Leave comments below.
I definitely like to respond to any of those as fast as I can.
And of course, give this a thumbs up if you like this video and you want more
sort of general tips and tricks those thumbs up some likes over there, go into
the Google algorithm of goodness and recommend this video to other people.
So I hope that you enjoyed this video.
I'm going to go on a hike because I have my hiking clothes on.
I hope you have a great day, great weekend wherever you're at in the world.
And thanks for it.