mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-08-14 09:28:59 +00:00
Merge pull request #1310 from drugo72/pr-avr-clock_time_t
AVR platforms: use 32 bit clock_time_t
This commit is contained in:
commit
bc90b5df71
@ -56,18 +56,10 @@
|
||||
*/
|
||||
/* Clock ticks per second */
|
||||
#define CLOCK_CONF_SECOND 128
|
||||
#if 1
|
||||
/* 16 bit counter overflows every ~10 minutes */
|
||||
typedef unsigned short clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed short)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffff
|
||||
#define RIME_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#define COLLECT_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#else
|
||||
typedef unsigned long clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed long)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffffffff
|
||||
#endif
|
||||
|
||||
typedef uint32_t clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((int32_t)((a)-(b)) < 0)
|
||||
|
||||
/* These routines are not part of the contiki core but can be enabled in cpu/avr/clock.c */
|
||||
void clock_delay_msec(uint16_t howlong);
|
||||
void clock_adjust_ticks(clock_time_t howmany);
|
||||
|
@ -68,18 +68,10 @@
|
||||
*/
|
||||
/* Clock ticks per second */
|
||||
#define CLOCK_CONF_SECOND 128
|
||||
#if 1
|
||||
/* 16 bit counter overflows every ~10 minutes */
|
||||
typedef unsigned short clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed short)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffff
|
||||
#define RIME_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#define COLLECT_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#else
|
||||
typedef unsigned long clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed long)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffffffff
|
||||
#endif
|
||||
|
||||
typedef uint32_t clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((int32_t)((a)-(b)) < 0)
|
||||
|
||||
/* These routines are not part of the contiki core but can be enabled in cpu/avr/clock.c */
|
||||
void clock_delay_msec(uint16_t howlong);
|
||||
void clock_adjust_ticks(clock_time_t howmany);
|
||||
|
@ -70,18 +70,10 @@
|
||||
*/
|
||||
/* Clock ticks per second */
|
||||
#define CLOCK_CONF_SECOND 125
|
||||
#if 1
|
||||
/* 16 bit counter overflows every ~10 minutes */
|
||||
typedef unsigned short clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed short)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffff
|
||||
#define RIME_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#define COLLECT_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#else
|
||||
typedef unsigned long clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed long)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffffffff
|
||||
#endif
|
||||
|
||||
typedef uint32_t clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((int32_t)((a)-(b)) < 0)
|
||||
|
||||
/* These routines are not part of the contiki core but can be enabled in cpu/avr/clock.c */
|
||||
void clock_delay_msec(uint16_t howlong);
|
||||
void clock_adjust_ticks(clock_time_t howmany);
|
||||
|
@ -62,18 +62,10 @@
|
||||
*/
|
||||
/* Clock ticks per second */
|
||||
#define CLOCK_CONF_SECOND 125
|
||||
#if 1
|
||||
/* 16 bit counter overflows every ~10 minutes */
|
||||
typedef unsigned short clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed short)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffff
|
||||
#define RIME_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#define COLLECT_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#else
|
||||
typedef unsigned long clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed long)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffffffff
|
||||
#endif
|
||||
|
||||
typedef uint32_t clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((int32_t)((a)-(b)) < 0)
|
||||
|
||||
/* These routines are not part of the contiki core but can be enabled in cpu/avr/clock.c */
|
||||
void clock_delay_msec(uint16_t howlong);
|
||||
void clock_adjust_ticks(clock_time_t howmany);
|
||||
|
@ -62,18 +62,10 @@
|
||||
*/
|
||||
/* Clock ticks per second */
|
||||
#define CLOCK_CONF_SECOND 125
|
||||
#if 1
|
||||
/* 16 bit counter overflows every ~10 minutes */
|
||||
typedef unsigned short clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed short)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffff
|
||||
#define RIME_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#define COLLECT_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#else
|
||||
typedef unsigned long clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed long)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffffffff
|
||||
#endif
|
||||
|
||||
typedef uint32_t clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((int32_t)((a)-(b)) < 0)
|
||||
|
||||
/* These routines are not part of the contiki core but can be enabled in cpu/avr/clock.c */
|
||||
void clock_delay_msec(uint16_t howlong);
|
||||
void clock_adjust_ticks(clock_time_t howmany);
|
||||
|
@ -56,18 +56,10 @@
|
||||
*/
|
||||
/* Clock ticks per second */
|
||||
#define CLOCK_CONF_SECOND 128
|
||||
#if 1
|
||||
/* 16 bit counter overflows every ~10 minutes */
|
||||
typedef unsigned short clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed short)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffff
|
||||
#define RIME_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#define COLLECT_CONF_BROADCAST_ANNOUNCEMENT_MAX_TIME INFINITE_TIME/CLOCK_CONF_SECOND /* Default uses 600 */
|
||||
#else
|
||||
typedef unsigned long clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((signed long)((a)-(b)) < 0)
|
||||
#define INFINITE_TIME 0xffffffff
|
||||
#endif
|
||||
|
||||
typedef uint32_t clock_time_t;
|
||||
#define CLOCK_LT(a,b) ((int32_t)((a)-(b)) < 0)
|
||||
|
||||
/* These routines are not part of the contiki core but can be enabled in cpu/avr/clock.c */
|
||||
void clock_delay_msec(uint16_t howlong);
|
||||
void clock_adjust_ticks(clock_time_t howmany);
|
||||
|
Loading…
Reference in New Issue
Block a user