Обновление
This commit is contained in:
parent
deff348010
commit
fc9c5e7b04
|
|
@ -521,6 +521,16 @@ static lin_event_id_t CFR_PRG_x(tLinIO *linIo, tLinData *linData, uint8_t BUS_AD
|
|||
return res;
|
||||
}
|
||||
*/
|
||||
static bool isBroadCast(tLinTaskActuator *env) {
|
||||
|
||||
for (uint8_t j = 0; j < env->LIN_ISSR_ALL; ++j) {
|
||||
if (env->linCommandActuator[j].BUS_ADR != 0) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool setState20(tLinTaskActuator *env, bool isError, uint8_t index) {
|
||||
|
||||
|
|
@ -534,6 +544,9 @@ static bool setState20(tLinTaskActuator *env, bool isError, uint8_t index) {
|
|||
env->linCommandActuator[index].isRFR_STA = 1;
|
||||
|
||||
if (env->linCommandActuator[index].BUS_ADR == 0) {
|
||||
|
||||
if (isBroadCast(env)) {
|
||||
|
||||
for (uint8_t j = 0; j < env->LIN_ISSR_ALL; ++j) {
|
||||
|
||||
env->linCommandActuator[j].COM = LIN_ACT_CFR_SUCCESSFUL;
|
||||
|
|
@ -545,23 +558,14 @@ static bool setState20(tLinTaskActuator *env, bool isError, uint8_t index) {
|
|||
env->linStateActuator[j].error_connect = 0;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
static bool isBroadCast(tLinTaskActuator *env) {
|
||||
|
||||
for (uint8_t j = 0; j < env->LIN_ISSR_ALL; ++j) {
|
||||
if (env->linCommandActuator[j].BUS_ADR != 0) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static lin_event_id_t Lin_Scheduler(tLinTaskActuator *env, char *LOG_SIGN) {
|
||||
|
||||
lin_event_id_t ret = LIN_NO_EVENT;
|
||||
|
|
|
|||
Loading…
Reference in New Issue