настройка стандартов связи GSM заблокирована по мьютексам, причина - добавление потоков, одновременного обращения к АТ интерфейсу модема
This commit is contained in:
parent
ba7d1aec20
commit
2b342d75b9
|
|
@ -39,7 +39,7 @@ void TELEMATICA_STOP(tMma *env) {
|
||||||
SystemDelayMs(100);
|
SystemDelayMs(100);
|
||||||
}
|
}
|
||||||
|
|
||||||
Gsm_SetProfileERA(&env->egtsProcessing);
|
Gsm_SetProfileERA(&env->gsmWithGnss.gsmAt, &env->storage.nvm.deviceTeledataStorageData);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -91,16 +91,21 @@ void Mma_Shutdown(tMma *env) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Mma_EcallPrepare(tMma *env) {
|
void Mma_EcallPrepare(tMma *env) {
|
||||||
AtGsm_OperatorSelectionDeregister(&env->gsmWithGnss.gsmAt);
|
if (osMutexAcquire(env->gsmWithGnss.gsmAt.access, 5000) == osOK) {
|
||||||
SystemDelayMs(1000);
|
AtGsm_OperatorSelectionDeregister(&env->gsmWithGnss.gsmAt);
|
||||||
GsmWithGnss_SelectStandartNetwork(&env->gsmWithGnss.gsmAt, 12);
|
SystemDelayMs(1000);
|
||||||
SystemDelayMs(1000);
|
GsmWithGnss_SelectStandartNetwork(&env->gsmWithGnss.gsmAt, 12);
|
||||||
GsmWithGnss_SelectStandartNetwork(&env->gsmWithGnss.gsmAt, 22);
|
SystemDelayMs(1000);
|
||||||
SystemDelayMs(1000);
|
GsmWithGnss_SelectStandartNetwork(&env->gsmWithGnss.gsmAt, 22);
|
||||||
GsmWithGnss_SelectStandartNetwork(&env->gsmWithGnss.gsmAt, 25);
|
SystemDelayMs(1000);
|
||||||
SystemDelayMs(1000);
|
GsmWithGnss_SelectStandartNetwork(&env->gsmWithGnss.gsmAt, 25);
|
||||||
AtGsm_OperatorSelectionDeregister(&env->gsmWithGnss.gsmAt);
|
SystemDelayMs(1000);
|
||||||
AtGsmTelitLe910_GnssEcallOnlyMode(&env->gsmWithGnss.gsmAt, 0);
|
AtGsm_OperatorSelectionDeregister(&env->gsmWithGnss.gsmAt);
|
||||||
|
AtGsmTelitLe910_GnssEcallOnlyMode(&env->gsmWithGnss.gsmAt, 0);
|
||||||
|
osMutexRelease(env->gsmWithGnss.gsmAt.access);
|
||||||
|
} else {
|
||||||
|
LoggerErrorStatic(LOGGER, LOG_SIGN, "Захватить мьютэкс Mma_EcallPrepare не удалось")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue