// // Created by xemon on 19.09.22. // #ifndef UVEOS_ON_NATION_MMA_H #define UVEOS_ON_NATION_MMA_H //Железные интерфесы #include "PeripheralInterfaces.h" #include "DevRtc.h" #include "RtcIO.h" #ifdef UVEOS_ADD_TELEMATICA #include "EgtsProcessing.h" #endif //Переферийные устройства #include #include #include #if USE_GSM_AND_GNSS_TELIT #include #endif #ifdef USE_GSM_AND_GNSS_SIMCOM #include #include #endif //Подсистемы #include #include #include #include #include #include #include #include "CanMain.h" typedef struct { // Преферийные интерфесы tGpios *gpios; tSerialPorts *serialPorts; tI2cPorts *i2cPorts; tSpiPorts *spiPorts; tAdcs *adcs; tStorageOnFlash *flash; tRtc *rtc; // Преферийные устройства tDeviceStorage storage; tPowerManagement power; tAudioCodec audioCodec; tGsmWithGnss gsmWithGnss; tAccel accel; //Подсистемы tLoggerToSerialPort slog; tUserInput userInput; tUserIndication indication; tComInt comInt; // tCli cli; tCli cliVrt; tDeviceTesting testing; tCrashDetection crashDetect; tEraGlonassUveos uveos; tCanMainAdditional canMainAdditional; uint32_t lastSmsCheckTime; struct { osThreadId_t id; uint32_t stack[2048]; //4048 6072 StaticTask_t controlBlock; osThreadAttr_t attr; } thread; tStaticThreadBlock(512) threadTesting; bool flIgn; volatile bool kzModeBloc; // tSignPack signature; tCanMain canMain; #ifdef UVEOS_ADD_TELEMATICA tEgtsProcessing egtsProcessing; #endif } tMma; void Mma_Init( tMma *env, tGpios *gpios, tSerialPorts *serialPorts, tI2cPorts *i2cPorts, tSpiPorts *spiPorts, tAdcs *adcs, tStorageOnFlash *flash, tRtc *rtc ); void Mma_StartThread(tMma *env); #define Mma_SetMode(ENV, VALUE) UserIndication_SetMode(&((ENV)->indication),(VALUE)) #endif //UVEOS_ON_NATION_MMA_H