Broken Event flags

This commit is contained in:
@CarlWachter 2024-02-16 17:44:01 +01:00
parent 68365e3d5e
commit 51fad902e7
6 changed files with 15 additions and 14 deletions

View File

@ -29,14 +29,10 @@
#define STA_RTOS_SYSTEM_EVENTS_ENABLE #define STA_RTOS_SYSTEM_EVENTS_ENABLE
// #define STA_RTOS_SYSTEM_WATCHDOG_ENABLE // #define STA_RTOS_SYSTEM_WATCHDOG_ENABLE
// #define STA_RTOS_WATCHDOG_ENABLE // #define STA_RTOS_WATCHDOG_ENABLE
//#define STA_CAN_BUS_ENABLE
// Uses the default configuration for TACOS.
// Settings for TACOS #include<sta/tacos/configs/default.hpp>
#define STA_TACOS_MANAGER_PRIORITY osPriorityNormal
#define STA_TACOS_STATEMACHINE_PRIORITY osPriorityNormal
// Statemachine settings. Here, we only have a single state which is also the initial state.
#define STA_TACOS_NUM_STATES 3 #define STA_TACOS_NUM_STATES 3
#define STA_TACOS_INITIAL_STATE 0
#endif /* INC_STA_CONFIG_HPP_ */ #endif /* INC_STA_CONFIG_HPP_ */

View File

@ -8,9 +8,12 @@
#include <tasks/can_task.hpp> #include <tasks/can_task.hpp>
#include <sta/debug/debug.hpp> #include <sta/debug/debug.hpp>
#include <sta/rtos/debug/heap_stats.hpp> #include <sta/rtos/debug/heap_stats.hpp>
#include <sta/rtos/system/can_bus.hpp>
#include <cmsis_os2.h> #include <cmsis_os2.h>
#include <sta/tacos/can_bus.hpp>
namespace demo namespace demo
{ {
CanTask::CanTask(const char* name, CAN_HandleTypeDef * handle) CanTask::CanTask(const char* name, CAN_HandleTypeDef * handle)
@ -36,9 +39,12 @@ namespace demo
void CanTask::func() void CanTask::func()
{ {
//STA_DEBUG_HEAP_STATS(); //struct CanDataMsg myCanDataMsg = {
///*.header = */ txHeader.id.sid, txHeader.id.eid, (uint8_t)txHeader.id.format, txHeader.payloadLength ,
///*.payload = */ *payload // Initialize payload to zero (or any other values as needed)
//};
canController.sendFrame(txHeader, payload); canController.sendFrame(txHeader, payload);
//STA_DEBUG_HEAP_STATS(); //STA_DEBUG_PRINTLN(sta::tacos::CanBus::instance()->queueCanBusMsg(myCanDataMsg, osWaitForever));
STA_DEBUG_PRINTLN("SENT FRAME"); STA_DEBUG_PRINTLN("SENT FRAME");
HAL_Delay(1000); HAL_Delay(1000);
} }

View File

@ -30,7 +30,7 @@
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.enable_logging" value="false"/> <booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.enable_logging" value="false"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.enable_max_halt_delay" value="false"/> <booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.enable_max_halt_delay" value="false"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.enable_shared_stlink" value="false"/> <booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.enable_shared_stlink" value="false"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.frequency" value="75"/> <stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.frequency" value="0"/>
<booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.halt_all_on_reset" value="false"/> <booleanAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.halt_all_on_reset" value="false"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.log_file" value="C:\Users\carlw\Desktop\to-the-moon\CAN-Demo\Debug\st-link_gdbserver_log.txt"/> <stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.log_file" value="C:\Users\carlw\Desktop\to-the-moon\CAN-Demo\Debug\st-link_gdbserver_log.txt"/>
<stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.low_power_debug" value="enable"/> <stringAttribute key="com.st.stm32cube.ide.mcu.debug.stlink.low_power_debug" value="enable"/>

View File

@ -386,8 +386,7 @@ HAL_TickFreqTypeDef HAL_GetTickFreq(void)
* @param Delay specifies the delay time length, in milliseconds. * @param Delay specifies the delay time length, in milliseconds.
* @retval None * @retval None
*/ */
__weak void HAL_Delay(uint32_t Delay) __weak void HAL_Delay(uint32_t Delay){
{
uint32_t tickstart = HAL_GetTick(); uint32_t tickstart = HAL_GetTick();
uint32_t wait = Delay; uint32_t wait = Delay;

@ -1 +1 @@
Subproject commit bfba17245ff5a4f2c5e2f7e08a8dc719676ae32a Subproject commit 16b2ed5a20df1c04b9bbcf5e12101d5e822e45d2

@ -1 +1 @@
Subproject commit 16f33857f7f32f1b7b71959e5a322728a88a53ce Subproject commit 1925a1668e847e048423499f523f3293ea9d923a