altos: Change default time type to 32-bits
authorKeith Packard <keithp@keithp.com>
Mon, 25 Feb 2019 23:41:45 +0000 (16:41 -0700)
committerKeith Packard <keithp@keithp.com>
Mon, 25 Feb 2019 23:41:45 +0000 (16:41 -0700)
Offers additional range for internal use without increasing cost on
32-bit platforms.

Signed-off-by: Keith Packard <keithp@keithp.com>
src/attiny/ao_arch.h
src/kernel/ao.h

index dfd41afe2ec90dba9d5decdc51f7f340101fc714..5550eb447e101f3fa724120bf634053ca1b28540 100644 (file)
 
 #define AO_LED_TYPE    uint8_t
 
+#ifndef AO_TICK_TYPE
+#define AO_TICK_TYPE   uint16_t
+#define AO_TICK_SIGNED int16_t
+#endif
+
 /* Various definitions to make GCC look more like SDCC */
 
 #define ao_arch_naked_declare  __attribute__((naked))
index 910c1d8ed97c532c70da13957fd087f6ee06b84a..c00de1fe064644e3189bfd8b024865477676f26e 100644 (file)
@@ -100,8 +100,8 @@ extern AO_ROMCONFIG_SYMBOL uint32_t ao_radio_cal;
  */
 
 #ifndef AO_TICK_TYPE
-#define AO_TICK_TYPE   uint16_t
-#define AO_TICK_SIGNED int16_t
+#define AO_TICK_TYPE   uint32_t
+#define AO_TICK_SIGNED int32_t
 #endif
 
 extern volatile AO_TICK_TYPE ao_tick_count;