1
0
Fork 0

fix: reject invalid SRDO information direction during config

This commit is contained in:
MrAlaskan 2026-07-20 22:17:58 +08:00
parent 9b8beed836
commit 07fc670401

View file

@ -487,7 +487,7 @@ CO_SRDO_config(CO_SRDO_t* SRDO, uint8_t SRDO_Index, CO_SRDOGuard_t* SRDOGuard, u
if ((err == 0U) && configurationInProgress) {
if (cp_highestSubindexSupported != 6U) {
err = ERR_INFO(0x1301UL + SRDO_Index, 0, 2);
} else if (informationDirection > 3U) {
} else if (informationDirection > 2U) {
err = ERR_INFO(0x1301UL + SRDO_Index, 1, 2);
} else if (safetyCycleTime < ((CO_CONFIG_SRDO_MINIMUM_DELAY / 1000U) + 1U)) {
err = ERR_INFO(0x1301UL + SRDO_Index, 2, 2);