From 737124c7b279634d86422ea3e121de5d7d5ba5fb Mon Sep 17 00:00:00 2001 From: Imanol-Mikel Barba Sabariego Date: Sat, 24 May 2014 13:51:36 +0000 Subject: [PATCH] --- Project/applications/smartcities/include/timer-loop.h | 6 ++++-- Project/applications/smartcities/main2.c | 64 ++++++++++++++++++++++++++++++++++++++++++---------------------- Project/applications/smartcities/test_timer-loop.c | 2 +- 3 files changed, 47 insertions(+), 25 deletions(-) diff --git a/Project/applications/smartcities/include/timer-loop.h b/Project/applications/smartcities/include/timer-loop.h index d610907..c79f581 100644 --- a/Project/applications/smartcities/include/timer-loop.h +++ b/Project/applications/smartcities/include/timer-loop.h @@ -6,8 +6,10 @@ #define HALF_HOUR 60*30 // time in seconds #define FIVE_MIN 60*5 // time in seconds -#define LONG_PERIOD HALF_HOUR //60*3 // for testing -#define SHORT_PERIOD FIVE_MIN //60*1 // for testing +//#define LONG_PERIOD HALF_HOUR //60*3 // for testing +//#define SHORT_PERIOD FIVE_MIN //60*1 // for testing +#define LONG_PERIOD 60*3 //60*3 // for testing +#define SHORT_PERIOD 60*1 //60*1 // for testing unsigned long getSystemTime(void); diff --git a/Project/applications/smartcities/main2.c b/Project/applications/smartcities/main2.c index bf4a2d9..f595155 100644 --- a/Project/applications/smartcities/main2.c +++ b/Project/applications/smartcities/main2.c @@ -115,7 +115,8 @@ void send_data(char** buffers[], uint32_t ind[], uint32_t sizes[], uint8_t senso void put_buffers(char** buffers[],uint32_t ind[],uint32_t sizes[],char** cooked, uint8_t* sensors){ int i; - for(i=0;i