Jim Flynn
/
aws-iot-device-sdk-mbed-c
Changes to enabled on-line compiler
platform/common/timer_platform.h@0:082731ede69f, 2018-05-30 (annotated)
- Committer:
- JMF
- Date:
- Wed May 30 20:59:51 2018 +0000
- Revision:
- 0:082731ede69f
Initial commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
JMF | 0:082731ede69f | 1 | /* |
JMF | 0:082731ede69f | 2 | * Copyright 2010-2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. |
JMF | 0:082731ede69f | 3 | * |
JMF | 0:082731ede69f | 4 | * Licensed under the Apache License, Version 2.0 (the "License"). |
JMF | 0:082731ede69f | 5 | * You may not use this file except in compliance with the License. |
JMF | 0:082731ede69f | 6 | * A copy of the License is located at |
JMF | 0:082731ede69f | 7 | * |
JMF | 0:082731ede69f | 8 | * http://aws.amazon.com/apache2.0 |
JMF | 0:082731ede69f | 9 | * |
JMF | 0:082731ede69f | 10 | * or in the "license" file accompanying this file. This file is distributed |
JMF | 0:082731ede69f | 11 | * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either |
JMF | 0:082731ede69f | 12 | * express or implied. See the License for the specific language governing |
JMF | 0:082731ede69f | 13 | * permissions and limitations under the License. |
JMF | 0:082731ede69f | 14 | */ |
JMF | 0:082731ede69f | 15 | |
JMF | 0:082731ede69f | 16 | #ifndef SRC_PROTOCOL_MQTT_AWS_IOT_EMBEDDED_CLIENT_WRAPPER_PLATFORM_LINUX_COMMON_TIMER_PLATFORM_H_ |
JMF | 0:082731ede69f | 17 | #define SRC_PROTOCOL_MQTT_AWS_IOT_EMBEDDED_CLIENT_WRAPPER_PLATFORM_LINUX_COMMON_TIMER_PLATFORM_H_ |
JMF | 0:082731ede69f | 18 | |
JMF | 0:082731ede69f | 19 | #ifdef __cplusplus |
JMF | 0:082731ede69f | 20 | extern "C" { |
JMF | 0:082731ede69f | 21 | #endif |
JMF | 0:082731ede69f | 22 | |
JMF | 0:082731ede69f | 23 | /** |
JMF | 0:082731ede69f | 24 | * @file timer_platform.h |
JMF | 0:082731ede69f | 25 | */ |
JMF | 0:082731ede69f | 26 | #include <time.h> |
JMF | 0:082731ede69f | 27 | |
JMF | 0:082731ede69f | 28 | //#include <sys/time.h> |
JMF | 0:082731ede69f | 29 | //#include <sys/select.h> |
JMF | 0:082731ede69f | 30 | #include "timer_interface.h" |
JMF | 0:082731ede69f | 31 | |
JMF | 0:082731ede69f | 32 | /** |
JMF | 0:082731ede69f | 33 | * definition of the Timer struct. Platform specific |
JMF | 0:082731ede69f | 34 | */ |
JMF | 0:082731ede69f | 35 | struct timeval { |
JMF | 0:082731ede69f | 36 | long int tv_sec; |
JMF | 0:082731ede69f | 37 | long int tv_usec; |
JMF | 0:082731ede69f | 38 | }; |
JMF | 0:082731ede69f | 39 | |
JMF | 0:082731ede69f | 40 | struct awsTimer { |
JMF | 0:082731ede69f | 41 | struct timeval end_time; |
JMF | 0:082731ede69f | 42 | }; |
JMF | 0:082731ede69f | 43 | |
JMF | 0:082731ede69f | 44 | #ifdef __cplusplus |
JMF | 0:082731ede69f | 45 | } |
JMF | 0:082731ede69f | 46 | #endif |
JMF | 0:082731ede69f | 47 | |
JMF | 0:082731ede69f | 48 | #endif /* SRC_PROTOCOL_MQTT_AWS_IOT_EMBEDDED_CLIENT_WRAPPER_PLATFORM_LINUX_COMMON_TIMER_PLATFORM_H_ */ |