Added support of 64bit events. (#597)
* Added support of 64bit even
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Added missing brackets
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Made proper name for tick macro.
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Improved macro evaluation
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Fixed missed port files + documentation
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Changes made on PR
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Fix macro definition.
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
* Formatted code with uncrustify
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
---------
Signed-off-by: Cervenka Dusan <cervenka@acrios.com>
diff --git a/portable/GCC/ATMega323/portmacro.h b/portable/GCC/ATMega323/portmacro.h
index 7afdef9..c22706d 100644
--- a/portable/GCC/ATMega323/portmacro.h
+++ b/portable/GCC/ATMega323/portmacro.h
@@ -65,12 +65,14 @@
typedef signed char BaseType_t;
typedef unsigned char UBaseType_t;
-#if( configUSE_16_BIT_TICKS == 1 )
+#if( configTICK_TYPE_WIDTH_IN_BITS == TICK_TYPE_WIDTH_16_BITS )
typedef uint16_t TickType_t;
#define portMAX_DELAY ( TickType_t ) 0xffff
-#else
+#elif ( configTICK_TYPE_WIDTH_IN_BITS == TICK_TYPE_WIDTH_32_BITS )
typedef uint32_t TickType_t;
- #define portMAX_DELAY ( TickType_t ) 0xffffffffUL
+ #define portMAX_DELAY ( TickType_t ) ( 0xFFFFFFFFUL )
+#else
+ #error configTICK_TYPE_WIDTH_IN_BITS set to unsupported tick type width.
#endif
/*-----------------------------------------------------------*/