一、如何进入 Emulator console
telnet localhost 5554
二、在console下做什么工作
一、网络重定向,例如
redir add tcp:5000:6000
就是把对来自 localhost:5000 的TCP或UDP转向到 10.0.2.15:6000
redir list 列出所有重定向
redir del 删除重定向
To allow one emulator instance to communicate with another, you must set up the necessary network redirections as illustrated below. Assume that your environment is and you want to run a server on B, to which C will connect, here is how you could set it up: For example, if you wanted to run an HTTP server, you can select Interconnecting Emulator Instances
10.0.2.15:<serverPort>
A:localhost:<localPort>
to B:10.0.2.15:<serverPort>
<serverPort>
as 80 and <localPort>
as 8080:redir add tcp:8080:80
2、network status命令
3 、network delay <value> 其中 value有以下值
The format of network is one of the following (numbers are milliseconds):
network delay gprs
Value Description Comments gprs
GPRS (min 150, max 550) edge
EDGE/EGPRS (min 80, max 400) umts
UMTS/3G (min 35, max 200) none
No latency (min 0, max 0) <num>
Emulate an exact latency (milliseconds). <min>:<max>
Emulate an specified latency range (min, max milliseconds).
network speed 14.4 80
The format of network <speed>
is one of the following (numbers are kilobits/sec):
Value | Description | Comments |
---|---|---|
gsm | GSM/CSD | (Up: 14.4, down: 14.4) |
hscsd | HSCSD | (Up: 14.4, down: 43.2) |
gprs | GPRS | (Up: 40.0, down: 80.0) |
edge | EDGE/EGPRS | (Up: 118.4, down: 236.8) |
umts | UMTS/3G | (Up: 128.0, down: 1920.0) |
hsdpa | HSDPA | (Up: 348.0, down: 14400.0) |
full | no limit | (Up: 0.0, down: 0.0) |
<num> | Set an exact rate used for both upload and download. | |
<up>:<down> | Set exact rates for upload and download separately. |