From 7ebc2e5d1e7c66aa386c48d845c219cf5513d943 Mon Sep 17 00:00:00 2001 From: carlwachter Date: Thu, 21 Dec 2023 13:50:23 +0000 Subject: [PATCH] Added uartmutex to README --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/README.md b/README.md index 152f808..7611825 100644 --- a/README.md +++ b/README.md @@ -28,6 +28,24 @@ void StartDefaultTask(void *argument) } ``` +Ebenfalls müssen noch diese Ergänzungen in `Core/Src/freertos.c` vorgenommen werden: +``` +/* Definitions for uartMutex */ +osMutexId_t uartMutexHandle; +osStaticMutexDef_t uartMutex_cb; +const osMutexAttr_t uartMutex_attributes = { + .name = "uartMutex", + .cb_mem = &uartMutex_cb, + .cb_size = sizeof(uartMutex_cb), +}; + + +void MX_FREERTOS_Init(void) { + uartMutexHandle = osMutexNew(&uartMutex_attributes); + //... +} +``` + ## Configuring TACOS Be sure to add a "config.hpp" to the App/Inc/sta directory. This file could look like this: ``` @@ -63,4 +81,10 @@ Be sure to add a "config.hpp" to the App/Inc/sta directory. This file could look #define STA_TACOS_INITIAL_STATE 0 #endif /* INC_STA_CONFIG_HPP_ */ +``` +PS: For not officially supported chips use this as the include: +``` +#include +#define STA_MCU_LITTLE_ENDIAN +#define STA_PLATFORM_STM32 ``` \ No newline at end of file