55#define LOG_MODULE "coap-timer"
56#define LOG_LEVEL LOG_LEVEL_NONE
58PROCESS(coap_timer_process,
"coap timer process");
60static uint64_t current_time;
68 LOG_DBG(
"remaining %lu msec\n", (
unsigned long)remaining);
78 }
else if(remaining < 1) {
93 ev == PROCESS_EVENT_POLL);
108 static clock_time_t last;
113 diff = (clock_time_t)(now - last);
133const coap_timer_driver_t coap_timer_default_driver = {
clock_time_t clock_time(void)
Get the current clock time.
#define CLOCK_SECOND
A second, measured in system clock time.
int coap_timer_run(void)
This function must be called periodically by the CoAP timer driver to process any expired CoAP timers...
uint64_t coap_timer_time_to_next_expiration(void)
Get the time until next CoAP timer expires or 0 if there already exists expired timers that have not ...
void etimer_set(struct etimer *et, clock_time_t interval)
Set an event timer.
#define PROCESS(name, strname)
Declare a process.
#define PROCESS_BEGIN()
Define the beginning of a process.
#define PROCESS_WAIT_EVENT_UNTIL(c)
Wait for an event to be posted to the process, with an extra condition.
#define PROCESS_END()
Define the end of a process.
void process_start(struct process *p, process_data_t data)
Start a process.
#define PROCESS_THREAD(name, ev, data)
Define the body of a process.
void process_poll(struct process *p)
Request a process to be polled.
Header file for the Contiki process interface.