mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-19 04:18:43 +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 xPortParam = xParts[1].ToLower();
|
||||
|
||||
var xLaunch = mDebugInfo[BuildPropertyNames.LaunchString];
|
||||
|
||||
OutputText("Starting debug connector.");
|
||||
switch (xPortType)
|
||||
{
|
||||
case "pipe:":
|
||||
if (xLaunch == "HyperV")
|
||||
if (mLaunch == LaunchType.HyperV || mLaunch == LaunchType.Qemu)
|
||||
{
|
||||
mDbgConnector = new DebugConnectorPipeClient(xPortParam);
|
||||
}
|
||||
|
|
@ -325,7 +323,7 @@ namespace Cosmos.VS.DebugEngine.AD7.Impl
|
|||
}
|
||||
break;
|
||||
case "serial:":
|
||||
if (xLaunch == "IntelEdison")
|
||||
if (mLaunch == LaunchType.IntelEdison)
|
||||
{
|
||||
mDbgConnector = new DebugConnectorEdison(xPortParam, Path.ChangeExtension(mDebugInfo["ISOFile"], ".bin"));
|
||||
}
|
||||
|
|
@ -336,7 +334,6 @@ namespace Cosmos.VS.DebugEngine.AD7.Impl
|
|||
break;
|
||||
default:
|
||||
throw new Exception("No debug connector found for port type '" + xPortType + "'");
|
||||
|
||||
}
|
||||
mDbgConnector.SetConnectionHandler(DebugConnectorConnected);
|
||||
mDbgConnector.CmdBreak += new Action<uint>(DbgCmdBreak);
|
||||
|
|
|
|||
Loading…
Reference in a new issue