1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-13 11:29:56 +03:00

use MAX_SUPPORTED_RC_CHANNEL_COUNT instead of hardcoded 16

This commit is contained in:
Roman Lut 2023-01-04 01:04:26 +02:00
parent 7f38d107af
commit 59a19ec299

View file

@ -778,7 +778,7 @@ int logicConditionGetOperandValue(logicOperandType_e type, int operand) {
case LOGIC_CONDITION_OPERAND_TYPE_RC_CHANNEL:
//Extract RC channel raw value
if (operand >= 1 && operand <= 16) {
if (operand >= 1 && operand <= MAX_SUPPORTED_RC_CHANNEL_COUNT) {
retVal = rxGetChannelValue(operand - 1);
}
break;