aboutsummaryrefslogtreecommitdiffstats
path: root/Projects
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2010-07-22 12:34:32 +0000
committerDean Camera <dean@fourwalledcubicle.com>2010-07-22 12:34:32 +0000
commit2461ae508c32914ff8aa0920ed99d4fceb18b141 (patch)
tree28651d6de62b21d948f100044e7c294e29c9d675 /Projects
parentac0ece0141fe9470539380fb5e5f069a0ff701ff (diff)
downloadlufa-2461ae508c32914ff8aa0920ed99d4fceb18b141.tar.gz
lufa-2461ae508c32914ff8aa0920ed99d4fceb18b141.tar.bz2
lufa-2461ae508c32914ff8aa0920ed99d4fceb18b141.zip
Future proof the XPROG protocol of the AVRISP-MKII project, so that non PDI and TPI requests return failure.
Diffstat (limited to 'Projects')
-rw-r--r--Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.c b/Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.c
index 84d82bc5f..0f5269db9 100644
--- a/Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.c
+++ b/Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.c
@@ -115,7 +115,7 @@ static void XPROGProtocol_EnterXPROGMode(void)
Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
- bool NVMBusEnabled;
+ bool NVMBusEnabled = false;
if (XPROG_SelectedProtocol == XPRG_PROTOCOL_PDI)
{
@@ -138,7 +138,7 @@ static void XPROGProtocol_EnterXPROGMode(void)
/* Wait until the NVM bus becomes active */
NVMBusEnabled = XMEGANVM_WaitWhileNVMBusBusy();
}
- else
+ else if (XPROG_SelectedProtocol == XPRG_PROTOCOL_TPI)
{
/* Enable TPI programming mode with the attached target */
XPROGTarget_EnableTargetTPI();