/************************ AP FlightMode **********************************/ /*** FUNCTIONALITY TEMPORARY REMOVED ***/ /* Temporarily Disables GPS_HOLD_MODE to be able to make it possible to adjust the Hold-position when moving the sticks.*/ //#define AP_MODE 40 // Create a deadspan for GPS.
so, if i understand correctly, upcoming 2.4 will NOT support a "loiter" functionality (gps-hold repositioning using sticks).
Guys, i do not understand how this is related with radio mixes instead of code change. Anyway, i think "AP FlightMode" is a "must" feature for aerial photography....am i the only one thinking of this??
Patrik, can u be more specific?? Where to restore your code snippet?? Why it was excluded by EOS after his NAV version?? (is there a conflict between AP Aflightmode and NAvigation??)
I assume that on, say, an openTX compatible transmitter, one could build a mix such as:
if pitch or roll stick deflection > threshold, switch an AUX channel back from GPS hold to horizon mode
I am considering trying to set such a mix on my Taranis as an exercise, but if anyone already did this or if there is a better way, I am all for enlightenment
jaames74 wrote:Patrik, can u be more specific?? Where to restore your code snippet?? Why it was excluded by EOS after his NAV version?? (is there a conflict between AP Aflightmode and NAvigation??)
#if defined(AP_MODE) if (f.GPS_mode == GPS_MODE_HOLD &&(abs(rcCommand[ROLL])> AP_MODE || abs(rcCommand[PITCH]) > AP_MODE)) { //Position hold has priority over mission execution //But has less priority than RTH GPS_set_next_wp(&GPS_coord[LAT], &GPS_coord[LON],&GPS_coord[LAT], & GPS_coord[LON]); // Move HoldPos } #endif
#define AP_MODE 50 feels good i think.
/edit/ corrected line numbers
Last edited by PatrikE on Tue Mar 24, 2015 9:15 am, edited 3 times in total.
#if defined(AP_MODE) if (f.GPS_mode == GPS_MODE_HOLD &&(abs(rcCommand[ROLL])> AP_MODE || abs(rcCommand[PITCH]) > AP_MODE)) { //Position hold has priority over mission execution //But has less priority than RTH GPS_set_next_wp(&GPS_coord[LAT], &GPS_coord[LON],&GPS_coord[LAT], & GPS_coord[LON]); // Move HoldPos } #endif
#define AP_MODE 70 feels good i think.
Hi PatrikE, thanks for this. I downloaded the last MWii 2.4 and seems that your suggested code has to be added after lines 1144,1145 and not after lines 1202,1203. Can you please give me a tip or confirmation?
Someone has already tested it? I will do it asap.
@ Eosbandi: What do you think about this very simple and nice solution by PatrikE ?