return _emul_info.vm_base_port;
}
+/* ecs port for emualtor vm */
+void set_emul_vm_ecs_port(int port)
+{
+ _emul_info.vm_ecs_port = port;
+}
+
+int get_emul_vm_ecs_port(void)
+{
+ return _emul_info.vm_ecs_port;
+}
+
/* current emulator condition */
int get_emulator_condition(void)
{
bool input_touch_enable;
int max_touch_point;
int vm_base_port;
+ int vm_ecs_port;
/* add here */
} EmulatorConfigInfo;
void set_emul_input_touch_enable(bool on);
void set_emul_max_touch_point(int cnt);
void set_emul_vm_base_port(int port);
+void set_emul_vm_ecs_port(int port);
void set_emulator_condition(int state);
void set_emul_rotation(short rotation_type);
bool is_emul_input_touch_enable(void);
int get_emul_max_touch_point(void);
int get_emul_vm_base_port(void);
+int get_emul_vm_ecs_port(void);
int get_emulator_condition(void);
short get_emul_rotation(void);
sdb_setup(); /* determine the base port for emulator */
set_emul_vm_base_port(tizen_base_port);
+ set_emul_vm_ecs_port(tizen_ecs_port);
+
gchar * const tmp_str = g_strdup_printf(" sdb_port=%d,"
" http_proxy=%s https_proxy=%s ftp_proxy=%s socks_proxy=%s"
" dns1=%s", get_emul_vm_base_port(),
/* base + 1 = sdb port */
/* base + 2 = shared memory key */
- int shmkey = config.getArgInt(ArgsConstants.NET_BASE_PORT) + 2;
+ int shmkey = config.getArgInt(ArgsConstants.VM_BASE_PORT) + 2;
logger.info("shmkey = " + shmkey);
/* initialize shared memory */
}
private void setColorVM() {
- int portNumber = config.getArgInt(ArgsConstants.NET_BASE_PORT) % 100;
+ int portNumber =
+ config.getArgInt(ArgsConstants.VM_BASE_PORT) % 100;
if (portNumber >= 26200) {
int red = (int) (Math.random() * 256);
public void widgetSelected(SelectionEvent e) {
String emulName = SkinUtil.getVmName(config);
- int portSdb = config.getArgInt(ArgsConstants.NET_BASE_PORT);
- int portEcp = 0;
+ int portSdb = config.getArgInt(ArgsConstants.VM_BASE_PORT);
+ int portEcp = config.getArgInt(ArgsConstants.VM_ECS_PORT);
+ /*
DataTranfer dataTranfer = communicator.sendDataToQEMU(
SendCommand.ECP_PORT_REQ, null, true);
byte[] receivedData = communicator.getReceivedData(dataTranfer);
portEcp |= receivedData[1] << 16;
portEcp |= receivedData[2] << 8;
portEcp |= receivedData[3];
+ */
ProcessBuilder procEcp = new ProcessBuilder();
return;
}
- int portSdb = config.getArgInt(ArgsConstants.NET_BASE_PORT);
+ int portSdb = config.getArgInt(ArgsConstants.VM_BASE_PORT);
ProcessBuilder procSdb = new ProcessBuilder();
public static final String RESOLUTION_WIDTH = "width";
public static final String RESOLUTION_HEIGHT = "height";
public static final String TEST_HEART_BEAT_IGNORE = "test.hb.ignore";
- public static final String VM_PATH = "vm.path";
public static final String LOG_LEVEL = "log.level";
- public static final String NET_BASE_PORT = "net.baseport";
+ public static final String VM_PATH = "vm.path";
+ public static final String VM_BASE_PORT = "vm.baseport";
+ public static final String VM_ECS_PORT = "vm.ecsport";
public static final String SKIN_PATH = "skin.path";
public static final String DISPLAY_SHM = "display.shm";
public static final String INPUT_MOUSE = "input.mouse";
import org.tizen.emulator.skin.EmulatorSkin;
import org.tizen.emulator.skin.EmulatorSkinState;
import org.tizen.emulator.skin.comm.ICommunicator.RotationInfo;
-import org.tizen.emulator.skin.comm.ICommunicator.SendCommand;
-import org.tizen.emulator.skin.comm.sock.data.DisplayStateData;
import org.tizen.emulator.skin.config.EmulatorConfig;
import org.tizen.emulator.skin.config.EmulatorConfig.ArgsConstants;
import org.tizen.emulator.skin.config.EmulatorConfig.SkinPropertiesConstants;
displayCanvas = new Canvas(shell, style);
- int vmIndex = config.getArgInt(ArgsConstants.NET_BASE_PORT) % 100;
+ int vmIndex =
+ config.getArgInt(ArgsConstants.VM_BASE_PORT) % 100;
int x = config.getSkinPropertyInt(SkinPropertiesConstants.WINDOW_X,
EmulatorConfig.DEFAULT_WINDOW_X + vmIndex);
vmName = EMULATOR_PREFIX;
}
- int portNumber = config.getArgInt(ArgsConstants.NET_BASE_PORT);
+ int portNumber = config.getArgInt(ArgsConstants.VM_BASE_PORT);
return vmName + ":" + portNumber;
}
#define OPT_SVR_PORT "svr.port"
#define OPT_UID "uid"
#define OPT_VM_PATH "vm.path"
-#define OPT_NET_BASE_PORT "net.baseport"
+#define OPT_VM_BASE_PORT "vm.baseport"
+#define OPT_VM_ECS_PORT "vm.ecsport"
#define OPT_DISPLAY_SHM "display.shm"
#define OPT_INPUT_MOUSE "input.mouse"
#define OPT_INPUT_TOUCH "input.touch"
char* vm_path = tizen_target_path;
//INFO( "vm_path:%s\n", vm_path );
+
char buf_skin_server_port[16];
char buf_uid[16];
- char buf_tizen_base_port[16];
+ char buf_vm_base_port[16];
+ char buf_vm_ecs_port[16];
sprintf(buf_skin_server_port, "%d", skin_server_port);
sprintf(buf_uid, "%d", uid);
- sprintf(buf_tizen_base_port, "%d", get_emul_vm_base_port());
+ sprintf(buf_vm_base_port, "%d", get_emul_vm_base_port());
+ sprintf(buf_vm_ecs_port, "%d", get_emul_vm_ecs_port());
/* display */
char buf_display_shm[8] = { 0, };
strlen(buf_uid) + SPACE_LEN +
strlen(OPT_VM_PATH) + EQUAL_LEN +
QUOTATION_LEN + strlen(vm_path) + SPACE_LEN +
- strlen(OPT_NET_BASE_PORT) + EQUAL_LEN +
- strlen(buf_tizen_base_port) + SPACE_LEN +
+ strlen(OPT_VM_BASE_PORT) + EQUAL_LEN +
+ strlen(buf_vm_base_port) + SPACE_LEN +
+ strlen(OPT_VM_ECS_PORT) + EQUAL_LEN +
+ strlen(buf_vm_ecs_port) + SPACE_LEN +
strlen(OPT_DISPLAY_SHM) + EQUAL_LEN +
strlen(buf_display_shm) + SPACE_LEN +
strlen(OPT_INPUT_TOUCH) + EQUAL_LEN +
%s=%d \
%s=\"%s\" \
%s=%d \
+%s=%d \
%s=%s \
%s=%s \
%s=%d \
OPT_SVR_PORT, skin_server_port,
OPT_UID, uid,
OPT_VM_PATH, vm_path,
- OPT_NET_BASE_PORT, get_emul_vm_base_port(),
+ OPT_VM_BASE_PORT, get_emul_vm_base_port(),
+ OPT_VM_ECS_PORT, get_emul_vm_ecs_port(),
OPT_DISPLAY_SHM, buf_display_shm,
OPT_INPUT_TOUCH, buf_input_touch,
OPT_MAX_TOUCHPOINT, maxtouchpoint,