mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-26 21:42:11 +00:00
Use enums for LaunchType
This commit is contained in:
parent
3e25902894
commit
da3ca1fe02
1 changed files with 2 additions and 5 deletions
|
|
@ -309,13 +309,11 @@ namespace Cosmos.VS.DebugEngine.AD7.Impl
|
||||||
string xPortType = xParts[0].ToLower();
|
string xPortType = xParts[0].ToLower();
|
||||||
string xPortParam = xParts[1].ToLower();
|
string xPortParam = xParts[1].ToLower();
|
||||||
|
|
||||||
var xLaunch = mDebugInfo[BuildPropertyNames.LaunchString];
|
|
||||||
|
|
||||||
OutputText("Starting debug connector.");
|
OutputText("Starting debug connector.");
|
||||||
switch (xPortType)
|
switch (xPortType)
|
||||||
{
|
{
|
||||||
case "pipe:":
|
case "pipe:":
|
||||||
if (xLaunch == "HyperV")
|
if (mLaunch == LaunchType.HyperV || mLaunch == LaunchType.Qemu)
|
||||||
{
|
{
|
||||||
mDbgConnector = new DebugConnectorPipeClient(xPortParam);
|
mDbgConnector = new DebugConnectorPipeClient(xPortParam);
|
||||||
}
|
}
|
||||||
|
|
@ -325,7 +323,7 @@ namespace Cosmos.VS.DebugEngine.AD7.Impl
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "serial:":
|
case "serial:":
|
||||||
if (xLaunch == "IntelEdison")
|
if (mLaunch == LaunchType.IntelEdison)
|
||||||
{
|
{
|
||||||
mDbgConnector = new DebugConnectorEdison(xPortParam, Path.ChangeExtension(mDebugInfo["ISOFile"], ".bin"));
|
mDbgConnector = new DebugConnectorEdison(xPortParam, Path.ChangeExtension(mDebugInfo["ISOFile"], ".bin"));
|
||||||
}
|
}
|
||||||
|
|
@ -336,7 +334,6 @@ namespace Cosmos.VS.DebugEngine.AD7.Impl
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Exception("No debug connector found for port type '" + xPortType + "'");
|
throw new Exception("No debug connector found for port type '" + xPortType + "'");
|
||||||
|
|
||||||
}
|
}
|
||||||
mDbgConnector.SetConnectionHandler(DebugConnectorConnected);
|
mDbgConnector.SetConnectionHandler(DebugConnectorConnected);
|
||||||
mDbgConnector.CmdBreak += new Action<uint>(DbgCmdBreak);
|
mDbgConnector.CmdBreak += new Action<uint>(DbgCmdBreak);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue