Created
April 16, 2014 17:00
-
-
Save koenkooi/10907293 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iMac:MultiWii koen$ git diff | |
diff --git a/EEPROM.cpp b/EEPROM.cpp | |
index 11e57d5..38675df 100644 | |
--- a/EEPROM.cpp | |
+++ b/EEPROM.cpp | |
@@ -166,11 +166,11 @@ void LoadDefaults() { | |
conf.dynThrPID = 0; | |
conf.thrMid8 = 50; conf.thrExpo8 = 50; | |
for(i=0;i<CHECKBOXITEMS;i++) {conf.activate[i] = 0;} | |
- | |
+/* TODO: find MW2.3 equivalent of these: | |
conf.activate[BOXHORIZON] = 1 << 0 | 1 << 1 | 1 << 2; | |
conf.activate[BOXHEADFREE] = 1 << 2; | |
conf.activate[BOXBARO] = 1 << 5; | |
- | |
+ */ | |
conf.angleTrim[0] = 0; conf.angleTrim[1] = 0; | |
conf.powerTrigger1 = 0; | |
#endif // SUPPRESS_DEFAULTS_FROM_GUI | |
diff --git a/Protocol.cpp b/Protocol.cpp | |
index 5010f0f..f87c2e8 100644 | |
--- a/Protocol.cpp | |
+++ b/Protocol.cpp | |
@@ -96,6 +96,10 @@ void evaluateCommand(); | |
const uint32_t capability = 0+BIND_CAPABLE; | |
+#if defined(HEX_NANO) | |
+ volatile uint16_t serialRcValue[RC_CHANS] = {1502, 1502, 1502, 1502, 1502, 1502, 1502, 1502}; | |
+#endif | |
+ | |
uint8_t read8() { | |
return inBuf[indRX[CURRENTPORT]++][CURRENTPORT]&0xff; | |
} | |
@@ -310,10 +314,10 @@ void evaluateCommand() { | |
//headSerialReply(0); | |
break; | |
case MSP_ARM: | |
- go_arm(); | |
+ f.OK_TO_ARM = 1; // allow arming again | |
break; | |
case MSP_DISARM: | |
- go_disarm(); | |
+ f.OK_TO_ARM = 0; // disallow arming | |
break; | |
case MSP_TRIM_UP: | |
conf.angleTrim[PITCH]+=4; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment