comparison Small_CPU/Inc/scheduler.h @ 221:486dddfba7ce

Merged in Ideenmodellierer/ostc4/Improve_IPC_Sync (pull request #12) Improve IPC Sync
author heinrichsweikamp <bitbucket@heinrichsweikamp.com>
date Mon, 01 Apr 2019 09:01:09 +0000
parents e524a824d8f2
children e4207f0aaa4b
comparison
equal deleted inserted replaced
216:7012a521fa95 221:486dddfba7ce
34 34
35 #define SPI_SYNC_METHOD_NONE (0u) 35 #define SPI_SYNC_METHOD_NONE (0u)
36 #define SPI_SYNC_METHOD_HARD (1u) /* Scheduler shall reset all counters to 0 */ 36 #define SPI_SYNC_METHOD_HARD (1u) /* Scheduler shall reset all counters to 0 */
37 #define SPI_SYNC_METHOD_SOFT (2u) /* Scheduler shall reset adjust counters to 100ms SPI data exchange cycle */ 37 #define SPI_SYNC_METHOD_SOFT (2u) /* Scheduler shall reset adjust counters to 100ms SPI data exchange cycle */
38 #define SPI_SYNC_METHOD_INVALID (4u) 38 #define SPI_SYNC_METHOD_INVALID (4u)
39
40 #define SCHEDULER_TICK_EXE1SEC (980u) /* tick count based on cycle start which is used to trigger functions which */
41 /* shall be executed once in a second (20ms before cycle restarts) */
39 42
40 typedef struct 43 typedef struct
41 { 44 {
42 uint8_t mode; 45 uint8_t mode;
43 short conservatism; 46 short conservatism;
80 { 83 {
81 uint8_t counterSPIdata100msec; 84 uint8_t counterSPIdata100msec;
82 uint8_t counterPressure100msec; 85 uint8_t counterPressure100msec;
83 uint8_t counterCompass100msec; 86 uint8_t counterCompass100msec;
84 uint8_t counterAmbientLight100msec; 87 uint8_t counterAmbientLight100msec;
88 uint32_t tick_execute1second;
85 uint32_t tickstart; 89 uint32_t tickstart;
86 } SScheduleCtrl; 90 } SScheduleCtrl;
87 91
88 92
89 /* Variables ---------------------------------------------------------*/ 93 /* Variables ---------------------------------------------------------*/