Compilation fixes on all boards
This commit is contained in:
@@ -244,7 +244,7 @@ uint8_t getTextWidth(const char * s, uint8_t len, LcdFlags flags)
|
||||
{
|
||||
uint8_t width = 0;
|
||||
for (int i=0; len==0 || i<len; ++i) {
|
||||
unsigned char c = (flags & ZCHAR) ? idx2char(*s) : *s;
|
||||
unsigned char c = (flags & ZCHAR) ? zchar2char(*s) : *s;
|
||||
if (!c) {
|
||||
break;
|
||||
}
|
||||
@@ -274,7 +274,7 @@ void lcdDrawSizedText(coord_t x, coord_t y, const char * s, uint8_t len, LcdFlag
|
||||
#if defined(BOOT)
|
||||
unsigned char c = *s;
|
||||
#else
|
||||
unsigned char c = (flags & ZCHAR) ? idx2char(*s) : *s;
|
||||
unsigned char c = (flags & ZCHAR) ? zchar2char(*s) : *s;
|
||||
#endif
|
||||
|
||||
if (setx) {
|
||||
|
||||
@@ -1280,11 +1280,11 @@ void menuModelFailsafe(event_t event)
|
||||
|
||||
if (menuVerticalPosition < sentModuleChannels(g_moduleIdx)) {
|
||||
if (s_editMode) {
|
||||
g_model.moduleData[g_moduleIdx].failsafeChannels[menuVerticalPosition] = channelOutputs[menuVerticalPosition+channelStart];
|
||||
g_model.failsafeChannels[menuVerticalPosition] = channelOutputs[menuVerticalPosition+channelStart];
|
||||
s_editMode = 0;
|
||||
}
|
||||
else {
|
||||
int16_t & failsafe = g_model.moduleData[g_moduleIdx].failsafeChannels[menuVerticalPosition];
|
||||
int16_t & failsafe = g_model.failsafeChannels[menuVerticalPosition];
|
||||
if (failsafe < FAILSAFE_CHANNEL_HOLD)
|
||||
failsafe = FAILSAFE_CHANNEL_HOLD;
|
||||
else if (failsafe == FAILSAFE_CHANNEL_HOLD)
|
||||
@@ -1330,7 +1330,7 @@ void menuModelFailsafe(event_t event)
|
||||
|
||||
for (; line < 8; line++) {
|
||||
const int32_t channelValue = channelOutputs[ch+channelStart];
|
||||
int32_t failsafeValue = g_model.moduleData[g_moduleIdx].failsafeChannels[8*col+line];
|
||||
int32_t failsafeValue = g_model.failsafeChannels[8*col+line];
|
||||
uint8_t lenLabel = ZLEN(g_model.limitData[ch+channelStart].name);
|
||||
uint8_t barW = colW - FW * maxNameLen - FWNUM * 3; // default bar width
|
||||
|
||||
@@ -1359,7 +1359,7 @@ void menuModelFailsafe(event_t event)
|
||||
}
|
||||
else {
|
||||
flags |= BLINK;
|
||||
CHECK_INCDEC_MODELVAR(event, g_model.moduleData[g_moduleIdx].failsafeChannels[8*col+line], -lim, +lim);
|
||||
CHECK_INCDEC_MODELVAR(event, g_model.failsafeChannels[8*col+line], -lim, +lim);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user