Subversion Repositories FlightCtrl

Compare Revisions

Ignore whitespace Rev 2345 → Rev 2384

/branches/V2.01a_ACC-HH_MartinR/jetimenu.c
68,6 → 68,8
#define JetiBox_printfxy(x,y,format, args...) { LIBFC_JetiBox_SetPos(y * 16 + x); _printf_P(&LIBFC_JetiBox_Putchar, PSTR(format) , ## args);}
#define JetiBox_printf(format, args...) { _printf_P(&LIBFC_JetiBox_Putchar, PSTR(format) , ## args);}
 
#define LIMIT_MIN_MAX(value, min, max) {if(value <= min) value = min; else if(value >= max) value = max;} //MartinR
 
// -----------------------------------------------------------
// the menu functions
// -----------------------------------------------------------
188,6 → 190,29
}
 
 
// MartinR für Jeti+ Anfang
void Menu_spoti1(uint8_t key)
{ //0123456789ABCDEF
 
JetiBox_printfxy(0,0,">%3i=Serialpot1",(PPM_in[13] + 127));
//JetiBox_printfxy(0,1," %3i=Serialpot2",PPM_in[14]);
if(key== JETIBOX_KEY_UP) PPM_in[13] = PPM_in[13]+25;
if(key== JETIBOX_KEY_DOWN) PPM_in[13] = PPM_in[13]-25;
LIMIT_MIN_MAX(PPM_in[13], -127, 128); // MartinR: Begrenzung
}
 
void Menu_spoti2(uint8_t key)
{ //0123456789ABCDEF
 
//JetiBox_printfxy(0,0," %3i=Serialpot1",PPM_in[13]);
JetiBox_printfxy(0,1,">%3i=Serialpot2",(PPM_in[14] + 127));
if(key== JETIBOX_KEY_UP) PPM_in[14] = PPM_in[14]+2;
if(key== JETIBOX_KEY_DOWN) PPM_in[14] = PPM_in[14]-2;
LIMIT_MIN_MAX(PPM_in[14], -127, 128); // MartinR: Begrenzung
}
 
// MartinR für Jeti+ Ende
 
// -----------------------------------------------------------
// the menu topology
// -----------------------------------------------------------
212,11 → 237,17
const MENU_ENTRY JetiBox_Menu[] PROGMEM=
{ // l r u d pHandler
#if !defined (RECEIVER_SPEKTRUM_DX7EXP) && !defined (RECEIVER_SPEKTRUM_DX8EXP)
{4, 1, 0, 0, &Menu_Status }, // 0
//{4, 1, 0, 0, &Menu_Status }, // 0 // MartinR: so war es
{6, 1, 0, 0, &Menu_Status }, // 0 // MartinR: geändert
{0, 2, 1, 1, &Menu_Temperature }, // 1
{1, 3, 2, 2, &Menu_Battery }, // 2
{2, 4, 3, 3, &Menu_PosInfo }, // 3
{3, 0, 4, 4, &Magnet_Values } // 4
//{3, 0, 4, 4, &Magnet_Values } // 4 // MartinR: so war es
{3, 5, 4, 4, &Magnet_Values }, // 4 // MartinR: geändert
{4, 6, 5, 5, &Menu_spoti1 }, // 5 // MartinR: für Jeti+
{5, 0, 6, 6, &Menu_spoti2 }, // 6 // MartinR: für Jeti+
 
#endif
};